Performance Testing

LoadRunner How to Run LR in Jenkins Continuous Integration

By Test Guild
  • Share:
Join the Guild for FREE

Jenkins and LoadRunner

I was recently asked if it was possible to integrate LoadRunner with Jenkins. I was not sure but after some research, it turns out that it is possible. Basically, all you need to do is setup Jenkins to use the Jenkins HP Application Automation Tools add-in and configure it to point to you LoadRunner Scenario info.

Jenkins HP Application Automation Tools add-in

I knew that this Jenkins plugin worked with ALM and QTP/UFT but it was news to me that is also works with HP LoadRunner 11.52. This add-in allows you to enable a trigger for LoadRunner Scenarios as a build step, and its results will show up in the Jenkins results dashboard.

Jenkins Setup

To start using the HP Application Automation Tools with LoadRunner you need to do the following setup work in Jenkins:

First, install the Jenkins HP Application Automation Tools add-in

1) In your Jenkins instance, navigate to the Manage Jenkins area and click on the Manage Plugins link.


2) Click on the Available Tab.

3) Under the Filter text box, enter HP.

4) Under the Available tab, look for the name HP Application Automation Tools.


5) Click on the Install checkbox and click on the Download Now and Install After
Restart button.

Configure Jenkins

Once the add-in is installed and you have restarted Jenkins:

  1. Click on the Jenkins>New Job menu option.
  2. Enter a Job Name – I named my RunLoadrunner – and click on the Build a free-style software project option. Click OK


  3. Under the your new project's configuration scroll down to the Build section and click on the Add build step and click on the Execute HP tests from file system option


  4. Under Build you should now have an option for LoadRunner-Specific Settings.. – Click on it.


  5. Under the LoadRunner Settings enter the following:
  • Controller Polling Interval – the time to poll the LR Controller for your scenario status
  • Scenario Execution Timeout – this is the total time for the execution of all your scenarios
  • Errors to Ignore – – during the run you can tell which errors to ignore


  1. Under the Build/Tests section enter the path to your LoadRunner scenario. For example, my scenario named JnekinsDebug.lrs lives under my D:\myLoadRuner directory. So my Tests field = D:\myLoadRunner


  2. Under the Post-build Actions section click on the Add post-build action and select Publish HP tests result


  3. Apply and Save your settings
  4. Run the LR job you just created like you would any standard Jenkins job

Set LoadRunner Scenario SLA

One thing to watch out for is to make sure that your scenario has a SLA defined. If it does not your Jenkins job will fail with a message similar to this:


To fix just go into your Scenario in the LoadRunner Controller and add a SLA:


LR Jenkins CI Wrap-up

