sessionctx: avoid IMDS leak in TestSetTiDBCloudStorageURI#67604
Conversation
|
Skipping CI for Draft Pull Request. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughA test in the session variable module now sets the Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 golangci-lint (2.11.4)Command failed Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
The master agent encountered an error while processing. Please try again later. ℹ️ Learn more details on Pantheon AI. |
|
Hi @D3Hunter. Thanks for your PR. PRs from untrusted users cannot be marked as trusted with I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #67604 +/- ##
================================================
- Coverage 77.7488% 77.5060% -0.2429%
================================================
Files 1959 1964 +5
Lines 543393 551953 +8560
================================================
+ Hits 422482 427797 +5315
- Misses 120070 124142 +4072
+ Partials 841 14 -827
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
|
/retest |
|
@D3Hunter: PRs from untrusted users cannot be marked as trusted with DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: joechenrh, lance6716 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
) ref pingcap#65526 (cherry picked from commit a69ecb8) Signed-off-by: okjiang <819421878@qq.com>
What problem does this PR solve?
Issue Number: ref #65526
Problem Summary:
TestSetTiDBCloudStorageURIis flaky in CI because it can trigger AWS IMDS credential probing when validatings3://blackholewithout explicit credentials. The test assertions pass, but background HTTP connection goroutines from that probe can still be alive when goleak runs, causing intermittent shard failures.What changed and how does it work?
This PR adds a test-scoped environment guard in
TestSetTiDBCloudStorageURI:t.Setenv("AWS_EC2_METADATA_DISABLED", "true")This disables EC2 IMDS probing only for this test process, removing the flaky goroutine source while keeping the existing behavior checks and assertions unchanged.
Check List
Tests
Side effects
Documentation
Release note
Summary by CodeRabbit