You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/azure-signalr/signalr-concept-disaster-recovery.md
+85-8Lines changed: 85 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,6 +8,7 @@ ms.devlang: csharp
8
8
ms.custom: devx-track-csharp
9
9
ms.date: 03/01/2019
10
10
ms.author: lianwei
11
+
zone_pivot_groups: azure-signalr-service-mode
11
12
---
12
13
# Resiliency and disaster recovery in Azure SignalR Service
13
14
@@ -48,10 +49,9 @@ Multiple SignalR service instances are supported on both app servers and Azure F
48
49
49
50
Once you have SignalR service and app servers/Azure Functions created in each region, you can configure your app servers/Azure Functions to connect to all SignalR service instances.
50
51
51
-
### Configure on app servers
52
-
There are two ways you can do it:
52
+
:::zone pivot="default-mode"
53
53
54
-
####Through config
54
+
### Through config
55
55
56
56
You should already know how to set SignalR service connection string through environment variables/app settings/web.cofig, in a config entry named `Azure:SignalR:ConnectionString`.
57
57
If you have multiple endpoints, you can set them in multiple config entries, each in the following format:
In the ConnectionString, `<name>` is the name of the endpoint and `<role>` is its role (primary or secondary).
64
64
Name is optional but it's useful if you want to further customize the routing behavior among multiple endpoints.
65
65
66
-
####Through code
66
+
### Through code
67
67
68
68
If you prefer to store the connection strings somewhere else, you can also read them in your code and use them as parameters when calling `AddAzureSignalR()` (in ASP.NET Core) or `MapAzureSignalR()` (in ASP.NET).
69
69
@@ -94,9 +94,86 @@ You can configure multiple primary or secondary instances. If there are multiple
Weusea [`ServiceEndpoint`](https://github.com/Azure/azure-signalr/blob/dev/src/Microsoft.Azure.SignalR.Common/Endpoints/ServiceEndpoint.cs) object to represent a SignalR Service instance. You can define an service endpoint with its `<EndpointName>` and `<EndpointType>` in the entry key, and the connection string in the entry value. The keys are in the following format :
>*WhenyouconfigureAzureSignalRendpointsintheAppServiceonAzureportal, don't forget to replace `":"` with `"__"`, the double underscore in the keys. For reasons, see [Environment variables](https://docs.microsoft.com/en-us/aspnet/core/fundamentals/configuration/?view=aspnetcore-5.0#environment-variables).
0 commit comments