Solving VuGen Script Generation Errors
On very rare occasions you may encounter a web-based application that causes VuGen to throw an error during code generation. Every time this has happened to me, it has been solvable without having to talk to HP Software Support. Read on for my tips…

When this problem occurs, you will see that both the Recorded Events Log and the Recording log show that HTTP requests and responses have been captured, but the Code Generation Log is empty.



Fortunately, it is usually not even necessary to re-record the script, because VuGen has a neat “Regenerate Script” feature, which will allow you to experiment with the different recording settings that are applied during the VuGen code generation stage.

Note that when you regenerate your script, it will overwrite any changes you have made to the code. But comments and transactions added during recording and any correlation performed automatically with Correlation Rules will still be included in your newly generated script.

Regenerating the script as a URL-based script with “Use web_custom_request only” enabled is a work-around for some script generation problems, but it can result in a very verbose script to work with.

Changing the supported character set will sometimes solve code generation problems too. EUC-JP is a multi-byte format for representing characters from Asian langages (s0 I have never come across this one), but changing to UTF-8 (which is disabled by default in VuGen) has solved code generation problems for me several times.

Recording the script using the earlier recording engine sometimes solves code generation problems, but note that you actually do have to re-record the script using the old recording engine, you can’t just regenerate the script. Remember to restart VuGen after ticking the “Record script using earlier recording engine” checkbox or the new recording engine will still be used.
Recording the script with a Multiple Protocol vuser type, with Web and Windows Sockets (even though your application only sends and receives HTTP) sometimes also fixes code generation problems as this forces a different recording engine to be used. I am fairly sure that this just forces VuGen to use the same “earlier” recording engine mentioned previously, but cannot confirm without doing further investigation. This is worth a try anyway if you are still having problems.

So, in summary…
- Regenerate your script with a different recording mode (try “Use web_custom_request only”).
- Try a different character set. Check or un-check “Support charset UTF-8″
- Re-record the script with the old recording engine (remember to restart VuGen).
- Re-record the script with a Multiple Protocol Web + Windows Sockets vuser.
You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
April 19th, 2008 at 9:05 pm
Hello Stuart,
A bunch of Thanks to you, the above illustration has helped me to resolve the issue.
Great contribution from your side.
Thanks once again
Herbert
[Stuart's Reply: Glad that we could help, Herbert.]
June 6th, 2008 at 12:08 am
Hey,
THANKS a TON
the explanation given here is too good. It solved my problem so quickly.
Hats off to you.