-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Overhaul and simplify proxy upload routines, handling ConnectionErrors
Effectively, we do the following here: 1. Always check for /status if available when uploading via a proxy 2. If /status has a `complete: false` field, poll up to 15 minutes 3. Raise a RetryableUploadException or fail based on /status code (2) specifically fixes bugs we were encountering wherein the Python client could send all of the data and either: A. Send a file with an error but not be listening for the reply, experience a ConnectionError, and then retry automatically even if the file was invalid and the proxy returned a 400 B. Send data too fast for the proxy to compress (with data getting buffered in the ALB/nginx) and then abort *despite the proxy ultimately completing successfully* (A) led to bad files not being caught by the proxy. (B) could lead to duplicate uploads to to erroneous retry requests. Both of these fixes bring our implementation into line with the frontend JS code on app.onecodex.com.
- Loading branch information
1 parent
df84f43
commit 74a50e9
Showing
4 changed files
with
77 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters