How to run a test plan for a specified period of time in Apache Jmeter,in my previous post you learned Proxy set up,record script in Jmeter for web applications,now in this post you will learn how to run a test plan for a specified period of time in Apache Jmeter.
Before you read this post,please read below posts
Please follow below steps to run your Test plan for a specific amount of time in Jmeter.
Step 1 : Add Thread Group to Test Plan,in Thread group mention specified Thread Users,Ramp-Up Period,Loop Count.
Step 2 : Add HTTP Request Default to provide Server Name/Ip and Port number to perform on specific applications.
Step 3 : Add or Record HTTP Samples for AUT.
Step 4 : Now add Summary Report/View Result Tree from Listeners.
Step 5: Now go to Thread Group Select Scheduler check box ,it will enable Schedule Configuration fields to enter the details,which will have below fields.
Duration(Seconds)
Start Up Delay(Seconds)
Start Time 2016/10/10 22:39:23
End Time 2016/10/10 22:39:23
Start and End time is default no need of changing anything ,just you need to change Duration (Seconds) field as below.
In case you want to run a test plan for 5 minutes then in Seconds 1 minute = 60 sec,so 5 minutes = 300 seconds.Simple enter 300 in Duration field,Save the script as .jmx extension.
Now run the Test Plan it will run up to 5 minutes and reports will generate as below.
Note : Select LoopCount as Forever check box.
Summary Report
Summary Report will show you the details as below
Summary Report at 1 minute 16 seconds
Summary Report at 4 minutes 6 seconds.
Summary Report at 5 Minutes means 300 Seconds as below.
Here all threads are stopped ,please see below screenshot.
Like this you can run your Test plan up to specified period of time in Jmeter.