-
Notifications
You must be signed in to change notification settings - Fork 363
Cosmos: Update key-based live tests to fixed self-owned accounts. #5049
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
f28292a
8e272f6
67b02b9
8a9ab21
5c88035
a088719
83115ef
5a1b948
7b2a119
13df811
0edf8b0
172530d
f1de010
64c3117
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -76,11 +76,31 @@ extends: | |
| Path: sdk/cosmos/inmemory-emulator-matrix.json | ||
| Selection: all | ||
| GenerateVMJobs: true | ||
| LiveTestMatrixConfigs: | ||
| # Cosmos_live_test runs against fixed, self-owned accounts (see | ||
| # sdk/cosmos/pipeline/README.md) instead of resources deployed fresh each run, | ||
| # so it lives in FixedAccountMatrixConfigs rather than LiveTestMatrixConfigs. | ||
| # PreTestRunSteps resolves the account selected by each matrix leg's | ||
| # AccountSelector from the rust-ci secret, in place of | ||
| # ARM deployment (DisableAzureResourceCreation: true is set automatically for | ||
| # this leg by archetype-sdk-client.yml). | ||
| FixedAccountMatrixConfigs: | ||
| - Name: Cosmos_live_test | ||
| Path: sdk/cosmos/live-platform-matrix.json | ||
| Selection: sparse | ||
| GenerateVMJobs: true | ||
|
Comment on lines
+97
to
101
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The scope of this PR is the move to fixed accounts; adding a sweeper is a separate concern with its own design questions (schedule, age threshold, safety against a concurrent run, which identity runs it).
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it is not completely orthogonal - for example one step to take now might be to not just use UUID based names - but prefix them with some tiemstamp - so, that any async sweeper could delete let's say db/collections that were created >12 hours ago? Not necessarily blocking for this PR - but worth thinking about this because it will become a hot topic as soon as this PR is merged. |
||
| PreTestRunSteps: | ||
| - template: /sdk/cosmos/pipeline/resolve-test-account-steps.yml | ||
| parameters: | ||
| AccountSelector: $(AccountSelector) | ||
| LiveTestMatrixConfigs: | ||
| # Thin-client (GatewayV2) legs still use ARM-deployed per-run Cosmos | ||
| # accounts (they run against $(thinclient-test-endpoint)/$(thinclient-test-key) | ||
| # for the thin-client itself, but their primary client still needs an | ||
| # ARM-provisioned account). Left on the legacy per-run path intentionally. | ||
| - Name: Cosmos_live_thinclient | ||
| Path: sdk/cosmos/live-thinclient-matrix.json | ||
| Selection: all | ||
| GenerateVMJobs: true | ||
| # Dedicated live leg that runs the full integration suite with the primary | ||
| # (data-plane) client authenticated via Entra ID (AAD) instead of the | ||
| # account key. `AZURE_COSMOS_AUTH_MODE=aad` surfaces as a job env var and | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| { | ||
| "displayNames": {}, | ||
| "matrix": { | ||
| "Agent": { | ||
| "ubuntu": { | ||
| "OSVmImage": "env:LINUXVMIMAGE", | ||
| "Pool": "env:LINUXPOOL" | ||
| } | ||
| }, | ||
| "RustToolchainName": ["stable"], | ||
| "Account Settings": { | ||
| "Session SingleRegion GatewayV2": { | ||
| "ArmTemplateParameters": "@{ defaultConsistencyLevel = 'Session'; testCategory = 'gateway_v2' }" | ||
| }, | ||
| "Session MultiRegion GatewayV2": { | ||
| "ArmTemplateParameters": "@{ defaultConsistencyLevel = 'Session'; enableMultipleRegions = $true; testCategory = 'gateway_v2_multi_region' }" | ||
| } | ||
| } | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Daniel Jurek (@danieljurek) or Ben Broderick Phillips (@benbp) can you review this please? I think you helped them originally so I don't have as much context.