On 20/09/2007, Nikolaos Giannopoulos <[EMAIL PROTECTED]> wrote: > Hi, > > We have a JMeter plan that hits a JSP on site that has 9 web instances > behind a load balancer. The JSP presents information on the instance > hit e.g. "Server 3 instance 2" as well as other diagnostic information. > > Currently, in order to ensure that all instances are running after a > deployment we run JMeter and look at all the JSP pages manually until we > see that we have hit all 9 web instances. This is not only very manual > but also tedious because of non-RR LB algorithms there may be some > instances that aren't hit that often. > > I was thinking of writing some BeanShell scripts to automate this process. > > Essentially, what I need is: > > 1. a way to obtain the HTTP response of a particular JSP,
Use the HTTP Sampler. > 2. extract the strings that represent the instance hit and track that > against a "global" list > 3. once all instances are hit in the "global" list - simply stop the test > 4. print a message on the screen saying something like "All 9 instances > running" once test stopped The rest can be done with the BeanShell Post-Processor. Possibly easier to use the RE Post-Processor to extract the string. The BSH script can then mark the string as seen, e.g. using a Hash and counting when there are nine entries. > How hard is this to do. Any tips / pointers / examples / help would be > appreciated. If you are competent in Java, then it should not be too hard. Read the mailing list for BSH examples. > Thanks, > > --Nikolaos > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

