I used Gatling for performance testing and a problem troubled me a lot recently.
we use “httpReq = httpReq.queryParam(paramName, paramValue)” to build query string. But if there is a space in the “paramValue”, an extra double quotations will be added to query string. This will cause our server cannot extract the key and value correctly.
For example: paramName=“filter”, paramValue=“flag:(A OR B) AND (NOT C)”.
We expected the request sent to server is: http://host:port/questions?filter=flag:(A OR B) AND (NOT C)
But actually, the request we get is http://host:port/questions?“filter=flag:(A OR B) AND (NOT C)” When the server receive this request, it found there are double quotation marks in the query string, so it takes the whole query as a single string, so it cannot to extract the filter and its value, then raise an error message.
How to avoid the double quotation marks to be added in this case? Could anybody help me here? thank you.
Could you please explain if the issue is with the code generated by the recorder, or with the way Gatling executes it at runtime.
Could you please provide an actionnable reproducer?
Which version of Gatling do you use?