kubeshop / xk6-tracetest

Apache License 2.0
9 stars 2 forks source link

fix: adding concurrency check on Tracetest constructor #6

Closed danielbdias closed 1 year ago

danielbdias commented 1 year ago

This PR aims to fix a concurrency problem that we have when we execute load testing with this plugin, as described on https://github.com/kubeshop/xk6-tracetest/issues/5

Steps to recreate the problem:

  1. Clone Tracetest
  2. Go to testing/load folder and execute ./run.bash
  3. After k6 start to run, interrupt the process with a Ctrl+C
  4. Try to run the command ./k6 run load-test.js -o xk6-tracetest
  5. The error should appear as k6 starts

Steps to test this PR:

  1. Clone Tracetest
  2. Go to testing/load folder and change line 37 of ./run.bash (here), from
    xk6 build v0.42.0 --with github.com/kubeshop/xk6-tracetest \

    to

    xk6 build v0.42.0 --with github.com/kubeshop/xk6-tracetest@v0.1.4-rc.1 \
  3. Run ./run.bash and interrupt k6 with Ctrl+C
  4. Try to run the command ./k6 run load-test.js -o xk6-tracetest
  5. The test should continue to execute successfully

Changes

Fixes

Checklist