New plug-in: Uno Choice Plug-in for dynamic parameters

470 views
Skip to first unread message

Bruno P. Kinoshita

unread,
Feb 17, 2015, 8:33:16 AM2/17/15
to jenkin...@googlegroups.com
Hello all, 

We developed a plug-in in the BioUno project [1], initially based on the Dynamic Parameter Plug-in [2], but that followed a different approach for dynamic parameters. It provides parameters that are also rendered from Groovy scripts (per job script or via Scriptler integration) **but that can be related to other parameters**.

It utilizes JavaScript (FWIW dynamicparameter-plugin code is 2.8% JavaScript according to GitHub interface and uno-choice's is 43.9%) to monitor the HTML elements of one parameter, and trigger changes in other parameters. This way, you can easily create many parameters, like Maven Group ID, Artifact ID and Versions, that are dynamically updated.

Quick example: The Maven group ID could be a "Uno Choice Dynamic Choice Parameter" that returns a list of maven group IDs in some Maven repo using Groovy. Once the user selects a group ID, the artifact ID (a "Uno Choice Cascade Dynamic Choice Parameter") would automatically get updated, and its Groovy script rendered. The selected group ID would be available to the artifact id Groovy script as a variable. This way your script can load only the artifacts related to the selected group ID.

Attached is a GIF file with another example with a State parameter that dynamically updates the City parameter accordingly. 

The following Wiki page has been created and contains further information and examples: https://wiki.jenkins-ci.org/display/JENKINS/Uno+Choice+Plugin There are other features that were added to the plug-in such as hidden parameters, parameter filtering, self-referenced parameters and more, that I believe Ioannis could explain much better if necessary.

GitHub user IDS: @kinow and @imoutsatsos

If the plug-in gets accepted, I'll adjust the pom.xml, and will cut a 1.0 release.

Thank you!
Bruno

biouno1.gif

Jesse Glick

unread,
Feb 18, 2015, 4:01:43 PM2/18/15
to Jenkins Dev
On Tue, Feb 17, 2015 at 8:30 AM, 'Bruno P. Kinoshita' via Jenkins
Developers <jenkin...@googlegroups.com> wrote:
> We developed a plug-in in the BioUno project

A suggestion: give the plugin a more descriptive name. Random Jenkins
users are not going to have any idea what “Uno” is. Crediting the
institution that did the work is fine, but if I were looking to make
my parameters dynamic, I would pick a plugin named “Dynamic Parameter”
and skip right over “Uno Choice”.

BTW if this is to be usable in a secured installation you need to
integrate with the script-security plugin.

Bruno P. Kinoshita

unread,
Feb 18, 2015, 7:25:13 PM2/18/15
to jenkin...@googlegroups.com
A suggestion: give the plugin a more descriptive name. Random Jenkins
users are not going to have any idea what “Uno” is. Crediting the
institution that did the work is fine, but if I were looking to make
my parameters dynamic, I would pick a plugin named “Dynamic Parameter”
and skip right over “Uno Choice”.

Good point. I didn't choose the name, but I like it. Maybe Uno Choice Dynamic Parameter? Other suggestions? 
 
> BTW if this is to be usable in a secured installation you need to
integrate with the script-security plugin.

True! My bad for forgetting about this. I will try to integrate it in my next development cycle for the plug-in. I will try to check if the Dynamic Parameter plug-in is already integrated with the script-security plug-in. If not, I'll try to submit a pull request (otherwise I'll use it as reference :)

Cheers
Bruno 


From: Jesse Glick <jgl...@cloudbees.com>
To: Jenkins Dev <jenkin...@googlegroups.com>
Sent: Wednesday, February 18, 2015 7:01 PM
Subject: Re: New plug-in: Uno Choice Plug-in for dynamic parameters
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CANfRfr0gip-ui8oZggT277keKGzYDJoH_WKsEHPFSWjcbw3%2BAQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Richard Bywater

unread,
Feb 18, 2015, 7:31:29 PM2/18/15
to jenkin...@googlegroups.com
Personally I'd avoid the word Uno in the plugin name completely as, according to the README, you can have one *or more* parameters and Uno Choice Dynamic Parmeter says to me that the plugin only supports one choice.

Richard.

To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/1979203684.442515.1424305331365.JavaMail.yahoo%40mail.yahoo.com.

Ioannis Moutsatsos

unread,
Feb 18, 2015, 9:36:20 PM2/18/15
to jenkin...@googlegroups.com
All,

I do have to take responsibility for naming this plugin. So here goes the thinking behind it.

