Re: Build parameterization

2012-10-30 Thread LordShacks
Apologies for the delay in responding to my original post.

I think my original question may have been somewhat unclear as to what I
wanted to accomplish with Jenkins and the plugin I am trying to develop. I
will try to clarify:

At the moment I am using Jenkins simply to kick off a series of tests that
run to evaluate the health of a system, these tests take certain parameters
based on the status of the system at the time of testing. The status of the
system often changes and as a result the parameters required change
frequently as well.

Currently I am manually entering the parameters everytime I kick off the
tests using the Parameterize Build option. However this is time consuming.

Would it be possible to have a plugin that takes in a config file of all
possilbe parameters that could be used and present these to the user in the
Jenkins GUI, allowing the user to dynamically choose which parameters to use
each time the tests are started.

I realise this is somewhat outside the original purpose of Jenkins, however
the end user is currently using Jenkins to build their projects as well so
an all in one solution would be idea if possible.



--
View this message in context: 
http://jenkins.361315.n4.nabble.com/Build-parameterization-tp467p4644648.html
Sent from the Jenkins dev mailing list archive at Nabble.com.


Re: Build parameterization

2012-10-29 Thread LordShacks
I think my original question may have been somewhat unclear as to what I 
wanted to accomplish with Jenkins and the plugin I am trying to develop. I 
will try to clarify:

At the moment I am using Jenkins simply to kick off a series of tests that 
run to evaluate the health of a system, these tests take certain parameters 
based on the status of the system at the time of testing. The status of the 
system often changes and as a result the parameters required for 
testing change frequently as well.

Currently I am manually entering the parameters everytime I kick off the 
tests using the Parameterize Build option. However this is time consuming.

Would it be possible to have a plugin that takes in a config file of all 
possilbe parameters that could be used and present these to the user in the 
Jenkins GUI, allowing the user to dynamically choose which parameters to 
use each time the tests are started.

I realise this is somewhat outside the original purpose of Jenkins, however 
the end user is currently using Jenkins to build their projects as well so 
an all in one solution would be idea if possible.

On Friday, October 26, 2012 1:21:32 PM UTC+1, cjo wrote:

> From my point of view, this type of plugin would be useless as without 
> setting up the Job to use the parameter it is just another step that slows 
> the user from starting a build.
>
> For example the user adds a String parameter name MESSAGE with a value 
> "reason for building", 
> when is this going to be used in any of the build steps unless they have a 
> some code to check for it. 
> if it is checked e.g. if ($MESSAGE != "") then print $MESSAGE to file.txt
>
> However if the user has to add it, how are they to know the correct name 
> and what it does.
> so I would just add the parameter it as an option and leave the default to 
> "", with a description on how it affects the build.
>
> In most cases the current parameters can be setup to provide a standard 
> set of defaults that the build uses, (allowing the user to just accept 
> these values) while allowing them to be changed to provide behaviour for 
> the less often used cases.
>
> And from a security point of view if only I had access to create and 
> modify jobs, all other users can start them, I would not want other users 
> to be able to add extra parameters, over and above then ones that are 
> exposed with the job.
>
> Chris.
>
>
>
> On Friday, October 26, 2012 12:35:59 PM UTC+1, AdvanTiSS wrote:
>>
>> Could you describe usecase for that parameter?
>>
>> On Friday, October 26, 2012 1:54:20 PM UTC+3, LordShacks wrote:
>>>
>>> Hi 
>>>  
>>> I am currently attempting to write a Jenkins plugin that is similar to 
>>> the Parameterized Build option in the Configure Project page.
>>>  
>>> I want to create a plugin that lets the user specify the type of 
>>> parameter in addition to the parameter value when the Build Now button is 
>>> pressed.
>>>  
>>> As far as I can see there is no currently functionality in Jenkins that 
>>> allows the parameter type and value to be specified when a build is 
>>> scheduled.
>>>  
>>> I was wondering if it is possible to implement this feature in Jenkins.
>>>  
>>> Many thanks
>>>
>>

Re: Build parameterization

2012-10-27 Thread linards . liepins
The thing is such options are out of CI server scope - it is not about doing 
code/env altering @ runtime, but with standartized infrastructure, parameters 
and options. That is why it is Integration - you integrate codebase changes in 
continuous way. For such thing build infrastructure (apache ant / maven) is 
made.
I really suggest to think over or to learn more before dealing with CI stuff.




