Check performance Testing Of A RESTful API Using JMeter

Apache JMeter is an open-source software that is popular for performance testing. This tool is designed to load test functional behavior and measure performance.

Let’s see how we can use j meter step by step with API.

Download JMeter from this link.

Step 1

Open bin folder, then run jmeter.bat file

Step 2

Right click on TestPlan, add, then click Config Element select HTTP Header Manager as in depicted figure.

add

Step 3

After that add header values .

add

Step 4

After that Right click on Test Plan =>add=>Thread(users) =>Thread Group as in depicted figure.

add

Step 5

After that set the number of thread(users) and ramp-up period(in seconds) as in depicted figure.

group

Step 6

After that Right click on Thread Group=> Config Element=> HTTP Request Defaults as in depicted figure.

add

Step 7

After that add Your Server name or IP address and add your Protocol as in depicted figure,

Like Server name = facebook.com or (182.71.87.254)

Protocol[http]=http

server

Step 8

After that Right click on Thread Group=> Sampler=> HTTP Request as in depicted figure,

Group

In this frame select your protocol, select You Methods behavior (get,post,put,delete) and Enter your remaining Path in Path Box. If your method behavior is Get pass the value from URL . in the case of Post Behavior Pass value from BodyData. as in depicted figure.

request

Step 9

After that run you j-meter press green play button in upper side of tool bar. after that you will see the output in different format like graph result , table format,

Let’s see the result in graph format.

Right click on Thread Group, Listener, then Graph result as in depicted figure.

result

Up Next
    Ebook Download
    View all
    Learn
    View all