Hi,

I guess you can use the below plugins:

 - EnvInject plugin 
(https://wiki.jenkins-ci.org/display/JENKINS/EnvInject+Plugin)
 - Parameterized+Trigger+Plugin 
(https://wiki.jenkins-ci.org/display/JENKINS/Parameterized+Trigger+Plugin)

You can either create a properties file during the build process and run a 
postbuild action -> Trigger another projects based on a properties file, or 
inject those properties using the env inject plugin and another post build 
action with those parameters.

There are different approaches but those are the ones off the top of my 
head.

Cheers

On Wednesday, 26 August 2015 14:57:54 UTC+2, 文宾 王· wrote:
>
> Hi all, 
>
> I would like to put some our own variables into jenkins job build 
> environment variables during build execution. how could I do it? how 
> to access the jenkins object model? 
>
> Saying, I have a job named A, and we run a java application as its 
> step, in the java application, I need to put some own variables into 
> the build environment variables during build execution, these 
> variables might be transferred 
> to downstream jobs by existing plugin. 
>
> So, how to add variables into build env variables? 
> what`s the extension points for that?   
>
> I found BuildVariableContributor, might be it is the extension point to 
> add my variables into build env, but when and how would it be triggered? 
> since I need to trigger adding variables from my java application, how to 
> do it?  is it possible to get the handle of running build of given name job?
>
> Thanks for any clues. 
>
> Thanks 
>
> Regards, 
> Grrison 
>
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/cb2f9ea4-de04-468a-bafd-360a37c2d14e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to