Skip to content

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Feb 19, 2025

Backport of #7677 to release/9.1

/cc @eerhardt

Customer Impact

Customers are unable to use Azure AppInsights, OpenAI, and CosmosDB existing resources. It will always try provisioning new resources even when calling "AsExisting". For Azure Redis, using AsExisting doesn't work because the bicep fails to deploy since we are setting properties on an existing resource. See https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/bicep-core-diagnostics#BCP173

Testing

New bicep tests for these scenarios added.

Risk

Low. Since we are changing the bicep generation code to support existing resources, we may affect the bicep generation of new resources. But existing bicep baseline tests are passing. The only test that required a change was for AppInsights, but that is a simple resource reordering in bicep, which shouldn't affect it.

Regression?

No

These resources don't support existing resources yet. Adding support to finish all the Azure resources for existing.

Note that for CosmosDB, we only explicitly set DisableLocalAuth if WithAccessKeyAuthentication is called. We don't want to disable local auth on an existing resource if it is already enabled as that might break other uses of the resource.

Fix #7665
…d Redis

Existing Azure resources can't be directly updated in bicep. When trying to deploy these changes it raises an error "Error BCP173: The property "properties" cannot be used in an existing resource declaration. [https://aka.ms/bicep/core-diagnostics#BCP173]"
…e added to the infrastructure in the opposite order now.
@danmoseley danmoseley added this to the 9.1 milestone Feb 19, 2025
@danmoseley danmoseley added the area-integrations Issues pertaining to Aspire Integrations packages label Feb 19, 2025
@eerhardt eerhardt closed this Feb 19, 2025
@eerhardt eerhardt reopened this Feb 19, 2025
@danmoseley danmoseley enabled auto-merge (squash) February 19, 2025 22:19
@danmoseley danmoseley merged commit 6e5bf1b into release/9.1 Feb 19, 2025
70 checks passed
@danmoseley danmoseley deleted the backport/pr-7677-to-release/9.1 branch February 19, 2025 22:30
@github-actions github-actions bot locked and limited conversation to collaborators Mar 22, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-integrations Issues pertaining to Aspire Integrations packages

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants