JMS: mark session as failed on no reply during specified timeout

I am looking for a way to mark JMS “sessions” of gatling as errors (KO) if they don’t get a reply during the given timeout.

At the moment my simulations would keep running forever waiting for those delayed/lost reply messages unless a simulation.maxDuration is specified, in which case the missing messages still won’t be counted as KO and I have to evaluate the ratio of the “pending” requests at the moment of completion, which is not very handy for parameterized automatic runs.

I thought that the JMS protocol’s “receiveTimeout” would help me, but this seems to be a technical parameter that doesn’t influence the reporting and is detached from the actual request.

The “gatling.http.ahc.requestTimeout” seems to be close to what I am looking for, but looks to be http specific.

Questions:

  • Is it possible to implement this timing out logic using the gatling DSL, and if so - where should I look at?
  • Would such feature be a useful contribution to JMS / generic DSL?

Yes, it seems JMS’s receiveTimeout is only used for setting the MessageConsumer receiveTimeout, so it’s not per request.
I don’t see a way to do what you want with current impl.

Indeed, contributions are very welcome!

Cheers,

I have opened https://github.com/gatling/gatling/issues/2875 as the starting point.

Will try to find some time to look at it in the near future.

@Stéphane thank you for the quick reply!