Repository navigation
fix: recover interrupted volumes and network deletion - #950
Merged
Merged
Conversation
|
Enclave skipped this draft pull request. It will run automatically when you mark the PR as Ready for review. |
Member
Author
|
@greptileai review |
alongubkin
force-pushed
the
alon/alien-1329-cloud-lifecycle-recovery
branch
from
October 8, 2026 12:58
2d21313 to
272e706
Compare
alongubkin
marked this pull request as ready for review
October 8, 2026 12:59
|
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.
An interrupted EBS resize returns AWS
IncorrectModificationStateas an untyped HTTP error, so the caller cannot wait for the accepted modification. Decode it as a volume conflict with the provider code retained, and retryModifyVolumeonly for throttling responses so ambiguous outcomes return to the controller for inspection.Network teardown retains children after a denied deletion but advances to the VPC, where retries never revisit those children. Revisit retained child cleanup before the parent, bound complete cleanup passes, and preserve a denied VPC as a domain failure rather than reporting deletion. The new counter defaults to zero for old checkpoints and resets on manual retry; no state variants change.
Validation: real signed EC2 HTTP error decoding, permission-restoration deletion, old parent-delete checkpoint recovery, bounded waits, and the existing AWS network lifecycle tests. Regression checks restore the offending behavior and require the focused cases to fail. The local regression suite is supplemented by the live AWS test below.
The provider behavior is documented in EC2 error codes and DeleteVpc.
Executed 83 AWS network/EC2 tests with
cargo nextest run -p alien-infra -p alien-aws-clients --lib --all-features -E "test(network::aws::) | test(modify_volume_decodes_in_progress)": all passed after rebasing onto current main. The three focused shared-crate regression cases fail when the offending behavior is restored.Live AWS validation passed:
delete_resumes_retained_children_after_real_permission_restorationcreates a complete real network, switches to an STS session explicitly denying security-group deletion, verifies independent subnets disappear while the denied group and parent VPC remain, restores permission, reloads an older parent-delete checkpoint, and finishes with an empty tagged inventory. No sweep leftovers remained. Run withcargo test -p alien-infra --features all-platforms --test aws_network_live delete_resumes_retained_children_after_real_permission_restoration -- --ignored --exact --nocaptureand the documented live/restricted-session credentials. TLS verification stays enabled;ALIEN_LIVE_TEST_CA_CERToptionally trusts an explicit runner CA.The actual EC2 endpoint also returned
IncorrectModificationStateafter an accepted 10→20 GiB resize; the live signed client decoded it asREMOTE_RESOURCE_CONFLICT. Both created test volumes were independently observed deleted. Live results were captured at2d2131324; the final rebase adds the newer main fixes without changing the tested network/EC2 paths.Greptile's resize-retry coverage finding is addressed by direct signed HTTP tests:
modify_volume_does_not_resend_an_ambiguous_failureverifies one request for HTTP 503, andmodify_volume_retries_an_explicit_throttling_responseverifies throttling retries. All three resize tests pass. Restoring the old generic retry policy makes the ambiguous-response and conflict request-count tests fail with four sends instead of one.Final rebased regression run passed 82 AWS network unit tests (one existing ignored test), 17 persistent-storage controller tests, three Azure handler/metadata tests, and the SDK conflict test; the two added retry tests also pass.