Skip to content

Commit 66d2eef

Browse files
committed
Add new cross-region recovery article
1 parent b8dbf31 commit 66d2eef

File tree

7 files changed

+101
-0
lines changed

7 files changed

+101
-0
lines changed
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
title: Azure Notification Hubs cross-region disaster recovery
3+
description: Learn about cross-region disaster recovery options in Azure Notification Hubs.
4+
author: sethmanheim
5+
ms.author: sethm
6+
ms.service: notification-hubs
7+
ms.topic: conceptual
8+
ms.date: 09/28/2022
9+
10+
---
11+
12+
# Cross-region disaster recovery (preview)
13+
14+
[Azure Notification Hubs](notification-hubs-push-notification-overview.md) provides an easy-to-use and scaled-out push engine that enables you to send notifications to any platform (iOS, Android, Windows, etc.) from any back-end (cloud or on-premises). This article describes the cross-region disaster recovery configuration options currently available.
15+
16+
Cross-region disaster recovery provides *metadata* disaster recovery coverage. This is supported in paired and flexible region recovery
17+
options. Each Azure region is paired with another region within the same geography. All Notification Hubs tiers support [Azure paired region](/azure/availability-zones/cross-region-replication-azure#azure-cross-region-replication-pairings-for-all-geographies)
18+
(where available) or a flexible recovery region option that enables you to choose from a list of supported regions.
19+
20+
## Enable cross region disaster recovery
21+
22+
Cross-region disaster recovery options can be modified at any time.
23+
24+
### Use existing namespace
25+
26+
Use the Azure portal to edit an existing namespace:
27+
28+
1. Sign in to the [Azure portal](https://portal.azure.com).
29+
30+
2. Select **All services** on the left menu.
31+
32+
3. Select **Notification Hub Namespaces** in the **Internet of Things** section.
33+
34+
4. On the **Notification Hub Namespaces** page, select the namespace for which you want to modify the disaster recovery settings.
35+
36+
5. On the **Notification Hub Namespace** page for your namespace, you can see the current disaster recovery setting in the **Essentials** section.
37+
38+
6. In the following example, paired recovery region is enabled. To modify your disaster recovery region selection, select the **(edit)** link next to the current selection.
39+
40+
:::image type="content" source="media/cross-region-recovery/cedr1.png" alt-text="Azure portal namespace":::
41+
42+
7. On the **Edit Disaster** recovery pop-up screen, you can change your selections. Save your changes.
43+
44+
:::image type="content" source="media/cross-region-recovery/cedr2.png" alt-text="Azure portal edit recovery":::
45+
46+
### Use new namespace
47+
48+
To create a new namespace with disaster recovery, follow these steps:
49+
50+
1. Sign in to the [Azure portal](https://portal.azure.com).
51+
52+
2. Select **All services** on the left menu.
53+
54+
3. Select **Notification Hubs** in the **Mobile** section.
55+
56+
4. Select the star icon next to the service name to add the service to the **FAVORITES** section on the left menu. After you add **Notification Hubs** to **FAVORITES**, select it on the left menu.
57+
58+
:::image type="content" source="media/cross-region-recovery/cedr3.png" alt-text="Azure portal favorites":::
59+
60+
5. On the **Notification Hubs** page, select **Create** on the toolbar.
61+
62+
:::image type="content" source="media/cross-region-recovery/cedr4.png" alt-text="Create notification hub":::
63+
64+
6. In the **Basics** tab on the **Notification Hub** page, perform the following steps:
65+
66+
1. In **Subscription**, select the name of the Azure subscription you want to use, and then select an existing resource group, or create a
67+
new one.
68+
1. Enter a unique name for the new namespace in **Namespace Details**.
69+
1. A namespace contains one or more notification hubs, so type a name for the hub in **Notification Hub Details**. Or, select an existing
70+
namespace from the drop-down.
71+
1. Select a value from the **Location** drop-down list box. This value specifies the location in which you want to create the hub.
72+
1. Choose your **Disaster recovery** option – None, Paired recovery region or Flexible recovery region. If you choose **Paired recovery region**, the failover region is displayed.
73+
74+
:::image type="content" source="media/cross-region-recovery/cedr5.png" alt-text="Notification hub properties":::
75+
76+
1. If you select **Flexible recovery region**, use the drop down to choose from a list of recovery regions.
77+
78+
:::image type="content" source="media/cross-region-recovery/cedr6.png" alt-text="Select region":::
79+
80+
1. Select **Create**.
81+
82+
### Add resiliency
83+
84+
Paired and flexible region recovery only backs up metadata. You must implement a solution to repopulate the registration data into your new
85+
hub post-recovery:
86+
87+
1. Create a secondary notification hub in a different datacenter. We recommend creating one from the beginning to shield you from a disaster recovery event that might affect your management capabilities. You can also create one at the time of the disaster recovery event.
88+
89+
2. Keep the secondary notification hub in sync with the primary notification hub using one of the following options:
90+
- Use an app backend that simultaneously creates and updates installations in both notification hubs. Installations allow you to specify your own unique device identifier, making it more suitable for the replication scenario. For more information, see this [sample code](https://github.com/Azure/azure-notificationhubs-dotnet/tree/main/Samples/RedundantHubSample).
91+
- Use an app backend that gets a regular dump of registrations from the primary notification hub as a backup. It can then perform a bulk insert into the secondary notification hub.
92+
93+
The secondary notification hub may end up with expired installations/registrations. When the push is made to an expired handle, Notification Hubs automatically cleans the associated installation/registration record based on the response received from the PNS server. To clean expired records from a secondary notification hub, add custom logic that processes feedback from each send. Then, expire installation/registration in the secondary notification hub.
94+
95+
If you don't have a backend, when the app starts on target devices, they perform a new registration in the secondary notification hub. Eventually the secondary notification hub will have all the active devices registered.
96+
97+
There will be a time period when devices with unopened apps won't receive notifications.
98+
99+
## Next steps
100+
101+
- [Azure Notification Hubs](notification-hubs-push-notification-overview.md)
30.8 KB
Loading
47.9 KB
Loading
31.5 KB
Loading
116 KB
Loading
63 KB
Loading
61.7 KB
Loading

0 commit comments

Comments
 (0)