Skip to content

Align Stage Block Content-MD5 response with Azure - #2811

Open
Akanksha Jain (jainakanksha-msft) with Copilot wants to merge 6 commits into
mainfrom
copilot/fix-azure-azurite-issue-2394
Open

Akanksha Jain (jainakanksha-msft) with Copilot wants to merge 6 commits into
mainfrom
copilot/fix-azure-azurite-issue-2394

Conversation

Copilot AI commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Stage Block omitted Content-MD5 even when clients supplied a valid MD5 checksum. Azure returns the calculated Content-MD5 for API versions after 2019-02-02, while continuing to return CRC64 when MD5 is not supplied.

  • Handler behavior
    • Return calculated Content-MD5 for Stage Block requests with Content-MD5 and API version newer than 2019-02-02.
    • Preserve computed x-ms-content-crc64 responses when no MD5 is supplied.
    • Keep 2019-02-02 behavior unchanged.
contentMD5: shouldReturnContentMD5 ? calculatedContentMD5 : undefined,
xMsContentCrc64: calculatedCRC64,
  • Regression coverage

    • Added focused Loki/SQL assertions for post-2019-02-02 MD5 response behavior.
    • Added coverage that 2019-02-02 still omits Content-MD5.
    • Kept existing CRC64 response behavior covered.
  • Changelog

    • Added an Upcoming Release Blob entry for the Stage Block response alignment.
Original prompt

Fix Azure/Azurite issue #2394. Align Stage Block responses with Azure: for API versions after 2019-02-02, when the request supplies Content-MD5, return the already calculated MD5 as the response Content-MD5; otherwise preserve calculated CRC64 behavior. Add a focused Loki/SQL regression assertion, an Upcoming Release ChangeLog entry, and run targeted tests, build, and lint. Keep the change limited to BlockBlobHandler and its focused tests. The locally validated implementation changed src/blob/handlers/BlockBlobHandler.ts, tests/blob/apis/blockblob.test.ts, and ChangeLog.md. Include 'Fixes #2394' in the PR body.

Copilot AI lite review requested due to automatic review settings September 24, 2026 08:38

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.


💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Co-authored-by: jainakanksha-msft <181211853+jainakanksha-msft@users.noreply.github.com>
Co-authored-by: jainakanksha-msft <181211853+jainakanksha-msft@users.noreply.github.com>
@jainakanksha-msft Akanksha Jain (jainakanksha-msft) changed the title [WIP] Fix Azure/Azurite issue #2394 by aligning Stage Block responses Return Content-MD5 from Stage Block Sep 24, 2026
@jainakanksha-msft
Akanksha Jain (jainakanksha-msft) marked this pull request as ready for review September 24, 2026 08:45
Co-authored-by: jainakanksha-msft <181211853+jainakanksha-msft@users.noreply.github.com>
Co-authored-by: jainakanksha-msft <181211853+jainakanksha-msft@users.noreply.github.com>
Copilot AI changed the title Return Content-MD5 from Stage Block Align Stage Block Content-MD5 response with Azure Sep 24, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Omitted-version handling and API-version boundary coverage remain unresolved.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 Low severity

Open (1)

Comment thread tests/blob/apis/blockblob.test.ts

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

No unresolved issues were identified, and the focused changes include regression coverage.

Review effort: Lite
Findings: None

Resolved since last review (1)

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🔵 Needs a closer look

Targeted tests, build, and lint were not executed, so runtime validation remains pending.

Review effort: Lite
Findings: None

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

No unresolved blocking issues were identified; standard CI validation remains appropriate.

Review effort: Lite
Findings: None

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

stageBlock API does not return Content-MD5

3 participants