How to record and replay against a JAR executable

Configure VuGen to record using details from the application`s Manifest.mf file

1. Expand the JAR file using the WinZip utility, and look for the Manifest.mf file.
2. View the manifest file using Notepad, taking note of the defined "Class-Path:" and "Main-class:" sections.
3. Launch VuGen, and select "New Single Protocol, RMI-Java script."
4. At the "Start Recording" prompt, select/define the following:

Application Type: {select Java Application}
App. Main Class: {define as stated in "Manifest.mf" file’s Main-Class}
Working Directory: {Working directory of application}

5. Click on the "Options" button to access the Recording Options. Proceed to the Java Environment Settings: Classpath definition, and add in all the classpath entries as defined in the Manifest.mf file’s Class-Path.
6. If any additional VM parameters are used (e.g., -Djava.naming.provider.url="iiop://websphere"), proceed to define them in Java Environment Settings: Java VM.

Example:
Additional VM Parameters: -Djava.naming.provider.url="iiop://websphere"

Note:
Make sure to add "-Xbootclasspath/p:<LoadRunner>\classes;<LoadRunner>\classes\srv" to the Additional VM Arguments.

7. Start recording.

Note:
For successful replay, ensure that the classpath definitions in the Run-Time Settings are set accordingly as well (same as in Recording Options).

READ  VuGen fails to save the parameter specified in the RunTime Setting in "Additional VM Parameters" in "default.cfg" correctly

Leave a Comment