Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9097049
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T00:00:51+00:00 2026-06-17T00:00:51+00:00

I am using Jenkins with Testswarm and this plugin ( forked sources ). I

  • 0

I am using Jenkins with Testswarm and this plugin (forked sources).

I want to get a “job name” for Testswarm containing the Jenkins job name, build number and svn revision number.

Putting JOB_NAME in the configuration field does not help, the variable is not replaced by its value.

So I modified the plugin source code to get the Jenkins environment variables but all I get are “null”s.

Here is the culprit code. (in src/main/java/com/javaclimber/jenkins/testswarmplugin/TestSwarmBuilder.java from line 205)

I researched a lot concerning this functionnality and I did not find a working example for getting a variable.

public boolean perform(AbstractBuild build, Launcher launcher, BuildListener listener) throws InterruptedException, IOException {
    ...
EnvVars envVars = build.getEnvironment(listener);
    ...
    envVars.get("JOB_NAME")
}

I am not at ease in Java and I am stuck at this point.
Any idea anyone, please ?

Update: java used version
java version “1.6.0_24”
OpenJDK Runtime Environment (IcedTea6 1.11.5) (6b24-1.11.5-0ubuntu1~10.04.2)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T00:00:52+00:00Added an answer on June 17, 2026 at 12:00 am

    Replacing

    EnvVars envVars = build.getEnvironment(listener);
    

    By

    EnvVars envVars = new EnvVars();
    envVars = build.getEnvironment(listener);
    

    did the trick…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using jenkins with svn repository. Usually I want only to update svn
When using the Groovy Jenkins plugin (not the Groovy Post Build Plugin, which is
Using Jenkins ver. 1.494; Jenkins Sonar Plugin 2.0.1 ; Sonar server 3.4.1. Maven job.
I get following exception when building using Jenkins. This exception raises after running Cucumber
I'm using Jenkins and Bitbucket with the Mercurial plugin on windows. Every time I
I'm running a maven project using Jenkins. The project is using the checkstyle plugin
I'm trying to set up Jenkins (v1.47) to build a project using the ClearCase
I am using check_http plugin for discovering jenkins service(Winstone hosted and Apache hosted) is
I am using SVN as my source control repository and Jenkins as my CI
This used to work before I upgraded Jenkins to 1.494. Now I get this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.