Feeders: How to handle .csv files / lists without a header

Hej Community,

I do normally use gatlings build in feeders like this

val feeder = csv("sample.csv") ... feed(feeder) .exec(http("Test") .get(""${header_name_in_csv}"")

But how am I supposed to work with data-files which won’t have a header.

I tried to do something like this but can’t get it to run.

`
val list = Source.fromFile(“sample.csv”).getLines().toList

val feedlist = Iterator.continually(list)
`

I have to approaches in mind:

  1. I manipulate the file and add a head first or
  2. I try to edit the map which comes out "val feeder = csv(“sample.csv”)

But as a non-scala-pro I don’t know how to this.

Any help appretiated.

Greetings from Germany

Not supported atm. If you don’t feel confident in contributing, I suggest you add a header line to your file.

Thank your for the fast response, Stéphane.