NicolasN
Denoβ€’15mo agoβ€’
7 replies
Nicolas

Concurrent fetch timing

Hey all :playful_deno:

I'm trying to find a way of accurately timing a few fetch calls that are triggered concurrently. I tried something basic, but each new request will have an increased time, probably due to the internal fetch pool having some delay to send new requests:

functionCalledConcurrentlyManyTimes() {
  // start timer
  fetch(url).then((response) => {
    // end timer
  }
}


I read all pages of doc and GitHub issues I could find on the subject, the node:perf_hooks API does not seem to implement resource watching, and I'm out of idea to make that work πŸ€”

Any help is appreciated! Cheers.
Was this page helpful?