That is how you integrate LoadRunner with Jenkins. Hope it helps. Let me know if I missed anything.

  1. Hi Joe, your website is the best! How would these directions differ for UFT 11.52?

    As warned by HP, “only scenarios with defined SLA’s are allowed (others will be marked as “failed” without execution)” and it looks like this is probably my problem:

    10/10/2013 08:08:54 Running: C:\tests\test1
    Running test: C:\tests\test1
    Test result: Failed
    10/10/2013 08:09:17 Test complete: C:\tests\test1

  2. On a second look, I’m guessing Scenario is a term specifically used in LoadRunner, so I’m not entirely clear why my functional test is failing right off the bat.

  3. Hi Matt – in the bottom of my post I talk about this issue sometime being caused by not specifying an SLA in your LR Scenario. To fix just go into your Scenario in the LoadRunner Controller and add a SLA. Did this not work for you?

  4. Hi Joe, I have Functional Tests in UFT 11.52 which are failing without executing, so I don’t know if the issue is that I haven’t applied an SLA as is described for Load Runner Scenarios or if it’s just a coincidence that some other configuration issue within UFT or my tests is causing my tests to fail without executing.

    I do believe it’s on that side though and not an issue with Jenkins or the plugin, because when I modify the path to the test (i.e. in Step 5.1 above) the Jenkins build log then shows a different error “There are no valid tests to run!” which would indicate that the unedited path is to a valid test. For reference, the path I’m providing to Jenkins contains the Action0 and Action1 folders.

  5. Hi Joe, I’m not sure what did the trick, but Jenkins is now successfully able to run my test. Thanks just the same.

  6. Hi Joe,
    i am getting error:
    Building in workspace C:\.jenkins\jobs\test\workspace
    [workspace] $ C:\.jenkins\jobs\test\workspace\HpToolsLauncher.exe -paramfile props28072014211040484.txt
    “Started…”
    1 tests found:
    D:\XXXX\TestScenario.lrs
    ============================================================================
    Error: LoadRunner is not installed on INFPU05852.
    Build step ‘Execute HP tests from file system’ changed build result to ABORTED
    Report not found
    Finished: ABORTED

    Any idea, wha i might poin to ?

  7. Hello Joe,

    I have defined the SLA in LoadController as Transaction Response time (Percentile). Even though I have clearly named all my transactions the console output i get is as below without the transaction name. Is there something else I need to do when defining SLA’s?

    SLA report:
    ================================
    Full Name : Transaction Response Time (Percentile)
    Measurement : PercentileTRT
    Goal Value : 4
    Actual value : 0.314
    status : Passed

  8. Hi am getting below error,Any odea

    [EnvInject] – Loading node environment variables.
    Building remotely on marshall-slave-db-01 (db) in workspace /home/marshall/jenkins/build-slaves/db/workspace/Loadrunner_job
    [Loadrunner_job] $ /home/marshall/jenkins/build-slaves/db/workspace/Loadrunner_job/HpToolsLauncher.exe -paramfile props16022015164402527.txt
    Build step ‘Execute HP tests from file system’ changed build result to FAILURE
    Build step ‘Execute HP tests from file system’ marked build as failure
    [BFA] Scanning build for known causes…

    [BFA] Done. 0s
    Finished: FAILURE

  9. Hi Joe,

    I m using Loadrunner 11.0
    and Jenkins error says Error: The LoadRunner version must be 11.52 or higher.

    so i cant use this jenkins interegation to LoadRunner 11.0???
    if we can, Could u please tell how??

  10. I have been trying for several weeks to get the HP Automation Tools plugin to work with LoadRunner 12.5. I had it working back in 2015 with LoadRunner 11.52, but I did not like the results.

    Now I am getting this error:

    Load Generator localhost connected
    setting scenario result folder to C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\LRR
    scenario result folder: C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\LRR
    Starting scenario…
    controller failed to write to C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\LRR setting result folder to C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\ciresults00
    controller reult dir: ciresults00
    Scenario C:\ci\EID\ControllerScenarios\citest.lrs ended after 0:2:30.

    Because of the above, I then get this error:

    closing Controller
    Controller closed
    calling analysis report generator
    executing Analysis launcher with arguments : “C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\LRR\LRR.lrr” “C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\LRA\LRA.lra” “C:\jenkins\workspace\Performance_Testing_EID_Production\18b72f\HTML\HTML.html”
    time for analysis: 00::00:10:00
    starting analysis launcher
    creating analysis COM object
    creating analysis session
    Result loading failed. Log has been saved to: “c:\temp\Ana_963405845.log”
    at Analysis.ApiSL.ApiSlRuntimeErrors.Throw(Int32 aErrorCode, ApiException aException)
    at Analysis.ApiSL.ApiSlRuntimeErrors.UnsafeCode(UnsafeCodeHandlerBool aHandler, Int32 aLraErrorCode)
    at Analysis.Api.Session.CreateWithTemplateFile(String aSessionName, String aResultFileName, String aTemplateFileName)
    at LRAnalysisLauncher.Program.Main(String[] args)
    time passed: 00::00:00:00
    Error: Error during Analysis run. See output console for details
    analysis report generator finished

    I have been trying to work with HP to resolve my issues but so far no luck.

  11. Sorry Randy – did you get this resolved? I honestly have not tried it in newer versions of LoadRunner so I’m not sure why this is happening

  12. How it will get to know that it has to execute JnekinsDebug.lrs file only, as we are mentioning path only in Tests?

    In my case I have created job but it is not running and showing below error:
    (pending—DirectLoadRunnerNode is reserved for jobs with matching label expression) and it is not starting build as well.

  13. Hi All,

    I had run the load runner script successfully. However I am getting standard error message “Controller is still running”

    Any workaround to resolve this?

    Please find below code which i recieved from Console Ouput:

    saving RunReport.xml to C:\Program Files (x86)\Jenkins\workspace\MyLoadRunner\fad348\RunReport.xml
    saving SLA.xml to C:\Program Files (x86)\Jenkins\workspace\MyLoadRunner\fad348\SLA.xml
    closing analysis session
    time passed: 00::00:00:52
    analysis report generator finished
    Error(s) summary:
    0 ignored , 0 errors

    Test result: Passed
    07/04/2017 11:39:39 Test complete: C:\LoadRunnerScripts\Scenario1.lrs
    ——————————————————————————————————-
    Cleaning up the environment…
    Standard Error
    Error: The Controller is still running…

Comments are closed.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

6 Must Run Performance Tests for Black Friday

Posted on 11/21/2024

Regarding e-commerce, Black Friday is the ultimate test of endurance. It's one of ...

Unlock the Power of Continuous Performance Engineering

Posted on 03/25/2024

With the current demand for software teams to high quality product in a ...

16 Top Load Testing Software Tools for 2024 (Open Source Guide)

Posted on 03/12/2024

In the world of software development, testing is vital. No matter how well ...