Skip to content

Demo scripts to setup and play with Azure messaging services

Notifications You must be signed in to change notification settings

romaklimenko/azure-messaging-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Azure Messaging Demo

This repository contains a demo of Azure messaging services.

  • /bicep - contains Bicep templates to deploy Azure resources.
  • /python - contains Python scripts to interact with Azure messaging services.

How to use

The following steps assume you run the repository in GitHub Codespaces or devcontainer.

First, open the repository in a GitHub Codespace by clicking the button below:

Open in GitHub Codespaces

Or, clone the repository and open it in a devcontainer.

Next, deploy the Azure resources:

make deploy

You will be prompted to login to your Azure account and select a subscription.

NB: The script creates a new resource group called messaging in westeurope and deploys all resources to it. If you want to deploy resources to a different location or resource group, modify the resource-group.parameters.json accordingly.

After the deployment is complete, run the Python scripts directly or using the Makefile:

Azure Storage Queue

make sa_pub # Publish messages to the queue
make sa_sub # Receive messages

Azure Service Bus

make sb_pub # Publish messages to the topic
make sb_sub1 # Receive messages from the subscription1
make sb_sub2 # Receive messages from the subscription1

Azure Event Hubs

make eh_pub # Publish messages to the event hub
make eh_sub # Receive messages

Azure Event Grid

make eg_pub # Publish events to the event grid
make eg_sub # Receive events

Clean up

To delete all Azure resources, run:

make undeploy