Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-44783

HP Automation Tools Plugin & Building Pipeline activity to "RunLoadrunnerscript"

    Details

    • Similar Issues:
    • Epic Link:

      Description

      We are currently exploring "hp-application-automation-tools-plugin: 5.1.0.2 - beta. We had a requirement of instead of running VuGen script using mdrv.exe command it is better if there is a plugin that manages on its own to invoke mdrv.exe on the node and provides Run status with PASS/FAIL status for Transactions. In the Beta version our requirement is almost met and we were able to create Jenkins build & execute to invoke VuGen script by using "Run LoadRunner Script" step.
      However, our final objective of using the Plugin is to build a pipeline script in CI/CD flow.
      In that process, I have created as below using Pipeline syntax :
       
      stage('RunLRScriptDallasLG')
      {
          node('Dallas_LG_386')
          {
              RunLoadRunnerScript 'C:\\LR\\Projects\\MINA\\MINA_WebServices_01
      MINA_WebServices_01.usr'
             
          }
         
      }
       
      while saving the build and after executing it, I see below exception:
      org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
      WorkflowScript: 5: unexpected token: C:\LR\Projects\MINA\MINA_WebServices_01\MINA_WebServices_01.usr @ line 5, column 29.
                 RunLoadRunnerScript 'C:\\LR\\Projects\\MINA\\MINA_WebServices_01
      MINA_WebServices_01.usr'
                                     ^

      1 error

      at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:310)
      at org.codehaus.groovy.control.ErrorCollector.addFatalError(ErrorCollector.java:150)
      at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:120)
      at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:132)
      at org.codehaus.groovy.control.SourceUnit.addError(SourceUnit.java:360)
      at org.codehaus.groovy.antlr.AntlrParserPlugin.transformCSTIntoAST(AntlrParserPlugin.java:145)
      at org.codehaus.groovy.antlr.AntlrParserPlugin.parseCST(AntlrParserPlugin.java:111)
      at org.codehaus.groovy.control.SourceUnit.parse(SourceUnit.java:237)
      at org.codehaus.groovy.control.CompilationUnit$1.call(CompilationUnit.java:167)
      at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:931)
      at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:593)
      at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:569)
      at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:546)
      at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298)
      at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268)
      at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688)
      at groovy.lang.GroovyShell.parse(GroovyShell.java:700)
      at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:67)
      at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:429)
      at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:392)
      at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:221)
      at hudson.model.ResourceController.execute(ResourceController.java:98)
      at hudson.model.Executor.run(Executor.java:405)
      Finished: FAILURE
       
      Could you please help me in fixing the issue. I am suspecting as the plugin is in Beta version & it is not yet supported for Pipeline script?.

        Attachments

          Activity

          Hide
          yafim_kazak Yafim Kazak added a comment -

          We do support pipeline it seems more as jenkins / Grovvy problem.

          Does the command line was generated using the pipeline script generator?

           

          i wil try to reproduce and update.

          Show
          yafim_kazak Yafim Kazak added a comment - We do support pipeline it seems more as jenkins / Grovvy problem. Does the command line was generated using the pipeline script generator?   i wil try to reproduce and update.
          Hide
          schand16 Sharath Chandra added a comment -

          Yes, command was generated by Pipeline script generator. Please keep us posted.

          Show
          schand16 Sharath Chandra added a comment - Yes, command was generated by Pipeline script generator. Please keep us posted.
          Hide
          yafim_kazak Yafim Kazak added a comment - - edited

          Hi please try the following hot fix:
          https://ci.appveyor.com/api/buildjobs/8bkd5j7hgw7a2akp/artifacts/target%2Fhp-application-automation-tools-plugin.hpi

          Note: we changed the name of the step to RunLoadRunnerScript

          Show
          yafim_kazak Yafim Kazak added a comment - - edited Hi please try the following hot fix: https://ci.appveyor.com/api/buildjobs/8bkd5j7hgw7a2akp/artifacts/target%2Fhp-application-automation-tools-plugin.hpi Note: we changed the name of the step to RunLoadRunnerScript
          Hide
          schand16 Sharath Chandra added a comment -

          Thanks Yafim for providing an update with fix.

          I have added the plugin and created new script. Now am no more seeing the exception that I reported before. But, I do see another Error after I run the script. Below are details:

          Pipeline script used:

          stage('RunLRScriptDallasLG')
           {
               node('Dallas_LG_386')
                  {
                   runLoadRunnerScript 'C:\\LR\\Projects\\MINA\\MINA_WebServices_01
          MINA_WebServices_01.usr'
                  }
              
           }

          Output:

          Started by user anonymous
          [Pipeline] stage [Pipeline] { (RunLRScriptDallasLG) [Pipeline] node Running on <<Dallas_LG_386>> in C:\Jmeter_Agent\workspace\MINA_PerfTest
          [Pipeline] { [Pipeline] runLoadRunnerScript Running LoadRunner Script Runner step
          ERROR: Failed loading node in pipeline script run
          [Pipeline] } [Pipeline] // node [Pipeline] } [Pipeline] // stage [Pipeline] End of Pipeline Finished: FAILURE

          I have tried with just Echo " hello" command in the script and it ran Successfully.

          Please let me know if it worked fine at your end.

           

           

          Show
          schand16 Sharath Chandra added a comment - Thanks Yafim for providing an update with fix. I have added the plugin and created new script. Now am no more seeing the exception that I reported before. But, I do see another Error after I run the script. Below are details: Pipeline script used: stage('RunLRScriptDallasLG')  {      node('Dallas_LG_386')         {          runLoadRunnerScript 'C:\\LR\\Projects\\MINA\\MINA_WebServices_01 MINA_WebServices_01.usr'         }       } Output: Started by user anonymous [Pipeline] stage [Pipeline] { (RunLRScriptDallasLG) [Pipeline] node Running on <<Dallas_LG_386>> in C:\Jmeter_Agent\workspace\MINA_PerfTest [Pipeline] { [Pipeline] runLoadRunnerScript Running LoadRunner Script Runner step ERROR: Failed loading node in pipeline script run [Pipeline] } [Pipeline] // node [Pipeline] } [Pipeline] // stage [Pipeline] End of Pipeline Finished: FAILURE I have tried with just Echo " hello" command in the script and it ran Successfully. Please let me know if it worked fine at your end.    
          Hide
          yafim_kazak Yafim Kazak added a comment - - edited
          Show
          yafim_kazak Yafim Kazak added a comment - - edited Hi, I think I was able to reproduce and solve - please verify: https://ci.appveyor.com/api/buildjobs/qnac01rj74pbf67e/artifacts/target%2Fhp-application-automation-tools-plugin.hpi
          Hide
          schand16 Sharath Chandra added a comment -

          Thanks Yafim.

          I did applied the latest plugin and replayed Pipeline script. It was successful, could see the loadrunner report in the Jenkins Run.

          Hopefully, it will run smoothly from now on. You may close the issue at your convenience.

          Appreciate your assistance.

          Show
          schand16 Sharath Chandra added a comment - Thanks Yafim. I did applied the latest plugin and replayed Pipeline script. It was successful, could see the loadrunner report in the Jenkins Run. Hopefully, it will run smoothly from now on. You may close the issue at your convenience. Appreciate your assistance.
          Hide
          yafim_kazak Yafim Kazak added a comment -

          Happty to hear, will be included in our close formal release!

          Show
          yafim_kazak Yafim Kazak added a comment - Happty to hear, will be included in our close formal release!

            People

            • Assignee:
              yafim_kazak Yafim Kazak
              Reporter:
              schand16 Sharath Chandra
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: