Repository navigation
Add Azure Storage migration control rows - #1441
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The migration test file is under uppercase Test/ instead of the project’s lowercase test/ path, leaving all 15 cases uncompiled and undiscovered on case-sensitive checkouts.
1 open issue
What changed in this PR
Adds an Azure Storage helper for migration-attempt control rows, without enabling migration or changing normal workload processing.
Changes:
- Uses migration GUIDs to isolate attempts in the task hub’s
MigrationCtrltable. - Preserves Storage response time and ETags, with conditional updates and explicit error propagation.
- Adds focused tests for row format, missing data, stale updates, and attempt isolation.
| File | Description |
|---|---|
Test/DurableTask.AzureStorage.Tests/AzureStorageMigrationTests.cs |
Adds local-transport tests for migration control reads and updates. |
src/DurableTask.AzureStorage/AzureStorageMigration.cs |
Implements per-attempt control-row reads and ETag-conditional replacements. |
Review effort: Balanced
sophiatev
marked this pull request as ready for review
November 21, 2026 04:47
halspang
reviewed
Nov 23, 2026
halspang
approved these changes
Nov 23, 2026
This file contains hidden or 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
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.

Migration needs a separate control row for each attempt so source hosts can read its drain flag and access deadline without confusing it with a later attempt. Add the AzureStorageMigration helper for the task hub's MigrationCtrl table, keyed by the migration GUID. Reads retain the Storage response time and ETag; updates replace an existing row only when its ETag still matches. Missing rows are not recreated, and failures other than missing reads or stale-update conflicts reach the caller.
This is the first PR extracted from stevosyan/storage-migration. The production helper is unchanged from that branch. SAS renewal and runtime activation will be wired in later PRs, so this PR does not enable migration or change normal workload processing. It adds no performance telemetry.
Validation: 15 focused tests passed on each of net8.0 and net48 (30 total). The tests use the Table SDK with a local HTTP handler and cover the row format, Storage clock, missing fields and rows, stale renewal after drain, separate migration attempts, and error propagation.