The Simplest Way to Make Azure Service Bus and Zerto Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

You pair azure service bus and zerto to route disaster recovery events into cloud queues. This workflow lets your team automate failover alerts and track replication health across sites. Zerto protects virtual machines and cloud workloads through continuous replication. Azure Service Bus moves messages between apps and services with high reliability. When you link them, backup alerts and failover tasks flow straight to your response tools. Your apps can read these messages and run recovery scri

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

You pair azure service bus and zerto to route disaster recovery events into cloud queues. This workflow lets your team automate failover alerts and track replication health across sites.

Zerto protects virtual machines and cloud workloads through continuous replication. Azure Service Bus moves messages between apps and services with high reliability. When you link them, backup alerts and failover tasks flow straight to your response tools. Your apps can read these messages and run recovery scripts right away.

How permissions and data flow in azure service bus and zerto

Data flows from Zerto management servers into Azure message queues or topics. Zerto watches your workloads and creates alerts when replication lags or a failover starts. A middle worker app or webhook listener catches these alerts from Zerto. That worker then formats the event and sends it to a Service Bus queue.

Good security starts with how each side logs in. The worker app needs a role that can read alerts from the Zerto API. You should create a dedicated user role in Zerto with read-only permissions for alerts. Do not give this account full admin rights to trigger failovers on its own.

On the cloud side, the worker needs permission to send messages to the queue. Use cloud role assignments instead of shared root keys whenever you can. Give the sender role only the right to write to one specific queue. Downstream apps that process the alerts only need the right to read from that queue. This split keeps your message pipeline safe if one app gets compromised.

Common failure modes and how to scope roles and networks

Many teams make the mistake of using shared service accounts with broad access. When one shared key leaks, an attacker can read every message or delete queues. Broad tokens also make it hard to see who ran an action during an outage. Unlogged API calls leave your team guessing when a failover test goes wrong.

To fix this, give every worker and script its own identity and role. Scope each role to the exact queue or topic it needs to touch. Rotate keys on a set schedule and remove old accounts right after a test ends. Keep an audit log of every login and every message change in your cloud setup.

Service-to-Service Authentication + Azure RBAC: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Network paths between your recovery site and the cloud also need tight rules. Do not expose your Zerto management server to the public web. Run the alert forwarder inside the same private network as your Zerto server. Allow outbound traffic from that worker only to the specific Service Bus endpoint. Use private endpoints in the cloud so message traffic stays off the public internet.

Keeping sensitive event data safe in your queues

Disaster recovery alerts often hold sensitive details about your servers and users. An alert payload might include admin emails, phone numbers, or internal host details. If you store raw payloads in a queue, many downstream tools will read them.

You should strip or mask private fields before you process or log the messages. Data masking rewrites matched fields like emails and phone numbers in results. This step keeps private contact info out of general chat channels and ticket logs. Your team still gets the alert context they need to fix the replication issue.

Testing your disaster recovery message pipeline

A message pipeline is only useful if it works during a real outage. Test the link between your recovery tool and your queues every month. Run a non-disruptive failover test in Zerto to generate real event traffic. Check that your worker picks up the event and writes it to the queue.

Watch your dead-letter queues during these tests to catch bad message formats. If a message fails to process, fix the schema rules in your worker app. Check your logs to confirm that every step used the right scoped role. Regular testing builds trust so your team can act fast when an outage hits.

Govern statements and responses across databases and APIs

Good config and scoped roles are needed setup. They do not check single queries in flight or mask sensitive fields in returned rows. Across Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, and internal HTTP endpoints, hoop.dev runs beside each supported service as an open-source proxy, a sidecar for your database or API.

First, hoop.dev guardrails block banned queries before they run. Then hoop.dev data masking rewrites matched sensitive values in responses in memory. The audit trail records every statement and verdict per resource. Furthermore, hoop.dev holds SOC 2 Type II and is open source on GitHub.

Frequently asked questions

How does Zerto send alerts to Azure Service Bus?

Zerto sends event data to a webhook listener or a small script you run. That script formats the payload and writes it into your Service Bus queue.

What permissions should the message sender have?

Give the sender only the send role on the single queue it uses. Never use the root manage key for daily message traffic between your apps.

How do we handle failed alert messages in the queue?

Turn on dead-letter queues in your Service Bus setup to catch failed deliveries. Set up an alert on the dead-letter queue so your team can fix broken messages.

The query runs. The emails stay hidden.