Queue too slow ?

Hello! I'm implementing Cloudflare Queue in my projects. My Producer and Consumer are in the same Worker. However, I expected a shorter time to send messages.
const startedAt = Date.now()
await env.MY_QUEUE.send({ foo: "bar"})
console.info("took", Date.now() - startedAt)
const startedAt = Date.now()
await env.MY_QUEUE.send({ foo: "bar"})
console.info("took", Date.now() - startedAt)
After some tests, I get an average of 160 ms Shouldn't it be faster, since they are on the same worker? Is my test wrong or I missed something?
1 Reply
Want results from more Discord servers?
Add your server