k6 is a tool by Grafana that allows us to quickly replicate a sequence of HTTP requests through a website. This facilitates performance testing.

Requirements

  • har-to-k6 converter, a NodeJS tool
  • Setup yourself to run k6. The docker version is quicker to setup, the local version allows you to make use of local files more easily

Replicating the processes

  • Record the sequence of HTTP steps you’re interested in into an HAR File
  • Download the file
  • Convert it into a JavaScript script using the har-to-k6 <har_file> -o <output-file>
  • run k6 via the CLI or Docker
    • Docker command : docker run --rm -i grafana/k6 run - <script.js