How to Apply a Threshold rule on a specific page

Hello there,

I created a load test for a web application and I am trying to apply threshold rules but on specific pages. All I was able to do is to create a treshold rule on the LoadTest : Page : Avg.PageTime counter.

Another thing, I can't visualize the avg.pagetime of a specific time in the loadtest graph.To visualize it, The threshold applied above must bust, and only then we can see the avg page Time of every Page that the test has visited...

How can we visualize the Avg.PageTime counters for every page in the web test and how do we apply treshold rules to specific pages.

Erik



Answer this question

How to Apply a Threshold rule on a specific page

  • Naynesh Shah

    To view a page insatnce performance counter...
    There are specific performance counters for each page. The category is "LoadTest:page", counter name is "Avg. Page Time", and the instance name is the URL for the page. You can add individual performance counters a to graph by locating the counter in the counter panel (top left panel of the Load Test Analyzer), locate the performance counter and add it to the graph (drag/drop, double click, or choose "Add to graph" from the context menu).

    A page instance counter should be found by expanding the Scenario node in the tree to expose the tests. Then expand the test node to expose the pages. Choose the page instance you're interested in and expand that node. This will expose all the performance counters for that page, which includes the Avg. Page time.

    To add a threshold rule...
    In the load test editor, navigate to the Avg. Page Time counter under the the LoadTest counter set. You will have to add an instance names for the pages you wish to attach a threshold rule to. Then from the instance node, choose "Add Threshold Rule".

    Does this help
    Thanks,
    Rick


  • Markus H

    I sorry, I was mistaken in my previous post about being able to add a threshold rule to a specific instance of a performance counter. The problem is that if you attach a threshold rule to a counter, then it will be executed for every instance of that counter. If you attach the threshold rule to an instance, the threshold rule will be executed for each counter that has that instance (total pages, avg. page time, page response time goal, %page meeting goal in the case of a page instance).

    You can set a page goal time for individual requests in the web test editor. Is this what you're trying to accomplish Select a request in the web test editor and look to the property grid. There is a property called "Response Time Goal" that allows you to enter the number of seconds you exepct the page to complete by. If the actual response time exceeds the goal. The performance counter "% Meeting Goal" will report the percentage of page requests that met the goal. For example, you can set a goal on "page1.aspx" for 3 seconds and then track the "% Meeting Goal" for that page.

    Does this help
    Thanks,
    Rick


  • Prasad Honrao

    Well i didn't know we could set a goal time for individual request in the web test editor, thanks!

    But my question is: How do we add an instance to a counter WHat I'm trying to do is to set a threshold rule to an instance, the instance would be a specific page called in the Web Test.

    Erik


  • VBFan

    I'll correct my previous message! :)

    How do we add an instance to a counter


  • Timothy P

    By the way, how do we have an instance name of a counter

    Erik


  • NSK

    That helps a lot!!

    Thanks Rick

    Erik


  • Suresh

    There is no way to add a single instance to a single counter. A set of counters exist for a performanc counter category and a set of instances exist for the counter category. Thus, if you add a new counter to a category you will recieve that performance counter for all instances defined for that category. Likewise, if you add an instance to a category, you receive all counters in the category for that instance.

    For a system performance counter you pick the set of counters and the set of instances from the "Add Counters..." dialog. However, for load test counters (or system performance counters that don't have existing instances at design time), you must add instances explicitly in the load test editor.

    Unfortunately, there is not a specific command to add a performance counter instance. Here's what you can do.

    1) find an instance definition in another counter set (Controller: Processor: _Total, for example).
    2) select that instance node in the editor and copy it to the clipboard (control-c or "Copy" from the context menu)
    3) Select the counter category you want to add an instance to (LoadTest:Page in this case)
    4) Paste from the clipboard.
    5) Change the instance name in the property grid.

    And like I said, I was mistaken before. You cannot add a threshold rule to a performance counter instance, only a performance counter.

    Thanks,
    Rick


  • How to Apply a Threshold rule on a specific page