On 26/10/2012 13:54 LordShacks wrote:

Hi

I am currently attempting to write a Jenkins plugin that is similar to the 
Parameterized Build option in the Configure Project page.

I want to create a plugin that lets the user specify the type of parameter in 
addition to the parameter value when the Build Now button is pressed.

As far as I can see there is no currently functionality in Jenkins that allows 
the parameter type and value to be specified when a build is scheduled.

I was wondering if it is possible to implement this feature in Jenkins.

Many thanks



Re: Build parameterization

2012-10-26 Thread ari_hyttinen
What parameter types were you thinking of supporting? Can you describe a 
use case?

Almost all the parameters are essentially strings, and "parameter type" 
mostly relates to how value is asked from user when they trigger a build. 
User defining the parameter type too seems to make no sense to me.

On Friday, October 26, 2012 1:54:20 PM UTC+3, LordShacks wrote:
>
> Hi 
>  
> I am currently attempting to write a Jenkins plugin that is similar to the 
> Parameterized Build option in the Configure Project page.
>  
> I want to create a plugin that lets the user specify the type of parameter 
> in addition to the parameter value when the Build Now button is pressed.
>  
> As far as I can see there is no currently functionality in Jenkins that 
> allows the parameter type and value to be specified when a build is 
> scheduled.
>  
> I was wondering if it is possible to implement this feature in Jenkins.
>  
> Many thanks
>


Re: Build parameterization

2012-10-26 Thread cjo
>From my point of view, this type of plugin would be useless as without 
setting up the Job to use the parameter it is just another step that slows 
the user from starting a build.

For example the user adds a String parameter name MESSAGE with a value 
"reason for building", 
when is this going to be used in any of the build steps unless they have a 
some code to check for it. 
if it is checked e.g. if ($MESSAGE != "") then print $MESSAGE to file.txt

However if the user has to add it, how are they to know the correct name 
and what it does.
so I would just add the parameter it as an option and leave the default to 
"", with a description on how it affects the build.

In most cases the current parameters can be setup to provide a standard set 
of defaults that the build uses, (allowing the user to just accept these 
values) while allowing them to be changed to provide behaviour for the less 
often used cases.

And from a security point of view if only I had access to create and modify 
jobs, all other users can start them, I would not want other users to be 
able to add extra parameters, over and above then ones that are exposed 
with the job.

Chris.



On Friday, October 26, 2012 12:35:59 PM UTC+1, AdvanTiSS wrote:
>
> Could you describe usecase for that parameter?
>
> On Friday, October 26, 2012 1:54:20 PM UTC+3, LordShacks wrote:
>>
>> Hi 
>>  
>> I am currently attempting to write a Jenkins plugin that is similar to 
>> the Parameterized Build option in the Configure Project page.
>>  
>> I want to create a plugin that lets the user specify the type of 
>> parameter in addition to the parameter value when the Build Now button is 
>> pressed.
>>  
>> As far as I can see there is no currently functionality in Jenkins that 
>> allows the parameter type and value to be specified when a build is 
>> scheduled.
>>  
>> I was wondering if it is possible to implement this feature in Jenkins.
>>  
>> Many thanks
>>
>

Re: Build parameterization

2012-10-26 Thread AdvanTiSS
Could you describe usecase for that parameter?

On Friday, October 26, 2012 1:54:20 PM UTC+3, LordShacks wrote:
>
> Hi 
>  
> I am currently attempting to write a Jenkins plugin that is similar to the 
> Parameterized Build option in the Configure Project page.
>  
> I want to create a plugin that lets the user specify the type of parameter 
> in addition to the parameter value when the Build Now button is pressed.
>  
> As far as I can see there is no currently functionality in Jenkins that 
> allows the parameter type and value to be specified when a build is 
> scheduled.
>  
> I was wondering if it is possible to implement this feature in Jenkins.
>  
> Many thanks
>


Build parameterization

2012-10-26 Thread LordShacks
Hi 
 
I am currently attempting to write a Jenkins plugin that is similar to the 
Parameterized Build option in the Configure Project page.
 
I want to create a plugin that lets the user specify the type of parameter 
in addition to the parameter value when the Build Now button is pressed.
 
As far as I can see there is no currently functionality in Jenkins that 
allows the parameter type and value to be specified when a build is 
scheduled.
 
I was wondering if it is possible to implement this feature in Jenkins.
 
Many thanks