Hi Team,
Problem : Capturing the response time for the batch request.
const responses = http.batch([
[‘GET’, ‘https://test.k6.io’, null, { tags: { ctype: ‘html’ } }],
[‘GET’, ‘https://test.k6.io/style.css’, null, { tags: { ctype: ‘css’ } }],
[‘GET’, ‘https://test.k6.io/images/logo.png’, null, { tags: { ctype: ‘images’ } }],
]);
I can capture the individual response time like below
console.log('Response time for single response: ‘+ responses[1].timings.duration + ’ ms’);
I can sum all the timings of individual responses for the batch response time, but that is not the correct way for the parallel request. Is there any other way to capture the timings? Guide me on this.