Elments Used on Jmeter

13
2 INTRODUCTION TO JMETER

Transcript of Elments Used on Jmeter

Page 1: Elments Used on Jmeter

2INTRODUCTION TO JMETER

Page 2: Elments Used on Jmeter

WHAT IS JMETER?

JMeter was first developed by Stefano Mazzocchi of the Apache Software Foundation, designed to

test and measure the performance and functional behavior of

client/server applications, such as web applications or FTP applications.

Page 3: Elments Used on Jmeter

A TYPICAL TEST PLAN WILL CONSIST OF ONE OR MORE : Thread Group: Each thread group simulates a single user.

Listeners: Provide access to the information gathered by JMeter about the test cases while JMeter runs. Since there are several listeners that come with JMeter it’s important to say that all of them save the same data, the only difference is in the way the data is presented on the screen.

Sampler: Tell JMeter to send a request to a server.

Logic Controllers: Determine the order in which samplers are processed.

Page 4: Elments Used on Jmeter

To understand the effect of Logic Controllers on a test plan, consider the following test tree: Test Plan

Thread Group Once Only Controller

Login Request (an HTTP Request ) Load Search Page (HTTP Sampler) Interleave Controller

Search "A" (HTTP Sampler) Search "B" (HTTP Sampler) HTTP default request (Configuration Element)

HTTP default request (Configuration Element) Cookie Manager (Configuration Element)

The first thing about this test is that the login request will be executed only the first time through. Subsequent iterations will skip it. This is due to the effects of the Once Only Controller .

Page 5: Elments Used on Jmeter

Timers: Allow JMeter to delay between each request that a thread makes.

Assertions: Allow you to test that your application is returning the results you expect it to.

Configuration Elements: A configuration element works closely with a Sampler. Although it does not send requests (except for HTTP Proxy Server ), it can add to or modify requests.

Pre-processor Elements: A Pre-Processor executes some action prior to a Sampler Request being made.

Post-Processor Elements: A Post-Processor executes some action after a Sampler Request has been madeA Post-Processor executes some action after a Sampler Request has been made.

Page 6: Elments Used on Jmeter
Page 7: Elments Used on Jmeter

Once JMeter runs, you will see two elements, Test Plan and

WorkBench

Page 8: Elments Used on Jmeter

Test Plan sample consisting of more than one Thread Group and multiple elements in each

Thread Group

Page 9: Elments Used on Jmeter

Test Plan sample having a single Thread Group incorporating multiple elements

Page 10: Elments Used on Jmeter

Thread Group sample with details is shown below

Page 11: Elments Used on Jmeter

The Response Assertion element shown in the following figure predefines the pattern matching conditions

Page 12: Elments Used on Jmeter

The Assertion Results element shown in following figure will capture these predefined patterns in the data or page

response and display them for further analysis

Page 13: Elments Used on Jmeter

Bibliography:

http://jmeter.apache.org/usermanual/test_plan.html