applications-service-performance-tests

Pre-requisites to run performance test suite:

  1. Install Java JDK 8 or above
  2. Install apache maven
  3. Install apache jmeter

Test parameters

BASE_URL- Application url, currently defaulted to local environment. USERS - Number of users (threads), Defaulted to 1. RAMP_UP_PERIOD - Period of time over which to ramp up to number of threads as defined by USERS. Defaulted to 1. LOAD_DURATION - Period of time maintain maximum number of threads as defined by USERS .

To execute Performance tests in GUI Mode, execute below command from the root of the project:

  1. jmeter -t src/test/jmeter/ApplicationsServiceMyselfJourneyTestPlan.jmx

  2. jmeter -t src/test/jmeter/ApplicationsServiceAgentJourneyTestPlan.jmx

  3. jmeter -t src/test/jmeter/ApplicationsServiceOrgJourneyTestPlan.jmx

  4. You will now see the Jmeter application opened with the Test Plan

  5. You can now make any changes to the test plan using GUI and save them

  6. Always execute using 1 user in GUI mode as more users will cause GUI to hang up

To execute Performance tests in NON-GUI Mode:

  1. At the root of the project Create a folder called testResults and give full read and write access to it

  2. Inside the testResults folder create a folder called JmeterTestResults and give full read and write access to it

  3. Inside the testResults folder create a folder called tests and give full read and write access to it

  4. Inside the tests folder create a folder called Agent and give full read and write access to it

  5. Inside the tests folder create a folder called Myself and give full read and write access to it

  6. Inside the tests folder create a folder called Org and give full read and write access to it

  7. Then execute below command with USERS, RAMP_UP_PERIOD and LOAD_DURATION depending on requirement

    jmeter -n -f -JUSERS=1 -JRAMP_UP_PERIOD=1 -JLOAD_DURATION=120 -t ./src/test/jmeter/ApplicationsServiceMyselfJourneyTestPlan.jmx -l ./testResults/JmeterTestResults/ApplicationsServiceMyselfJourneyTestPlan.jtl -e -o ./testResults/tests/Myself/Output

    jmeter -n -f -JUSERS=1 -JRAMP_UP_PERIOD=1 -JLOAD_DURATION=120 -t ./src/test/jmeter/ApplicationsServiceAgentJourneyTestPlan.jmx -l ./testResults/JmeterTestResults/ApplicationsServiceAgentJourneyTestPlan.jtl -e -o ./testResults/tests/Agent/Output

    jmeter -n -f -JUSERS=1 -JRAMP_UP_PERIOD=1 -JLOAD_DURATION=120 -t ./src/test/jmeter/ApplicationsServiceOrgJourneyTestPlan.jmx -l ./testResults/JmeterTestResults/ApplicationsServiceOrgJourneyTestPlan.jtl -e -o ./testResults/tests/Org/Output

  8. After the above execution is completed navigate to below folder depending on test plan that was executed above

    testResults > tests > Myself > Output

    testResults > tests > Agent > Output

    testResults > tests > Org > Output

  9. Open index.html file using any browser which will display the performance test results in a web page

To execute Performance tests in NON-GUI Mode using MAVEN:

  1. execute below command with USERS, RAMP_UP_PERIOD and LOAD_DURATION depending on requirement

    mvn clean compile verify -DUSERS=5 -DRAMP_UP_PERIOD=5 -DLOAD_DURATION=180

  2. After the above execution is completed navigate to below folder

    target > jmeter > reports > applications-service-performance-tests

  3. Open index.html file using any browser which will display the performance test results in a web page