This is a plugin for making one or more choices among options for a parameter. Some of the functionality was previously distributed among different plugins (dynamic parameter plugin, extensible choice parameter plugin, extended choice plugin), but none of these was able to deliver cleanly and consistently the four main things I wanted:
  1. Dynamic generation of the parameter options, 
  2. multi-select using a variety of formats (check-boxes, radio buttons, lists), 
  3. filtering, and 
  4. dynamically refreshed options based on other parameter choices that users make.

Thus I thought that naming the plugin Uno-Choice was appropriate for two reasons:
  • One (Uno) control that could do it all and
  • Uno for the project behind it (BioUno.org)
In retrospect, perhaps I could have chosen a better name but having Bruno like it, sealed the deal! The rest is history as they say...
Bruno developed it, and here we are finally contributing it to empower all Jenkins users.

So, if the name could confuse new users how could we improve it?

Let me try to offer a few alternatives. 
  • BioUno Dynamic Choices
  • BioUno Scripted Choices
  • Dynamic Options Parameter
  • Scripted Options Parameter
Finally, we have to consider the effort required to rename the plugin (Bruno, WDYT? )

Thanks all for the feedback
Best regards
Ioannis

Daniel Beck

unread,
Feb 19, 2015, 1:59:19 AM2/19/15
to jenkin...@googlegroups.com

On 18.02.2015, at 22:01, Jesse Glick <jgl...@cloudbees.com> wrote:

> I would pick a plugin named “Dynamic Parameter”
> and skip right over “Uno Choice”.

There is already 'Dynamic Extended Choice' and 'Dynamic Parameter'. At least with the 'Uno' it has a less generic name and you're not going to confuse it with another plugin all the time.


domi

unread,
Feb 19, 2015, 2:21:04 AM2/19/15
to Jenkins Developers
To be honest, the “Uno” in the name stopped my from looking closer into it - because the name was just confusing…
…my 2cents
Domi
> --
> You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/81CE5C0F-3BAE-4C51-948F-70FA87DDA9A6%40beckweb.net.

Bruno P. Kinoshita

unread,
Feb 19, 2015, 10:17:08 AM2/19/15
to jenkin...@googlegroups.com
> Finally, we have to consider the effort required to rename the plugin (Bruno, WDYT? )

There will be some effort, and we can miss updating some Javadocs or Strings here or there. Some users already familiar with the Uno Choice name would have to be notified on the new name.

But if we agree on a new name, I'd gladly fire Eclipse, rename the artifact ID and update the Javadocs and any other reference to the old name that I can find :^)

Bruno


From: Ioannis Moutsatsos <imout...@gmail.com>
To: jenkin...@googlegroups.com
Sent: Thursday, February 19, 2015 12:36 AM

Subject: Re: New plug-in: Uno Choice Plug-in for dynamic parameters

All,

To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@ googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/ msgid/jenkinsci-dev/ 1979203684.442515. 1424305331365.JavaMail.yahoo% 40mail.yahoo.com.

For more options, visit https://groups.google.com/d/ optout.
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

Daniel Beck

unread,
Feb 19, 2015, 12:41:46 PM2/19/15
to jenkin...@googlegroups.com

On 19.02.2015, at 16:17, 'Bruno P. Kinoshita' via Jenkins Developers <jenkin...@googlegroups.com> wrote:

> rename the artifact ID

The old one will still be available in update center, and just be a dead end. Not sure whether we've ever removed anything (there are a few plugins where this happened and it's not pretty).

Bruno P. Kinoshita

unread,
Feb 19, 2015, 1:03:40 PM2/19/15
to jenkin...@googlegroups.com
Hi Daniel! 

The plug-in hasn't been released to the Jenkins update center yet, just to the update center hosted at BioUno - we do this because of some niche plug-ins (phylogenetics, PBS/Torque, etc).

If the plug-in proposal gets accepted here and we agree on a new name, we can then release it to all users under the new artifact id.

Cheers,
Bruno


From: Daniel Beck <m...@beckweb.net>
To: jenkin...@googlegroups.com
Sent: Thursday, February 19, 2015 3:47 PM

Subject: Re: New plug-in: Uno Choice Plug-in for dynamic parameters
On 19.02.2015, at 16:17, 'Bruno P. Kinoshita' via Jenkins Developers <jenkin...@googlegroups.com> wrote:

> rename the artifact ID

The old one will still be available in update center, and just be a dead end. Not sure whether we've ever removed anything (there are a few plugins where this happened and it's not pretty).

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsub...@googlegroups.com.

