-
Notifications
You must be signed in to change notification settings - Fork 7
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
New type: subscription #121
Comments
Thanks for this submission. We'll use to help prioritize this work with the Graph subscription API owners. I can see why, with Bicep, there would be one place where you could configure both the Graph events subscription and Azure Event Grid. Since Graph events subscriptions need regular "renewing", would you be looking to redeploy the Bicep file each time the Graph event subscription needs renewing (just with a different |
Hi @dkershaw10 When the subscription is created with a It's expected that Event Grid Event Subscription (event handler) is created for |
Sorry I'm coming back to this late @MartinM85 - so this request is just to support Bicep for the initial subscription creation? I'm asking because typically folks redeploy Bicep template files on a regular basis - the subscription resource declaration in the Bicep file should represent what is deployed in infrastructure. However, for this resource, Are you sure this is still appropriate for your needs via Bicep? If so, I will put the ask in with the resource owner team. |
@dkershaw10 said:
agreed 👆... but not with this 👇...
Bicep (and ARM) doesn't represent what is deployed in infrastructure, rather it expresses what the desired state should be in infrastructure. IOW, it represents the desired state config (DSC). For instance, a Bicep file that represents an Azure Function app should be - the DSC. The first time I run it, I expect it will create the missing resource. If I modify the Bicep file to add/remove environment variable settings, I expect Azure deployment to update the existing resource that's defined... and Azure deployment does exactly that. So for a subscription, I expect I should be able to define it and it's created. If during my deployment, I include a GUID (for an existing subscription) and a new expiry date, the execution of that template will update the existing subscription with the new expiry. EDIT: maybe I'm misunderstanding the conversation as I reread your reply and the message you were responding to. Maybe I'm saying what you're saying, just in a different way? |
I agree with this behavior. |
Sorry - yes - the declarative file represents the desired state configuration for the infra - my bad. |
Suggestion
I would suggest to add subscription type.
Value
When using Azure Event Grid, I can subscribe to Microsoft Graph API events.
To create a Partner Topic, I need to create a Graph API subscription. the
notificationUrl
property specifies Partner Topic name, resource group name in which the partner topic is created, region (location) and Azure subscription.To be able to create a subscription and de facto Partner Topic via Bicep file, will simplify the configuration of Azure Event Grid. Once Partner Topic is created, I can continue with creating event subscriptions for Partner Topic.
Microsoft Graph API REST reference
https://learn.microsoft.com/en-us/graph/api/resources/subscription?view=graph-rest-1.0
https://learn.microsoft.com/en-us/azure/event-grid/subscribe-to-graph-api-events?tabs=http
The text was updated successfully, but these errors were encountered: