Skip to content

Latest commit

 

History

History
36 lines (32 loc) · 1.38 KB

README.md

File metadata and controls

36 lines (32 loc) · 1.38 KB

Introduction

Load testing APIs

Getting Started

  1. Install Jmeter https://jmeter.apache.org/

  2. Open .jmx file in jmeter and run test.

  3. This is optional unless you are doing it on cloud. To run tests against any server you will need jwt. You can get jwt from swagger request. Or there are other ways, just get he jwt already .

  4. This is optional unless you are doing it on cloud. Add the jwt to corresponding Http Header Manager.

  5. This is optional unless you are doing it on cloud. If you want to bypass load balancer, setup to hit nginx-ingress directly

  6. Should be able to run tests now.

  7. Once the test is built or modified in jmeter, it can be run through command line also.

  8. Tests cycles through users.csv file

    To run

    jmeter -n -t pathTo\UserServiceTests.jmx  -l pathTo\UserServiceTestResults.csv 
    

    To generate the report though command line

    jmeter -g pathTo\UserServiceTestResults.csv -o pathTo\UserServiceTestResults
    

SetUp to hit nginx-ingress directly (i used gcloud).

  1. Install kubectl
 gcloud components install kubectl
  1. Get credentials
 Run gcloud --project my-project-name container clusters get-credentials project-name
  1. Forward the port
 Run kubectl --namespace nginx-ingress port-forward nginx-name 80 (get running ingin-ingress from cloud)