sync changed files to S3 based on checksum, if present #9074
Labels
feature-request
A feature should be added or improved.
needs-review
This issue or pull request needs review from a core team member.
p2
This is a standard priority issue
s3
Describe the feature
This is the same as #8377 and #7011:
aws s3 sync
should be able to detect files that need synchronization based on the checksum stored in S3, not size/timestamp.Both issues were closed in favor of #6750 but #6750 only goes half the way: it uploads the checksum as metadata, but doesn't take it into account when computing the sync candidates.
Use Case
A prototypical use case looks like
Because the files are generated in CI, they always have the current timestamp, so all of them will be synced to S3, even though only few of them may have changed.
--size-only
is not a viable alternative, as it skips, for example, typo fixes that often don't change the file size.Proposed Solution
Add a flag
--checksum-only
or the like. If that flag is present, rather than retrieving file timestamp and size from S3 and comparing it to the local values, retrieve the checksum that was stored during the previous upload using--checksum-algorithm
and compare it to the locally computed value.Other Information
Current behavior:
Desired behavior:
Acknowledgements
CLI version used
aws-cli/2.21.0
Environment details (OS name and version, etc.)
exe/x86_64.opensuse-tumbleweed.20241107
The text was updated successfully, but these errors were encountered: