I’m using the asyncRequest in an iteration like this
export default function () {
const token = `${__ENV.AUTH_TOKEN}`;
const target = `${__ENV.TARGET}`
const params = {
headers: {
'Content-Type': 'application/json',
'Authorization': token
},
};
http.asyncRequest('GET',uri,null, params)
}
And I’m targeting two different services with the same scenario and achieving totally different offered loads (aka rate(k6_http_reqs_total[1m])
). By using an asyncRequest + discardResponseBodies: true
and doing nothing with the response I was expecting k6 to keep hitting the server independently of receiving responses or not.
So the question is
Does an iteration completes only when all in fly requests (even asynchronous ones) complete?
BTW I know there is a constant-arrival-rate executor that starts iterations independently of target responses.