<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>LoadRunner TnT &#187; Vugen</title>
	<atom:link href="http://www.loadrunnertnt.com/tag/vugen/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.loadrunnertnt.com</link>
	<description>Performance Testing, LoadRunner Tips &#38; Tricks</description>
	<lastBuildDate>Mon, 08 Mar 2010 07:57:02 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Resolving Vugen/Controller crash or abnormal behaviors</title>
		<link>http://www.loadrunnertnt.com/how-tos/resolving-vugencontroller-crash-or-abnormal-behaviors/</link>
		<comments>http://www.loadrunnertnt.com/how-tos/resolving-vugencontroller-crash-or-abnormal-behaviors/#comments</comments>
		<pubDate>Wed, 21 May 2008 13:25:14 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[How-Tos]]></category>
		<category><![CDATA[Controller]]></category>
		<category><![CDATA[Crash]]></category>
		<category><![CDATA[Error]]></category>
		<category><![CDATA[Vugen]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=112</guid>
		<description><![CDATA[In the event that Vugen/Controller crashes or behaves abnormally, the official vendor has provided two documents to assist the user in troubleshooting the problem for each component separately. The documents are rather out-dated but well, better than nothing, is still relevant in some sense. Below are the links to the resources:

Document ID 31731: Troubleshooting guide [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft" title="HP" src="http://loadrunnertnt.com/images/company_hp_logo.gif" alt="" width="64" height="55" />In the event that Vugen/Controller crashes or behaves abnormally, the official vendor has provided two documents to assist the user in troubleshooting the problem for each component separately. The documents are rather out-dated but well, better than nothing, is still relevant in some sense. Below are the links to the resources:<span id="more-112"></span></p>
<ul>
<li><a href="http://support.openview.hp.com/selfsolve/document/KM185544" target="_blank">Document ID 31731: Troubleshooting guide for VuGen (not stable/crashes/freezes/GPF)</a></li>
<li><a href="http://support.openview.hp.com/selfsolve/document/KM170566" target="_blank">Document ID 12532: Troubleshooting guide for Controller ( not stable/crashes/freezes/GPF )</a></li>
</ul>
<p>There are a couple of solutions in both documents, but we would recommend trying out the following that usually resolves the problem.</p>
<ul>
<li>Login as administrator and perform the work with that account.</li>
<li>Run the batch file.</li>
<li>Reinitializing the .ini file or the document term it as &#8220;recreate the initialization file&#8221;.</li>
</ul>
<p>Take note on the terminology of the administrator here, it is the default administrator account on the Windows operating system without any changes to it&#8217;s roles or privileges. If the environment you worked in have default images, or amended administrator account, you may need to use a machine that is &#8220;clean&#8221; to test out and run Vugen or Controller. On top of the given list from the official vendor, we&#8217;ve experiences that certain situations may cause the Vugen and Controller to behave abnormally as well.</p>
<p><strong>Do you have another Mercury/HP product running on the same machine such as QTP or WinRunner?</strong> They may conflict with Vugen and Controller when placed together on the same machine. As such, it is advisable to install only LoadRunner components on the machine while other products are to be installed separately.</p>
<p><img class="alignleft" title="Sysinternals" src="http://loadrunnertnt.com/images/bb545021.hero_windows_sysinternals(en-us,MSDN.10).jpg" alt="" width="265" height="42" />In addition, you can use Process Explorer (as recommended by the document) to find out if there are conflict with the processes. The link is broken in the document as <a href="http://technet.microsoft.com/en-us/sysinternals/default.aspx" target="_blank">Sysinternals</a> have been acquired by Microsoft in July 2006.  Click <a href="http://technet.microsoft.com/en-us/sysinternals/bb896653.aspx" target="_blank">Process Explorer</a> to be directed to the actual website.</p>
<p><strong>Do you have DEP enabled in your machine?</strong> DEP (Data Execution Prevention) is part of the Windows XP SP2 feature and extends to Windows 2003 and the Vista versions. For more information of DEP, refer to the following resources:</p>
<ul>
<li><a href="http://support.microsoft.com/kb/875352" target="_blank">A detailed description of the Data Execution Prevention (DEP) feature in Windows XP Service Pack 2, Windows XP Tablet PC Edition 2005, and Windows Server 2003</a></li>
<li><a href="http://en.wikipedia.org/wiki/Data_Execution_Prevention" target="_blank">Data Execution Prevention by Wikipedia</a></li>
<li><a href="http://www.updatexp.com/data-execution-prevention.html" target="_blank">Data Execution Prevention by Marc Liron</a></li>
</ul>
<p>To resolve this problem, you have to disable DEP. <a href="http://support.openview.hp.com/selfsolve/document/KM194248" target="_blank">This is as described in Document ID 41489: No events recorded in VuGen when trying to record an application on Windows 2003 SP1 or Windows XP SP2</a>.</p>
<p><strong>What are the technology/protocol used by the application? </strong> Specified to Vugen recording, the third possibility that causes the problem is the type of application that you are working with. Example, if the application runs on RCP (Rich Client Platform) or applets but communicates in HTTP. For this, you&#8217;ve to identify the actual protocol being transmitted and find workarounds to it. In the example of HTTP, you can refer to a previous article, <a href="http://www.loadrunnertnt.com/?p=104" target="_blank">&#8220;Quick-and-Dirty Recording Techniques for Web (HTTP/HTML)&#8221;</a> for more information.</p>
<p>If all else fails, the best suggestion is to get a “clean” machine, login with the default local administrator and perform a re-installation of LoadRunner. Remember, the definition of “clean” means that the machine operating system is not based on a clone image. Well, we&#8217;ve to say that this is not the entire list that the community is experiencing and therefore, if you have a problem relating to the crashing or abnormal behavior, please share with us and we will append to this list accordingly.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/how-tos/resolving-vugencontroller-crash-or-abnormal-behaviors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Are client activities recorded by Vugen?</title>
		<link>http://www.loadrunnertnt.com/concepts/are-client-activities-recorded-by-vugen/</link>
		<comments>http://www.loadrunnertnt.com/concepts/are-client-activities-recorded-by-vugen/#comments</comments>
		<pubDate>Tue, 22 Apr 2008 05:54:05 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[Concepts]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Vugen]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=307</guid>
		<description><![CDATA[Vugen is NOT designed to record client-side activities. The main functionality of LoadRunner is to load test a server, a SUT (System Under Test), through emulating network traffic to load against the SUT. The network traffic is as mentioned previously in earlier posts, captured (sniffed) and replayed during the script creation. Client activity exist only [...]]]></description>
			<content:encoded><![CDATA[<p>Vugen is NOT designed to record client-side activities. The main functionality of <span style="font-weight: bold;">LoadRunner</span> is to load test a server, a <span style="font-weight: bold;">SUT (System Under Test)</span>, through emulating network traffic to load against the SUT. The network traffic is as mentioned previously in earlier posts, captured (sniffed) and replayed during the script creation. Client activity exist only on the client machine and does not contributes to the network traffic loading on the SUT. With no traffic being generated, Vugen will not be able to record anything and of course not replayed as no traffic is generated.</p>
<p><a href="http://support.openview.hp.com/" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;"><span id="more-307"></span>Mercury/HP Support</span></span></a> have provided some information on this particular topic in <a href="http://support.openview.hp.com/selfsolve/document/KM190712" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">Document ID 3803 &#8211; Nothing gets recorded while performing some client side activity</span></span></a> and <a href="http://support.openview.hp.com/selfsolve/document/KM195129" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">Document ID 42319 &#8211; VuGen is not replaying the rendering of an Excel file in the browser’s MS Excel plug-in</span></span></a>. In both articles, it just merely describes what is client side activity and it cannot be recorded. (Take note that you required a valid login to the support website to access the article.)</p>
<p>At the release of <span style="font-weight: bold;">LR 8.1 FP3</span>, a new protocol called <span style="font-weight: bold;">Web (Click &amp; Script)</span> was introduced. <a href="http://support.openview.hp.com/selfsolve/document/KM201537" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">Document ID 48261 &#8211; New Features/Enhancements for the Web Click and Script protocol in LoadRunner 8.1 Feature Pack 4</span></span></a> provides more details in it as an enhanced released of<span style="font-weight: bold;"> FP4</span>. This protocol “promises” that the scripting will be make easy and it will resolve some of the client-side activities such as <span style="font-weight: bold;">Javascripts</span>. However, to my experience, I wasn’t successful in using it (or maybe I missed out some steps concerning this new protocol)… anyway… you can give it a try in recording those web applications with Javascripts/<span style="font-weight: bold;">AJAX</span> or similar components embedded into the web application (if you have intentions in recording the client-side activities). I would be more concerned with actual load been generated to the SUT and will use the conventional <span style="font-weight: bold;">Web (HTTP/HTML</span>). Similarly, there is an AJAX protocol that was introduced in <span style="font-weight: bold;">LR 9</span> to record <strong>AJAX</strong> applications.</p>
<p>Having the concept in mind, I would like to go a little further with the following example.</p>
<p style="float: right; margin-right: 8px;">
<p>For activities such as, opening of file, editing in <span style="font-weight: bold;">Excel sheet</span>, or <span style="font-weight: bold;">bat</span> files performing copying operations are considered to be <span style="font-weight: bold;">client-side</span> activities. Think about it, do they generate any network traffic (unless you the activities really have a network call to a remote server)?</p>
<p>Another example is that if a web application allows opening of files such as documents over the browser (e.g.<span style="font-weight: bold;"> Sharepoint</span>). The underlying mechanism for the file opening operation still requires a client installation of the program (e.g. <span style="font-weight: bold;">MS Word</span>), and subsequent activities are done locally on the client machine even though it exist in a browser. This of course is also considered as a <span style="font-weight: bold;">client-side</span> activity.</p>
<p>So, before recording the application, please ensure that you know the functionality of the Business Process that you are recording and determine if it is a client or server activity. This will greatly reduce the unneccessary effort in scripting and later realizing that it is client activity. If it is a client activity, a no-go, wrong tool for the job! It served no purpose of the tool to conduct non-performance tests. Consider other tools such as <span style="font-weight: bold;">Quick Test Professional </span>or <span style="font-weight: bold;">Silk Test</span> for functional testing client-activities.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/concepts/are-client-activities-recorded-by-vugen/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Why are my scripts/vusers failing?</title>
		<link>http://www.loadrunnertnt.com/errors/why-are-my-scriptsvusers-failing/</link>
		<comments>http://www.loadrunnertnt.com/errors/why-are-my-scriptsvusers-failing/#comments</comments>
		<pubDate>Tue, 22 Apr 2008 04:40:51 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[Errors]]></category>
		<category><![CDATA[Controller]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Vugen]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=147</guid>
		<description><![CDATA[Let’s answer the question systematically. This is sort of a troubleshooting guide for you when your script fails. It covers an overview which will be useful when the event happens. The script can fail in two areas in LoadRunner, in during replay in Vugen and during scenario execution in Controller.
What are the possibilities in Vugen?
1. [...]]]></description>
			<content:encoded><![CDATA[<p>Let’s answer the question systematically. This is sort of a troubleshooting guide for you when your script fails. It covers an overview which will be useful when the event happens. The script can fail in two areas in LoadRunner, in during replay in Vugen and during scenario execution in Controller.</p>
<p>What are the possibilities in Vugen?<span id="more-147"></span></p>
<p><strong><span style="text-decoration: underline;">1. The application that you are replaying against is not running.</span></strong></p>
<p>Simple? But it does happen, as such, when it fails on <span style="font-weight: bold;">replay</span>, take some time and try logging into the application manually and perform the <span style="font-weight: bold;">business processes</span>.</p>
<p style="text-decoration: underline;"><strong>2. There were changes to the application </strong></p>
<p>There were changes to the application in aspect that had affected the script. For a <span style="font-weight: bold;">3-tier architecture</span>, anything could have changed such as the following:</p>
<ul>a. <strong>Presentation layer</strong>: where links or button are removed,<br />
b. <strong>Application layer</strong>: where methods are changed or removed,<br />
c. <strong>Database layer</strong>: where calls or tables are changed or removed.<br />
d. <strong>Architecture level</strong>: where proxies or load balancers are changed or<br />
removed.</ul>
<p>As such, verify with the application and infrastructure team if there were any changes made. You may have to re-script or amend the script accordingly to the changes.</p>
<p style="text-decoration: underline;"><strong>3. There are dynamic values that needs to be correlated. </strong></p>
<p>This is common in applications. They are usually in the form of <strong>Session IDs</strong> or returned values based on <strong>parameterization</strong>. You have two options here:</p>
<ul>
<li>Use the <strong>auto-correlation</strong> feature to detect any dynamic values (which I don’t usually use) or,</li>
<li>Perform <strong>manual correlation</strong> by recording two scripts of the same business process. From the two scripts, compare the <strong>recording logs</strong> and the APIs that had been generated for the differences. If you are new to manual correlation, I would recommend you to go through <a href="http://support.openview.hp.com/selfsolve/document/KM170043" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">Document ID 11806 &#8211; What is correlation and how is it done</span></span></a> from the support website to get a better understanding.</li>
</ul>
<p style="text-decoration: underline;"><strong>4. The parameterization may be causing the problem </strong></p>
<p>The parameterization may be causing the problem in the following manner:</p>
<ul>
<li><strong>Insufficient records</strong>: ensure that you have sufficient records for the replay, especially in iterations.</li>
<li><strong>Incorrect records</strong>: verify with the application or database team that you are holding on the valid values to be passed in as parameters. Parameterization may also result in different set of data being returned by the server as mentioned previously in (3). If that happens, correlate the value accordingly.</li>
</ul>
<p>For (1) to (4), it’s recommended to turn on <strong>Full Extended Log (all options enabled: Advanced Trace, Parameter Subsitution, Data Returned From Server)</strong> in the <strong>Runtime Settings</strong> (Vugen) to verify the data that is been transmitted between the server and the client (script). Through this, you can find out what and where that could have gone wrong in the replay.</p>
<p>What are the possibilities in Controller?</p>
<p style="text-decoration: underline;"><strong>5. Does it happen at the start of the scenario execution? </strong></p>
<p>We are focusing on the script only and leaving out the load testing setups. If the script/vuser fail at the start of the execution, verify the script again in <strong>Vugen</strong>, and if it still fails; it’s a script problem where you have to re-work from the previous point (1) to (4).</p>
<p style="text-decoration: underline;"><strong>6. Does it fail on a particular Load Generator (LG)?</strong></p>
<p>This maybe caused by inconsistent LG across the load testing environment. As such, ensure the following in order for the script to run properly (but not limited to the list):</p>
<ul>
<li><strong>Folder directories</strong> that the script may be accessing to (particularly for file upload and download business processes).</li>
<li><strong>Java</strong> settings like <strong>JVM</strong> and <strong>CLASSPATHs</strong> that can affect Java LoadRunner scripts.</li>
<li>All LGs have the same version as the <strong>Controller</strong> (e.g. <strong>LR9.0</strong> across all LGs in the load testing environment).</li>
</ul>
<p style="text-decoration: underline;"><strong>7. Does it happen at the middle of the scenario execution? </strong></p>
<p>If it is the case, it maybe caused by anything but unlikely script problems (since the script/vuser have already started running successfully at the start of the run in (5). When this happens, the <span style="font-weight: bold;">Application Under Test (AUT)</span> maybe under load and unable to process all requests from the scripts/vusers and therefore returning errors to them. You can verify this with the following.</p>
<ul>
<li>Manually log into your <strong>AUT</strong> again and verify if it is still running or experiencing any lags.</li>
<li>Reduce the amount of <strong>vusers</strong> being generated in the scenario and re-run the test. If a reduced amount results in a error-free or non-script related errors, you are sure that the AUT is under load.</li>
</ul>
<p>The above should be sufficient for you to troubleshoot script/vuser problems in <strong>Vugen</strong> and <strong>Controller</strong>. However, take note that it may not be limited to those and it will be advisable to carefully work the problem step-by-step to eliminate and possibilities.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/errors/why-are-my-scriptsvusers-failing/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>How-to configure vuser behavior in Vugen that affects time</title>
		<link>http://www.loadrunnertnt.com/concepts/how-to-configure-vuser-behavior-in-vugen-that-affects-time/</link>
		<comments>http://www.loadrunnertnt.com/concepts/how-to-configure-vuser-behavior-in-vugen-that-affects-time/#comments</comments>
		<pubDate>Tue, 22 Apr 2008 03:24:16 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[Concepts]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[Vugen]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=253</guid>
		<description><![CDATA[In this article, we will walkthrough the settings that will enable your vuser (script) to perform in a certain behavior. We will start off with the configurations that affects time and the subsequent article in Vugen, we will be also touching on the configuration for time in Controller and settings that affects locality.
[1] Think Time
Think [...]]]></description>
			<content:encoded><![CDATA[<p>In this article, we will walkthrough the settings that will enable your vuser (script) to perform in a certain <strong>behavior</strong>. We will start off with the <strong>configurations</strong> that affects time and the subsequent article in <strong>Vugen</strong>, we will be also touching on the configuration for time in <strong>Controller</strong> and settings that affects locality.<span id="more-253"></span></p>
<p><span style="text-decoration: underline;">[1] Think Time</span></p>
<p><strong>Think time</strong> is as recorded during the recording of the application. During the recording, you maybe entering values into the text fields, or browsing through your data sheet or maybe thinking of something (whatever…), all these will be recorded and generate as a <strong>LoadRunner</strong> API, <strong>lr_think_time</strong>.</p>
<p>In your<strong> Script-view</strong>, for example you should see it as <strong>lr_think_time(90)</strong> if you had used 90secs to perform a task such as entering values into an online form. To change the value, simply change the value in lr_think_time(90) to lr_think_time(60) which means you are changing the value frm 90secs to 60secs. This is the same in the Tree-view. That is to change the value for <strong>Think Time</strong>.</p>
<p>You can further manipulate how the Think Time will be replayed in the <strong>Run-Time Settings</strong>.</p>
<p style="text-align: center;"><img class="aligncenter" title="Runtime Settings Think Time" src="http://loadrunnertnt.com/images/runtime_settings_think_time.jpg" alt="" width="544" height="335" /></p>
<p>You can choose the following options to suit your needs.</p>
<ul>1. Ignore think time<br />
2. Replay think time as recorded<br />
3. Multiply recorded think time by<br />
4. Use random percentage of recorded think time</ul>
<p><strong>Ignore think time</strong></p>
<p>Your script is going to run like a robot where there is no delay between each form submission. Not possible for a real human to do that which makes the load test unreal.</p>
<p><strong>Replay think time as recorded</strong></p>
<p>This setting will cause the script to replay as it is. It looks all good in Vugen at first but when you are in the Controller, it looks weird as all vusers will be replaying at the same amount of think time, which again, looked like cloned robots. If you have transactions created for the script, in the <strong>Controller</strong> graphs, all transactions will perform at the same speed.</p>
<p><strong>Multiply recorded think time by</strong></p>
<p>Straight-foward description; this setting multiplies the recorded value with the numeral provided, extending the time delay in the script.</p>
<p><strong>Use random percentage of recorded think time</strong></p>
<p>Personally, I like to use this option where the <strong>script</strong> will replay the percentage range of the recorded think time. With the recorded think time, I allow <strong>50% &#8211; 150% deviation</strong> emulating the expert users (lower range:50%) and novice users (upper range:150%). I presumed the speed I’m working (recording) with the <strong>application</strong> is at an average user speed.</p>
<p><strong>Limit think time to</strong></p>
<p>This last option allows the script to replay the think time at a defined minimal limit.</p>
<p><span style="text-decoration: underline;">[2] Pacing </span></p>
<p><strong>Pacing</strong> is the interval between each <strong>iteration</strong>s which defines the time the script waits between iterations of actions. Below is the screenshot of the Pacing options in the <strong>Runtime Settings</strong> launched from <strong>Vugen</strong>.(click on image to enlarge)</p>
<p><img class="aligncenter" title="Runtime Settings Pacing" src="http://loadrunnertnt.com/images/runtime_settings_pacing.jpg" alt="" width="483" height="309" /></p>
<p>You can choose the following options to suit your needs.</p>
<ul>1. As soon as the previous iteration ends<br />
2. After the previous iteration ends with a fixed or random delay of ..<br />
3. At fixed/random intervals, every …</ul>
<p><strong>As soon as the previous iteration ends</strong></p>
<p>The default setting in <strong>Vugen</strong>. The next iteration will start without any delay after the current iteration ends. The following illustrates the setting better.(click on image to enlarge)</p>
<p style="text-align: center;"><a href="images/runtime_settings_pacing_1.jpg"><span style="text-decoration: underline;"><span style="color: #0066cc;"> </span></span></a><img class="aligncenter" title="Runtime Settings Pacing" src="http://loadrunnertnt.com/images/runtime_settings_pacing_1.jpg" alt="" width="385" height="183" /></p>
<p><strong>After the previous iteration ends with a fixed or random delay of ..</strong>.</p>
<p>This setting will start the next iteration after the current iteration ends and with the defined delay (setting) achieved. This interval can be either fixed or random and applies for all iterations. The following illustrates the setting better. (click on image to enlarge)</p>
<p style="text-align: center;"><a href="images/runtime_settings_pacing_2.jpg"><span style="text-decoration: underline;"><span style="color: #0066cc;"> </span></span></a><img class="aligncenter" title="Runtime Settings Pacing" src="http://loadrunnertnt.com/images/runtime_settings_pacing_2.jpg" alt="" width="531" height="244" /></p>
<p><strong>At fixed/random intervals, every …</strong></p>
<p>This setting will start the next <strong>iteration</strong> based on the start of the previous iterations. For example you defined 30secs as the interval, the <strong>iteration</strong> completes in 12secs in the 30secs timeframe, then the next iteration will start after 18secs. Note, the scheduled iterations will only begin when the previous iteration is complete. The following illustrates the setting better.(click on image to enlarge)</p>
<p style="text-align: center;"><img class="aligncenter" title="Runtime Settings Pacing" src="http://loadrunnertnt.com/images/runtime_settings_pacing_3.jpg" alt="" width="551" height="290" /></p>
<p><span style="text-decoration: underline;">[3] Action blocks</span></p>
<p><strong>Action blocks</strong> are groups of actions within the <strong>vuser script</strong>. Actually you can think of it as two components. One, is the action which is defined in the script and two, the block that holds the actions. As mentioned earlier in previous article, <a href="/?p=109" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">Configuring Real User Behavior in LoadRunner &#8211; Time</span></span></a>, the purpose of <strong>action blocks</strong> allowed the tester to define a modular action of the real user.</p>
<p>What can you do with the action blocks:</p>
<ul>1. The actions to be included in a block<br />
2. The sequence of the actions in a block<br />
3. The number of iterations that the block will run</ul>
<p>Below illustrates the <strong>Run-time Settings</strong> for the <strong>Run Logic</strong>. (Click on the image to enlarge it).</p>
<p><a href="images/runtime_settings_run_logic.jpg"><span style="text-decoration: underline;"><span style="color: #0066cc;"> <img class="aligncenter" title="Runtime Settings Run Logic" src="http://loadrunnertnt.com/images/runtime_settings_run_logic.jpg" alt="" width="582" height="371" /><br />
</span></span></a></p>
<p>Let’s discuss a little more on this <strong>action blocks</strong>. For the actions, actually you can’t do much with it except to choose it from the list of actions available in the <strong>script</strong> and then place it in your desired block. Most of the settings are on the block itself.</p>
<blockquote><p>Note:<br />
The <strong>“Run”</strong> is also consider a block with iterations of its own.</p></blockquote>
<p>For the block, after you inserted one, you can provide the number of <strong>iterations</strong> for the <strong>block</strong> and include the <strong>actions</strong> that will be part of the block. Furthermore, you can define the block to perform either <strong>sequentially</strong> or <strong>randomly</strong> (via <strong>percentage parameter</strong>). This is all configurable at the block level, that’s to say, for each block, you can configure iterations, type of actions and sequence. Below illustrates the settings (click on the image to enlarge it).</p>
<p><img class="aligncenter" title="Runtime Settings Run Logic Random" src="http://loadrunnertnt.com/images/runtime_settings_run_logic_random.jpg" alt="" width="253" height="162" /></p>
<blockquote><p>Note:<br />
Be careful when you delete a block, the actions in the block will also be removed!</p></blockquote>
<p><span><span style="text-decoration: underline;">[4] Iteration</span></span></p>
<p>What <strong>iteration</strong> does is to define the <strong>vusers</strong> to repeat a set of <strong>actions</strong> a specified number of times.</p>
<p>Previously mentioned in this article, <strong>iteration</strong> is configured on the block level. Take note that iteration is applicable to <strong>“Run”</strong> block (which is also applicable to blocks that are within the “Run” block). It is not applicable to <strong>“Init”</strong> and <strong>“End”</strong> block which is unlike insertion of actions in “Init” and “End” block that is applicable.</p>
<blockquote><p>Note:<br />
When the script is ported into <strong>Controller</strong> for <strong>load testing</strong>, the <strong>scenario</strong> scheduling settings will override the vuser iteration settings. This means that if the duration is set to the five minutes (default), the vusers will continue to run as many iterations as required until the five minute completes, even if the run-time settings in Vugen specifies one iteration only.</p>
<p>(Source: Vugen User Guide, Chapter 12, Configuring Run-Time Settings)</p></blockquote>
<p>A good recommendation of using iteration other than for simulating an action performed multiple times is to ensure the <strong>parameter</strong> settings are working fine before proceeding with the <strong>scenario</strong> setup in the Controller.</p>
<p><!-- Additional Items for the post:Start --><!-- Additional Items for the post:End --><!-- Social Networks --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/concepts/how-to-configure-vuser-behavior-in-vugen-that-affects-time/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>How-to retrieve parameter data from MySQL database</title>
		<link>http://www.loadrunnertnt.com/how-tos/how-to-retrieve-parameter-data-from-mysql-database/</link>
		<comments>http://www.loadrunnertnt.com/how-tos/how-to-retrieve-parameter-data-from-mysql-database/#comments</comments>
		<pubDate>Tue, 22 Apr 2008 01:02:00 +0000</pubDate>
		<dc:creator>TnT Admin</dc:creator>
				<category><![CDATA[How-Tos]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Vugen]]></category>

		<guid isPermaLink="false">http://www.loadrunnertnt.com/?p=79</guid>
		<description><![CDATA[As you’ve know, LoadRunner offers the feature of retrieving parameter data from database with the Database Query Wizard in Vugen. This allows ease and alternative preparation of your parameter data for load test. By putting a little creativity on this feature, we need not limit ourselves to the example of Microsoft Access database as mentioned [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft" title="MySQL" src="http://loadrunnertnt.com/images/mysql_logo.jpg" alt="" width="180" height="104" />As you’ve know, <strong>LoadRunner</strong> offers the feature of retrieving parameter data from database with the <strong>Database Query Wizard</strong> in Vugen. This allows ease and alternative preparation of your parameter data for load test. By putting a little creativity on this feature, we need not limit ourselves to the example of <strong>Microsoft Access</strong> database as mentioned in it’s <strong>Vugen User Guide</strong>, we can extend this feature to other types of database, say, <strong>MySQL database</strong>!</p>
<p>Let’s go through a technical overview of what you need to do for it to work!</p>
<ol>
<li> Get and install the database driver to connect to the database</li>
<li>Get the database connection string</li>
<li>Get the SQL statement for query</li>
<li>Create a new parameter using Database Query Wizard</li>
<li>Enter the connection string and the SQL statement</li>
</ol>
<p>Now, let’s go through the details here with some screenshots to make it easier to understand.<span id="more-79"></span></p>
<p><span style="text-decoration: underline;">[1] Download driver</span></p>
<p>I’ve obtained my MySQL-ODBC driver from <a href="http://dev.mysql.com/downloads/connector/odbc/3.51.html" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">MySQL website</span></span></a>. You will need to find out what is the driver required to connect your database accordingly.</p>
<p><span style="text-decoration: underline;">[2] Get the database connection string</span></p>
<p>In the context of MySQL database, I referred to <a href="http://www.connectionstrings.com/?carrier=mysql" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">ConnectionStrings</span></span></a>. The string that I used was for <strong>3.51 driver</strong> and I was trying out on a localhost MySQL which will looked like the below</p>
<p><em>Driver={MySQL ODBC 3.51 Driver};Server=localhost;Database=myDatabase; User=root;Password=rootpassword;Option=3;</em></p>
<p>Of course, you can refer to other type of connection string in <a href="http://www.connectionstrings.com/" target="_blank"><span style="text-decoration: underline;"><span style="color: #0066cc;">ConnectionStrings.com</span></span></a> as well! If you have tried out with other database, please let us know and we can compile them into a single source of reference point!</p>
<p><span style="text-decoration: underline;">[3] Get the SQL statement</span></p>
<p>The <strong>SQL statement</strong> that I used was show status, which actually queries the status of MySQL database. Take note, I’m just using it for example purposes, you can use conventional statements like <em>SELECT field FROM table</em>.</p>
<p><span style="text-decoration: underline;">[4] Create a new parameter using Database Query Wizard</span></p>
<p>In the script and create a new parameter using Database Query Wizard (Open Parameter list &gt; New &gt; Data Wizard &gt; Select “Specify SQL statement manually” &gt; click “Next”)</p>
<p><strong>Database Query Wizard</strong></p>
<p><img class="aligncenter" title="Parameter List Database Query" src="http://loadrunnertnt.com/images/parameter_list_database_query_wizard.PNG" alt="" width="452" height="353" /></p>
<p><span style="text-decoration: underline;">[5] Enter the Connection String and SQL statement</span></p>
<p>Enter the <strong>Connection String</strong> and <strong>SQL statement</strong>, and click <em>“Finish”</em>. If the connection string and SQL statement are valid, after you clicked <em>“Finish”</em> the parameter should be populated accordingly.</p>
<p><strong>Enter Connection String and SQL statement</strong></p>
<p><img class="aligncenter" title="Specify SQL Statement" src="http://loadrunnertnt.com/images/parameter_list_specify_SQL_statement.PNG" alt="" width="452" height="353" /><strong></strong></p>
<p><strong>Connection and query successful!</strong></p>
<p><img class="aligncenter" title="Select data from MySQL" src="http://loadrunnertnt.com/images/parameter_list_select_data_from_mySQL_completed.PNG" alt="" width="618" height="558" /></p>
<p>That’s it and done! Hope it helps you when you are using the Database Query Wizard! Do share with us if you have tried other databases with the <strong>Database Query Wizard</strong>!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.loadrunnertnt.com/how-tos/how-to-retrieve-parameter-data-from-mysql-database/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>

