Skip to content

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Nov 11, 2025

Backport of #12901 to release/13.0

/cc @eerhardt

Customer Impact

When someone has Azure resources in their app, the "roles" resource is getting redeployed each time the app is run locally. This slows down the dev's inner loop.

Testing

Manually tested the roles resource is cached correctly. Also added a new unit test for the scenario.

Risk

Low. The fix is bringing parts of code that shipped earlier in Aspire 9.5.

Regression?

Yes

@github-actions
Copy link
Contributor Author

github-actions bot commented Nov 11, 2025

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 12903

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 12903"

Everytime we check if we need to redeploy an Azure "roles" resource in run mode, we are getting a different CheckSum. This is because we are overwriting the "known parameters" like PrincipalId and PrincipalType with 'null' values, because these values aren't available yet.

The fix is to skip setting those known parameters, like we did in previous versions.

Fix #12651
@github-actions github-actions bot force-pushed the backport/pr-12901-to-release/13.0 branch from 4088ae3 to 8480d9d Compare November 11, 2025 19:42
@eerhardt eerhardt added the Servicing-consider Issue for next servicing release review label Nov 11, 2025
@eerhardt eerhardt closed this Nov 11, 2025
@eerhardt eerhardt reopened this Nov 11, 2025
@davidfowl
Copy link
Member

@eerhardt who sets skipKnownValues to true?

@eerhardt
Copy link
Member

eerhardt commented Nov 12, 2025

@eerhardt who sets skipKnownValues to true?

The only place it gets set to true is in GetCurrentChecksumAsync(AzureBicepResource resource, IConfiguration section, CancellationToken cancellationToken = default).

The other caller is in BicepProvisioner.GetOrCreateResourceAsync, and this doesn't pass skipKnownValues.

This was referenced Dec 17, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Dec 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants