-
Notifications
You must be signed in to change notification settings - Fork 42
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
Add RemoteFilePersister #1202
Merged
Merged
Add RemoteFilePersister #1202
Conversation
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
ankur22
force-pushed
the
refactor/use-local-persister
branch
2 times, most recently
from
January 31, 2024 09:44
c2f30b9
to
ab79ae7
Compare
ankur22
force-pushed
the
add/remote-persister
branch
3 times, most recently
from
January 31, 2024 11:11
e39604f
to
dfafb6c
Compare
inancgumus
reviewed
Jan 31, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The feature is almost around the corner! Nice. Some suggestions.
inancgumus
reviewed
Jan 31, 2024
ankur22
force-pushed
the
add/remote-persister
branch
2 times, most recently
from
January 31, 2024 17:38
0d716f1
to
678b100
Compare
inancgumus
reviewed
Feb 1, 2024
ankur22
force-pushed
the
add/remote-persister
branch
from
February 1, 2024 11:00
e39930a
to
ac20d5b
Compare
inancgumus
approved these changes
Feb 1, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
This will be used to upload files (screenshots) to a remote location. It first retrieves the presigned url for the current file, then uploads the file with the new presigned url. It is possible to retrieve multiple presigned urls in one request, but the issue is that we don't know the names of the files before hand which is a requirement to retrieve the presigned urls.
The use of a default client might not be enough to cancel long running http requests. Enforcing a 10 second timeout in the http client will ensure that the request is timed out even if the context doesn't have a timer/cancel attached to it.
ankur22
force-pushed
the
add/remote-persister
branch
from
February 1, 2024 12:19
faa06d8
to
a01c52a
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What?
This adds a remote persister, which will upload files (screenshots) to the remote location. It uses a two request mechanism to:
Although it is possible to batch retrieve the pre-signed url, there is no easy way to retrieve the filenames that are required to retrieve the presigned urls, so it needs to be done one at a time when a request to persist the screenshot comes in.
Why?
To enable the browser module to upload screenshots to a remote location.
Checklist
Related PR(s)/Issue(s)
Updates: #1159