Skip to content

FetchBatch bug ("nats: timeout error") with large RTT to the NATS server? #1683

Answered by piotrpio
ashumkin asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @ashumkin. The timeout you're encountering is introduced as a safeguard in case we don't get the timeout response from the server. It has to be larger than the expiry set on the pull request, but the value needs to be arbitrary since we can't really speculate on the RTT.

That being said, I see that the added time is way to small now (10ms), giving high probability of hitting the internal (client) timeout rather than waiting for server timeout. I'll increase the value so that it should work fine under most circumstances but you still may be getting timeout errors on unusually high RTTs.

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
1 reply
@ashumkin
Comment options

Comment options

You must be logged in to vote
2 replies
@ashumkin
Comment options

@ashumkin
Comment options

Answer selected by ashumkin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants