-
-
Notifications
You must be signed in to change notification settings - Fork 46
Improved retry strategy in httpx transport #848
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Thanks for bringing this up! I have a few thoughts on this: First, I think the retry semantics on the streaming HTTP helpers are currently broken. I don't think the retry does any Range-request magic, so we'll just get the same source line Second, I'm a bit hesitant about introducing a dependency on While we're working on this, if you're on a bumpy connection, have you considered setting Looking forward to hear your thoughts! |
|
Hi Leon, thanks for your response. After hours of debugging, we finally managed to get it working. Our bumpy network would cause a TransportError every now and then while we were loading the "default" dataset with 4.1M entries.
|
IIUC, you would like the retry counter to be reset if at least one byte flows in again after a Does
Yeah, I guess the right thing to do here would be to reset the counter and retry in the indexer, but that's a lot of work touching a few layers for something that hasn't really been that much of an issue so far. How do you feel about #857. It tries to stream only once and then falls back to fetching. Does that solve your issue. Related, have you tried setting setting |
Ingestion failed for us because of our bumpy network.
It turns out that the retry strategy in
stream_http_linesis quite basic: retry 3 times and sleep 1 second in between.This PR improves the
stream_http_linesfunction retry strategy. It does so by defining a global retry strategy (exponential backoff) at the level of thehttpx_sessionclient defined in yente.data.util.