Daniel Beck

unread,
Feb 19, 2015, 1:04:41 PM2/19/15
to jenkin...@googlegroups.com
Sorry, forgot about that.

On 19.02.2015, at 19:03, 'Bruno P. Kinoshita' via Jenkins Developers <jenkin...@googlegroups.com> wrote:

> Hi Daniel!
>
> The plug-in hasn't been released to the Jenkins update center yet, just to the update center hosted at BioUno - we do this because of some niche plug-ins (phylogenetics, PBS/Torque, etc).
>
> If the plug-in proposal gets accepted here and we agree on a new name, we can then release it to all users under the new artifact id.
>
> Cheers,
> Bruno
>
> From: Daniel Beck <m...@beckweb.net>
> To: jenkin...@googlegroups.com
> Sent: Thursday, February 19, 2015 3:47 PM
> Subject: Re: New plug-in: Uno Choice Plug-in for dynamic parameters
>
>
> On 19.02.2015, at 16:17, 'Bruno P. Kinoshita' via Jenkins Developers <jenkin...@googlegroups.com> wrote:
>
> > rename the artifact ID
>
> The old one will still be available in update center, and just be a dead end. Not sure whether we've ever removed anything (there are a few plugins where this happened and it's not pretty).
>
> --
> You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
> --
> You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/271565627.716651.1424369013143.JavaMail.yahoo%40mail.yahoo.com.

Jesse Glick

unread,
Feb 20, 2015, 3:33:15 PM2/20/15
to Jenkins Dev
On Thu, Feb 19, 2015 at 10:17 AM, 'Bruno P. Kinoshita' via Jenkins
Developers <jenkin...@googlegroups.com> wrote:
> rename the artifact ID and update the Javadocs and any other reference to the old name

To be clear, I was not suggesting a change of artifactId, package
names, etc. Just the display name (pom.xml#<name>, and wiki title).

Daniel Beck

unread,
Feb 20, 2015, 5:16:04 PM2/20/15
to jenkin...@googlegroups.com

On 20.02.2015, at 21:33, Jesse Glick <jgl...@cloudbees.com> wrote:

> Just the display name (pom.xml#<name>, and wiki title).

We have a minor issue with issue tracker components when display name and artifact ID are different, especially at the start of the name.

Ioannis Moutsatsos

unread,
Feb 27, 2015, 9:47:04 AM2/27/15
to jenkin...@googlegroups.com, m...@beckweb.net
What do you all think about  naming the plugin 'Active Choices Plugin' . The plugin would then add 3 new parameter types:
  1. Active Choices [aka Uno-Choice Dynamic Choice]
  2. Re-Active Choices [aka Uno-Choice Cascade Dynamic]
  3. Re-Active References [aka Uno-Choice Dynamic Reference]
The 'Re-active' prefix perhaps would fit well with the main function of these parameter which is to actively react to changes in other submission form UI parameters.

Bruno P. Kinoshita

unread,
Mar 30, 2015, 4:09:26 PM3/30/15
to jenkin...@googlegroups.com, m...@beckweb.net
Bump anyone?

+1 / -1 for Jenkins Active Choices Plug-in? Any other suggestion?

Cheers
Bruno


From: Ioannis Moutsatsos <imout...@gmail.com>
To: jenkin...@googlegroups.com
Cc: m...@beckweb.net
Sent: Friday, February 27, 2015 11:47 AM

Subject: Re: New plug-in: Uno Choice Plug-in for dynamic parameters
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

Kanstantsin Shautsou

unread,
Mar 31, 2015, 5:01:28 PM3/31/15
to jenkin...@googlegroups.com, m...@beckweb.net, brunod...@yahoo.com.br
Maybe i already suggested not to use "Jenkins" word, just "XXX plugin"

"Re-active" prefix is not obvious for me...

Bruno P. Kinoshita

unread,
Mar 31, 2015, 6:24:03 PM3/31/15
to jenkin...@googlegroups.com, m...@beckweb.net
>Maybe i already suggested not to use "Jenkins" word, just "XXX plugin"

Agreed, we can drop the Jenkins prefix.

>"Re-active" prefix is not obvious for me...

Would you have other suggestions? Unfortunately I'm horrible choosing names :)

Thanks
Bruno



From: Kanstantsin Shautsou <kanstan...@gmail.com>
To: jenkin...@googlegroups.com
Cc: m...@beckweb.net; brunod...@yahoo.com.br
Sent: Tuesday, March 31, 2015 6:01 PM

Bruno P. Kinoshita

unread,
Apr 21, 2015, 9:06:58 AM4/21/15
to jenkin...@googlegroups.com
Bump again :)

What about renaming the plug-in at the repository


To "Active Choices Plug-in" as Ioannis suggested?

The plug-in provides parameter types that can be updated based on other parameter values in the UI. We have already some users downloading the plug-in either manually or from our update center, but we really would like to make it available to all users.

Thank you!
Bruno


From: 'Bruno P. Kinoshita' via Jenkins Developers <jenkin...@googlegroups.com>
To: "jenkin...@googlegroups.com" <jenkin...@googlegroups.com>
Cc: "m...@beckweb.net" <m...@beckweb.net>
Sent: Wednesday, April 1, 2015 11:20 AM

Kanstantsin Shautsou

unread,
Apr 21, 2015, 11:10:36 AM4/21/15
to jenkin...@googlegroups.com
imho sounds ok. 
But not very like “Re-active” for other plugin names.
You received this message because you are subscribed to a topic in the Google Groups "Jenkins Developers" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jenkinsci-dev/qUBLhE-4ybY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/1188114509.559863.1429621432095.JavaMail.yahoo%40mail.yahoo.com.

Bruno P. Kinoshita

unread,
Apr 22, 2015, 7:43:49 PM4/22/15
to jenkin...@googlegroups.com
Thanks Kanstantsin!

If there are no objections maybe someone with karma could clone it, and then I would fix the plug-in name in the code before the 1.0 release :)

Bruno


From: Kanstantsin Shautsou <kanstan...@gmail.com>
To: jenkin...@googlegroups.com
Sent: Wednesday, April 22, 2015 3:10 AM
Subject: Re: Release Active Choices Plug-in (was: Re: New plug-in: Uno Choice Plug-in for dynamic parameters)

Ullrich Hafner

unread,
Apr 28, 2015, 7:50:56 AM4/28/15
to jenkin...@googlegroups.com
signature.asc

Edwin Floyd

unread,
Jun 5, 2015, 11:00:49 AM6/5/15
to jenkin...@googlegroups.com
We currently have about 140 jenkins projects defined in our production
Jenkins environment, around 40 of which depend heavily on a 0.20-snapshot
version of uno-choice. As of yesterday, the 1.0 release of uno-choice is
available here <http://updates.jenkins-ci.org/download/plugins/uno-choice/>
,
so I downloaded it and installed in our jenkins-testing environment. It
immediately broke every one of the 40 projects that depend on the previous
uno-choice version. Apparently, the 1.0 version does not migrate
configurations from the 0.20 version? I can see how to manually convert
each parameter using the ui, and intend to do this on a representative
sample to verify that the new release works for us. But, our development
teams are utterly dependent on the production Jenkins environment so I am
reluctant to bring that down for the length of time necessary to manually
convert all 40 projects. Is there a plan to migrate configurations from
previous versions of uno-choice? Is there a manual migration process that we
could maybe script for our confgurations? What do you advise?



--
View this message in context: http://jenkins-ci.361315.n4.nabble.com/New-plug-in-Uno-Choice-Plug-in-for-dynamic-parameters-tp4739241p4754181.html
Sent from the Jenkins dev mailing list archive at Nabble.com.

Ioannis Moutsatsos

unread,
Jun 5, 2015, 11:08:58 AM6/5/15
to jenkin...@googlegroups.com, efl...@tsys.com
Sorry to hear about your problems Edwin! 

Unfortunately after about version 0.21 the code updates were not longer backward compatible.
This was discussed extensively on this dev list and I must say I also experienced similar 'growing pains'

Please, take a look at this wiki entry [1] for some help on how I migrated large numbers of projects to the new code base.
I hope it's somewhat helpful although it is is still a manual update process.


Best regards
Ioannis

Edwin Floyd

unread,
Jun 5, 2015, 12:26:24 PM6/5/15
to jenkin...@googlegroups.com
Thank you, Ioannis, I had not seen the wiki entry. It is very helpful. I'm
considering attempting a groovy script to automate parts of the migration.
Will share with you if anything comes of it.
-- Edwin



--
View this message in context: http://jenkins-ci.361315.n4.nabble.com/New-plug-in-Uno-Choice-Plug-in-for-dynamic-parameters-tp4739241p4754192.html

Ioannis Moutsatsos

unread,
Jun 5, 2015, 12:52:10 PM6/5/15
to jenkin...@googlegroups.com, efl...@tsys.com
That would be great!
Thank you!
Ioannis
Reply all
Reply to author
Forward
0 new messages