-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
perf(s3): Provide direct pre-signed download link #54436
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -302,15 +302,28 @@ public function isLocal(); | |
| public function instanceOfStorage(string $class); | ||
|
|
||
| /** | ||
| * A custom storage implementation can return an url for direct download of a give file. | ||
| * A custom storage implementation can return a url for direct download of a give file. | ||
| * | ||
| * For now the returned array can hold the parameter url - in future more attributes might follow. | ||
| * For now the returned array can hold the parameter url and expiration - in future more attributes might follow. | ||
| * | ||
| * @return array|false | ||
| * @param string $path Either the path or the fileId | ||
| * @return array{url: ?string, expiration: ?int}|false | ||
| * @since 9.0.0 | ||
| * @deprecated Use IStorage::getDirectDownloadById instead. | ||
| */ | ||
| public function getDirectDownload(string $path); | ||
|
|
||
| /** | ||
| * A custom storage implementation can return a url for direct download of a give file. | ||
| * | ||
| * For now the returned array can hold the parameter url and expiration - in future more attributes might follow. | ||
| * | ||
| * @param string $fileId The fileId of the file. | ||
| * @return array{url: ?string, expiration: ?int}|false | ||
| * @since 33.0.0 | ||
| */ | ||
| public function getDirectDownloadById(string $fileId): array|false; | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a breaking change for apps that provide a storage wrapper 🙈
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Indeed. Surprised me a bit while doing some groupfolders changes; thought it was my fault. ;-)
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Correction: the real issue was outdated stubs in gf repo that lacked this new method. All good now (at least in terms of fallback behavior). |
||
|
|
||
| /** | ||
| * @return void | ||
| * @throws InvalidPathException | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.