Blog

  • Programmatically Create A Unique Parameter Name

    Posted on June 11, 2009 by Admin

    Lets say you need to grab a list of items or numbers from a web page, such as GUID’s. These are not dynamic numbers, but will be used in a script as parameters. Here is how I captured the data I wanted and created my own DAT file:

    Figure out the format you want the DAT file to be in. For me, this was a GUID, another GUID, and a user ID. I created a file and put the top line in with the headers GUID1, GUID2, LOGIN and saved it to my C: drive in the root folder. I already knew the login so I had already set this up a a paramet Read Entire Entry

  • MI Listener: Additional Trace Logs For Debugging

    Posted on June 3, 2009 by Admin

    Did you know there is a deeper level of logging in the MI Listener Aganet? The following can be done if you are having problems with the MI_Listener and the Generator to determine connectivity issues.

    kill the agent processes on all the machines
    append to [launcher] section at launch_service\dat\mdrv.dat the following line:
    ExtCmdLine=-drv_int_msgs -drv_log_flush

    Activate agents on all the machines and try to connect.
    collect log file generated (%TEMP%\LoadRunner_agent_startup.log).

    You will need these logs when submi Read Entire Entry

  • LoadRunner VuGen: What’s Up With SPRINTF?

    Posted on May 27, 2009 by Admin

    In my custom load testing class, we usually get into specific code examples that demonstrate how to do some tips and tricks in VUGen. One of the things I always like to bring up is the behavior or sprintf. This is a commonly used C function for string manipulation. Many a young LoadRunner lad has come across the dreaded memory violation error in their output log when using sprintf:
    Error: C interpreter run time error: Action.c (10): Error — memory violation : Exception ACCESS_VIOLATION received.
    Let’s look at why. Here is some code: Read Entire Entry

  • LoadRunner VuGen: Fixing Corrupted Winsock Libraries

    Posted on May 25, 2009 by Admin

    I was trying out the new Protocol Advisor in LoadRunner 9.5 this week, and I found it was not working as advertised. It wasn’t even recommending WEB as a protocol choice for recording a simple web script. Not good. The only thing it did recommend to me properly was RDP. If a person cannot figure out they are using RDP when they launch an RDP window, they probably should not be using LoadRunner. 🙂 I decided to dig a bit deeper and found I had discovered a bigger problem.

    On my past several engagements, I had been using the client Read Entire Entry

  • VuGen: Dynamic data in web_submit_data

    Posted on May 5, 2009 by Admin

    This was developed as a result of load testing a bridal registry site written with BlueMartini. There needed to be a way for the Vuser to clean up its bridal registry at the end of each iteration. However, I couldn’t be assured of a specific number of items (because the item catalog changed frequently, and we varied the number of items added).

    The web_submit_data function looks for a symbolic “LAST” to determine when it has reached the end of a variable argument list. This was modified by inserting it into a predefined argumen Read Entire Entry

  • VuGen Custom Function: xstrcat

    Posted on April 23, 2009 by Admin

    // – – – – – – – – – – – – – – – – – – – – – – – – – – – – – –
    // Brian Wilson – TechSouth, LLC
    // – – – – – – – – – – – – – – – – – – – – – – – – – – – – – –

    // – – – – – – – – – – – – – – – – – – – – – – – – – – – – – –
    // xstrcat()
    // more efficient version of strcat
    // – – – – – – – – – – – – – – – – – – – – – – – – – – – – – –
    char *xstrcat( char *dest, char *src )
    {
    while (*dest) dest++;
    while (*dest++ = *src++);
    return –dest;
    }
    /*char * xstrcat(char * dest, const char * src) // alternate version Read Entire Entry

  • VuGen: Replace Special Characters

    Posted on April 14, 2009 by Admin

    This function (called EncodeText) may be a bit out of date, but can be used to replace special characters and use different encoding. You could put this in the very top of the vuser_init section of your script, or in the globals.h or other include file.
    //——begin code—————
    EncodeText(New,Orig)
    char *New;
    char *Orig;
    {
    int New_index;
    int Orig_index;
    int len;

    len = strlen(Orig);
    New_index = 0;
    for (Orig_index=0;Orig_index<len;Orig_index++) {
    Read Entire Entry

  • VuGen RTE Protocol: Autogenerate Transactions

    Posted on April 2, 2009 by Admin

    /*

    This custom RTE function will auto generate a transaction timing
    for every TE_wait_text. Paste this code into the top of your script,
    or use as an include file.
    Replace TE_wait_text with this function called TE_custom_wait_text
    using the search and replace tool.

    */

    int TE_custom_wait_text ( char * text, int timeout)
    {
    int rtnCode = 0;
    char myTransName[24];
    char spacelessText[24];
    char * spacePointer;

    memset ( spacelessText, ‘\0’, sizeof(spacelessText));

    {
    * spacePointer = ‘_’;
    }

    sprintf (myTransName, Read Entire Entry

  • VuGen: Using Undocumented Functions

    Posted on March 31, 2009 by Admin

    From James Pulley:
    ———————-

    I have never really cared for the use of the lr_user_data_point() and
    having to pull up the user defined graphs for analysis. Instead I take
    advantage of some undocumented functions

    lr_set_transaction()
    lr_get_transaction_duration()

    I use these functions in tandem to determine if I need to create a custom tracking transaction where a transaction has run too long and is out of spec.

    I can then compare raw numbers at the end of the test, a ratio of <transaction name>_out_of_spe Read Entire Entry

  • Web Click and Script actually does work

    Posted on March 27, 2009 by Admin

    On my latest engagement, I needed a web script to go with all of the Citrix scripts I am creating. The web script was giving me some issues with correlation and NT authentication, so I decided to give Web Click and Script a try. I didn’t have much expectation since neither I nor my colleagues have been able to get it to work in the past, but I thought that it would be worth a try in 9.5. Imagine my surprise when it actually worked! This could partly be because the javascript is minimal. That seems to be where C&S hangs.

    There i Read Entire Entry