QAInsight.net, QABlog.com, QABlog.net
Brent Strange's thoughts on Software Quality Assurance and technology

 
Saturday, February 11, 2006
 
 

Confusion between Timer vs. Transaction counts with SilkPerformer

 
 

Recently I've been confused at why my Timer count differed from my Transaction count in recent SilkPerformer test results. Having a second reference to compare SilkPerformer numbers against I had settled on the Timer count being the correct number to report as results but I still felt uneasy because I didn't know why this was occurring. I finally sat down today and figured out why the numbers differed. Take a look at the following table of Transaction counts and Timer counts:

Notice that the tables are nearly identical but the transaction AnswerChallenge is significantly higher in the Transaction count table making the overall number higher/different (759476 vs. 258285 ). Seems odd, but after thinking through my script and transaction flow I finally figured out why AnswerChallenge varies between counters. Before I explain look at my actual user transactions declaration (user flow):

transactions
InitTestCase : begin;
InitUserAndIP : 1;
AuthenticateUser: 1;
ThinkTimeTrxn : 1;
AnswerChallenge: 1; //only runs if Challenge is issued

and then my the code for my AnswerChallenge transaction:

transaction AnswerChallenge
begin
if (isChallenged = "Challenge") OR (isForceChallenge="ForceChallengeResponse") then 
   WebHeaderAdd("SOAPAction", " http://www.blah");
   MeasureStart("AnswerChallenge");
   WebPagePost(sPage,
   "<?xml version=\"1.0\" encoding=\"utf-8\"?>"
   "<soap:Envelope xmlns:soap=\"http://blah">"
   "<soap:Body>"
   "</soap:Body>"
   "</soap:Envelope>", 0, "text/xml; charset=utf-8);
   MeasureStop("AnswerChallenge");
end;
end AnswerChallenge;

Notice that after the begin statement I check for the presence of two flags:

if (isChallenged = "Challenge") OR (isForceChallenge = "ForceChallengeResponse")

If the strings match the variable then the transaction CONTENTS will run, if they don't the CONTENTS won't run. Notice that inside of the if statement I have my timer (MeasureStart("AnswerChallenge");). AHH! Bingo... Do you see it? The transaction: AnswerChallenge is ALWAYS called due to the user transactions definition, but the CONTENTS of the transaction won't be executed if the if statement is false. Thus, the transaction count ALWAYS grows regardless of the If statement results. If the if statement ends up being TRUE then the Timer count will go up (and this is the counter I care about).

See the visual difference with a TryScript:

From a programming point of view the behavior is obvious (with hind-sight). When perusing SilkPerformer reports.. not so obvious. Moral of the story: If you care about the count of transactions actually being sent over the wire, and you decide to run a transaction based on the result of another transaction, make sure to look at your Timer counts not your Transaction counts.

 
   
   
   
Tuesday, March 13, 2007 6:01:16 AM (US Mountain Standard Time, UTC-07:00)
TODAY I LOOK A GOOD ARCHIVES!!

Tuesday, March 13, 2007 6:01:42 AM (US Mountain Standard Time, UTC-07:00)
Hello I like your page is interesting...
10/325 - Vicoprofen - Lortab- Tylenol #3- - Ativan
All Major Medications are available right here at:
Tuesday, March 13, 2007 6:02:11 AM (US Mountain Standard Time, UTC-07:00)
In the same calification we can find drugs like!

Tuesday, March 13, 2007 6:02:36 AM (US Mountain Standard Time, UTC-07:00)
Have a great day!
Sunday, April 22, 2007 10:31:00 PM (US Mountain Standard Time, UTC-07:00)
In the same calification we can find drugs like!


Thursday, June 07, 2007 2:25:23 AM (US Mountain Standard Time, UTC-07:00)
Sehr gut gemachter Internetauftritt - gef?llt uns ausgezeichnet. Bei uns finden Sie WOW Gold unter
Beste Grü?e,
Comments are closed.