Skip to content

fix: Event Grid MI issue#2274

Open
Vamshi-Microsoft wants to merge 2 commits into
Azure-Samples:dev-v2from
Vamshi-Microsoft:vk-fix-eventgrid
Open

fix: Event Grid MI issue#2274
Vamshi-Microsoft wants to merge 2 commits into
Azure-Samples:dev-v2from
Vamshi-Microsoft:vk-fix-eventgrid

Conversation

@Vamshi-Microsoft

Copy link
Copy Markdown
Contributor

Purpose

This pull request implements a durable fix for the Event Grid system-topic subscription and role-assignment ordering issue (BUG-0061) in the Bicep infrastructure code, ensuring that role assignments are created before event subscriptions to prevent authorization errors during provisioning. It also applies consistent formatting improvements and minor refactors across the Bicep file for readability and maintainability.

Event Grid and Role Assignment Ordering Fix:

  • Refactored the Event Grid system-topic wiring in main.bicep so that the role assignment (eventGridQueueSenderRole) is created before the event subscription (newEventGridSubscription), breaking the chicken-and-egg problem that caused managed identity authorization failures on fresh azd up. The subscription is now a standalone resource that depends on the role assignment, matching the pattern used for existing topics. [1] [2]

Formatting and Readability Improvements:

Documentation Updates:

  • Added a detailed worklog entry (worklog/2026-06-23.md) documenting the fix, rationale, and next steps for verifying the Event Grid provisioning flow.
  • Updated the bug documentation in bugs.md to reflect the applied durable fix and lessons learned.

These changes ensure the infrastructure provisioning is reliable and idempotent, preventing manual intervention and improving maintainability.

Does this introduce a breaking change?

  • Yes
  • No

How to Test

  • Get the code
git clone [repo-address]
cd [repo-name]
git checkout [branch-name]
npm install
  • Test the code

What to Check

Verify that the following are valid

  • ...

Other Information

@Vamshi-Microsoft Vamshi-Microsoft changed the title Fix Event Grid MI issue fix: Event Grid MI issue Jun 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant