Skip to content

docs: specify S3-compatible ETag format for single-part and multipart uploads#392

Merged
bootjp merged 2 commits intofeature/s3-compatiblefrom
copilot/sub-pr-391
Mar 21, 2026
Merged

docs: specify S3-compatible ETag format for single-part and multipart uploads#392
bootjp merged 2 commits intofeature/s3-compatiblefrom
copilot/sub-pr-391

Conversation

Copy link
Contributor

Copilot AI commented Mar 21, 2026

The design doc referenced ETag computation without defining the required format, leaving ambiguity that would break S3 client/SDK compatibility for integrity checks and conditional requests.

Changes

  • New section 5.4 "ETag computation" — explicitly defines both formats:
    • Single-part (PutObject): hex(md5(object_body))
    • Multipart (CompleteMultipartUpload): hex(md5(md5_bytes(part_1) || ... || md5_bytes(part_N))) + "-N"
  • Per-part ETags use the single-part MD5 format; CompleteMultipartUpload must validate caller-supplied ETags against stored part descriptors before committing the manifest
  • Updated the PutObject flow step (§7.1) to reference the MD5 computation explicitly

Multipart ETag formula:

ETag = hex(md5(md5_bytes(part_1) || md5_bytes(part_2) || ... || md5_bytes(part_N))) + "-N"

where md5_bytes(part_i) is the raw 16-byte MD5 digest of part i's body.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI changed the title [WIP] [WIP] Address feedback on etag spec in S3-compatible adapter design docs docs: specify S3-compatible ETag format for single-part and multipart uploads Mar 21, 2026
Copilot AI requested a review from bootjp March 21, 2026 19:34
@bootjp bootjp marked this pull request as ready for review March 21, 2026 19:36
@bootjp bootjp merged commit f541a38 into feature/s3-compatible Mar 21, 2026
4 checks passed
@bootjp bootjp deleted the copilot/sub-pr-391 branch March 21, 2026 19:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants