1

I'm trying to run a simple load test using Artillery. Ideally, each request should include data for a user, taken from the payload file:

config:
  target: http://localhost:8000
  payload:
    path: "../SampleData.csv"
    fields:
        - "userId"
        - "username"
        - "password"
    order: sequence
    skipHeader: true
  phases:
    - duration: 30
    - arrivalRate: 10
scenarios:
  - flow:
      - post:
          url: "/register"
          json:
            uid: "{{ userId }}"
            alias: "{{ username }}"
            password: "{{ password }}"

The problem I'm running into is that with the above yml, Artillery is sending each line in the file 10 times. Doesn't make a difference if I use

duration: 30
arrivalRate: 10

or

duration: 30
arrivalCount: 300

It sends 10 requests with the data from line 1, then 10 requests with the data from line 2, etc. So at the end of 30 seconds, it has sent the first 30 lines of the file 10 times each. I'd like each of the 300 lines of the payload file to be sent once (at a rate of 10/second). How can I get it to send new data with each request?

Stuart
  • 48
  • 5
  • I have the same problem. I'm trying to get more info in their repo: https://github.com/artilleryio/artillery/issues/922#issuecomment-1023710167 – luislhl Jan 27 '22 at 22:53

1 Answers1

0

I don't know if you found a solution to this but I ran into the same issue.

In the payload section of the script add order and skipHeader attributes like the example below.

payload:
  path: "data.csv"
  order: sequence
  skipHeader: true
  fields:
     - field1
winst135
  • 3
  • 4