Local Development with Azure Functions and Event Grid

Azure Function

For the past couple of days I have been working with Azure Functions and Event Grid. 

The challenge I encountered was getting it so I could run and debug my Azure Functions locally, specifically the Even Grid Azure Function.

Finally figured it out!

For my example I am using two Azure Functions, the first is a Http Trigger function and the second is an Event Grid Trigger function.

This function simply adds a User to a SQL Server database.

The class AzureKeyVaultSecretService, is just a help class that extracts Environment Variables from local.settings.json, when running locally, and Azure Key Vault, when running in production.

Download the Azure Grid Emulator at https://github.com/ravinsp/eventgrid-emulator. and then configure the emulator-config.json file for the Azure Grid Emulator.

Set local.settings.json configuration.

Run your Azure Function project and the Event Grid Emulator. From Postman I make a POST call to http://localhost:7071/api/users.

Output from Azure Grid Emulator looks good! That’s it!

Related Articles


Discover more from Matt Ruma

Subscribe to get the latest posts sent to your email.

1 Reply to “Local Development with Azure Functions and Event Grid”

Leave a Reply

Your email address will not be published. Required fields are marked *