Feeders across injectors

Hi Gatling community!

Let’s say I have a scenario which uses some custom feeder circularly, and this feeder contains 100 items. Let’s also say that this feeder is called 100 times during the scenario.
If we run in a single machine, then the feeder goes through all 100 items.
From what I saw, when the same simulation runs from FrontLine with 5 injectors, then each injector machine calls the feeder 20 times, but in each machine the feeder starts from scratch, i.e. from the first item - meaning that 20 items are reached 5 times and 80 items are never reached.

Is there a workaround for this? Is there a way to split the load between the injectors, but also to make sure that different items are fed in each injector?



shard is exactly created for such usage.
Did you try it? Did you find something that doesn’t work as you like with it?

Hope this helps!


Thank you @sbrevet! I’m new to the FrontLine and was not aware of this option, will definitely give it a try!

Hi again @sbrevet, if a “shard” feeder is used out of the context of Enterprise, what will be the outcome? In the documentation it says it’s a “noop”, but does it mean that the feeder will not feed anything?
If so, what’s the best way to check that we’re in the context of Enterprise?


When not used with Gatling Enterprise, shard won’t do anything and the feeder will behave as usually and use the whole stock of data.

So, you’re running from Gatling Enterprise (FrontLine is the former name). It’s why I considered the shard modifier. When running locally, shard won’t do anything (ie. won’t split data across injectors) as Gatling Open Source is an application on one computer.

So as I understand it, it reverts to “queue” strategy?

Right, I just wondered what would happen when we debug our code locally.

Sharding and strategy are orthogonal.

What do you mean? I thought that you could use “shard”, instead “queue” or “circular”, but not both at the same time. Is that not the case?

What made you think they can’t be used together?
Strategies and shard are documented in different sections, so yes, they are unrelated and can be used together.

Great, thanks @slandelle :slight_smile:

Hi @slandelle and @sbrevet,

I’m struggling a bit with the sharded feeder. I’ve made the change to enable sharding on the feeder we’re using, but it seems that the records are still not distributed between the injectors.

This is the relevant code -
.exec(session => {


I only added the “shard” method.
myTenantsData(tenantType) returns the type Vector[Record[Any]], so the feeder is created implicitly from the vector.

Am I doing anything wrong here?


Are you running on Gatling Enterprise?
As highlighted in the documentation, shard is an Enterprise only feature.

Yes. But I discovered a possible different problem, so ignore this for now :slight_smile: