How to record and replay against a JAR executable

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

1. Expand the JAR file using the WinZip utility, and look for the 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 "" 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 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.

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

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

7. Start recording.

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

Leave a Comment