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
+13-13Lines changed: 13 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,34 +11,34 @@ ms.author: lianwei
11
11
---
12
12
# Resiliency and disaster recovery in Azure SignalR Service
13
13
14
-
Resiliency and disaster recovery is a common need for online systems. Azure SignalR Service already guarantees 99.9% availability, but it's still a regional service.
15
-
Your service instance is always running in one region and doesn't fail over to another region when there's a region-wide outage.
14
+
Resiliency and disaster recovery is a common need for online systems. Azure SignalR Service already provides 99.9% availability, however it's still a regional service.
15
+
When there's a region-wide outage, your service instance doesn't fail over to another region because it's always running in the one region.
16
16
17
17
For regional disaster recovery, we recommend the following two approaches:
18
18
19
-
-**Enable Geo-Replication** (Easy way). This feature will handle regional failover for you automatically. When enabled, there remains just one Azure SignalR instance and no code changes are introduced. Check [geo-replication](howto-enable-geo-replication.md) for details.
20
-
-**Utilize Multiple Endpoints in Service SDK**. Our service SDK provides a functionality to support multiple SignalR service instances and automatically switch to other instances when some of them aren't available. With this feature, you're able to recover when a disaster takes place, but you need to set up the right system topology by yourself. You learn how to do so **in this document**.
19
+
-**Enable Geo-Replication** (Easy way). This feature handles regional failover for you automatically. When enabled, there's only one Azure SignalR instance and no code changes are introduced. Check [geo-replication](howto-enable-geo-replication.md) for details.
20
+
-**Utilize Multiple Endpoints in Service SDK**. Our service SDK supports multiple SignalR service instances and automatically switches to other instances when some of them are unavailable. With this feature, you're able to recover when a disaster takes place, but you need to set up the right system topology by yourself. You learn how to do so **in this document**.
21
21
22
22
23
23
## High available architecture for SignalR service
24
24
25
-
In order to have cross region resiliency for SignalR service, you need to set up multiple service instances in different regions. So when one region is down, the others can be used as backup.
25
+
To ensure cross region resiliency for SignalR service, you need to set up multiple service instances in different regions. So when one region is down, the others can be used as backup.
26
26
When app servers connect to multiple service instances, there are two roles, primary and secondary.
27
-
Primary is an instance who is taking online traffic and secondary is a fully functional but backup instance for primary.
28
-
In our SDK implementation, negotiate only returns primary endpoints so in normal case clients only connect to primary endpoints.
27
+
Primary is an instance responsible for receiving online traffic, while secondary serves as a fallback instance that is fully functional.
28
+
In our SDK implementation, negotiate only returns primary endpoints, so clients only connect to primary endpoints in normal cases.
29
29
But when primary instance is down, negotiate returns secondary endpoints so client can still make connections.
30
30
Primary instance and app server are connected through normal server connections but secondary instance and app server are connected through a special type of connection called weak connection.
31
-
The main difference of a weak connection is that it doesn't accept client connection routing, because secondary instance is located in another region. Routing a client to another region isn't an optimal choice (increases latency).
31
+
One distinguishing characteristic of a weak connection is that it's unable to accept client connection routing due to the location of secondary instance in another region. Routing a client to another region isn't an optimal choice (increases latency).
32
32
33
33
One service instance can have different roles when connecting to multiple app servers.
34
-
One typical setup for cross region scenario is to have two (or more) pairs of SignalR service instances and app servers.
34
+
One typical setup for cross region scenario is to have two or more pairs of SignalR service instances and app servers.
35
35
Inside each pair app server and SignalR service are located in the same region, and SignalR service is connected to the app server as a primary role.
36
36
Between each pairs app server and SignalR service are also connected, but SignalR becomes a secondary when connecting to server in another region.
37
37
38
38
With this topology, message from one server can still be delivered to all clients as all app servers and SignalR service instances are interconnected.
39
-
But when a client is connected, it's always routed to the app server in the same region to achieve optimal network latency.
39
+
But when a client is connected, it routes to the app server in the same region to achieve optimal network latency.
40
40
41
-
Below is a diagram that illustrates such topology:
41
+
The following diagram illustrates such topology:
42
42
43
43

44
44
@@ -60,7 +60,7 @@ If you have multiple endpoints, you can set them in multiple config entries, eac
60
60
Azure:SignalR:ConnectionString:<name>:<role>
61
61
```
62
62
63
-
Here`<name>` is the name of the endpoint and `<role>` is its role (primary or secondary).
63
+
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
66
#### Through code
@@ -147,7 +147,7 @@ Follow the steps to trigger the failover:
Copy file name to clipboardExpand all lines: articles/azure-signalr/signalr-concept-event-grid-integration.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
title: React to Azure SignalR Service events
3
-
description: Use Azure Event Grid to subscribe to Azure SignalR Service events. Other downstream services can be triggered by these events.
3
+
description: Use Azure Event Grid to subscribe to Azure SignalR Service events. These events can also trigger other downstream services.
4
4
services: azure-signalr,event-grid
5
5
author: vicancy
6
6
ms.author: lianwei
@@ -14,25 +14,25 @@ ms.service: signalr
14
14
15
15
Azure SignalR Service events allow applications to react to client connections connected or disconnected using modern serverless architectures. It does so without the need for complicated code or expensive and inefficient polling services. Instead, events are pushed through [Azure Event Grid](https://azure.microsoft.com/services/event-grid/) to subscribers such as [Azure Functions](https://azure.microsoft.com/services/functions/), [Azure Logic Apps](https://azure.microsoft.com/services/logic-apps/), or even to your own custom http listener. With Azure SignalR, you only pay for what you consume.
16
16
17
-
Azure SignalR Service events are reliably sent to the Event Grid service which provides reliable delivery services to your applications through rich retry policies and dead-letter delivery. To learn more, see [Event Grid message delivery and retry](../event-grid/delivery-and-retry.md).
17
+
Azure SignalR Service events are reliably sent to the Event Grid service that provides reliable delivery services to your applications through rich retry policies and dead-letter delivery. To learn more, see [Event Grid message delivery and retry](../event-grid/delivery-and-retry.md).
Azure SignalR Service events are only active when client connections are in a serverless state. If a client does not route to a hub server, it goes into the serverless state. Classic mode only works when the hub that client connections connect to doesn't have a hub server. Serverless mode is recommended as a best practice. To learn more details about service mode, see [How to choose Service Mode](https://github.com/Azure/azure-signalr/blob/dev/docs/faq.md#what-is-the-meaning-of-service-mode-defaultserverlessclassic-how-can-i-choose).
22
+
Azure SignalR Service events are only active when client connections are in a serverless state. If a client doesn't route to a hub server, it goes into the serverless state. Classic mode only works when the hub that client connections connect to doesn't have a hub server. Serverless mode is recommended as a best practice. To learn more details about service mode, see [How to choose Service Mode](https://github.com/Azure/azure-signalr/blob/dev/docs/faq.md#what-is-the-meaning-of-service-mode-defaultserverlessclassic-how-can-i-choose).
23
23
24
24
## Available Azure SignalR Service events
25
-
Event grid uses [event subscriptions](../event-grid/concepts.md#event-subscriptions) to route event messages to subscribers. Azure SignalR Service event subscriptions support two types of events:
25
+
Event Grid uses [event subscriptions](../event-grid/concepts.md#event-subscriptions) to route event messages to subscribers. Azure SignalR Service event subscriptions support two types of events:
26
26
27
27
|Event Name|Description|
28
28
|----------|-----------|
29
29
|`Microsoft.SignalRService.ClientConnectionConnected`|Raised when a client connection is connected.|
30
30
|`Microsoft.SignalRService.ClientConnectionDisconnected`|Raised when a client connection is disconnected.|
31
31
32
32
## Event schema
33
-
Azure SignalR Service events contain all the information you need to respond to the changes in your data. You can identify an Azure SignalR Service event with the eventType property starts with "Microsoft.SignalRService". Additional information about the usage of Event Grid event properties is documented at [Event Grid event schema](../event-grid/event-schema.md).
33
+
Azure SignalR Service events contain all the information you need to respond to the changes in your data. You can identify an Azure SignalR Service event with the eventType property starts with **Microsoft.SignalRService**. Additional information about the usage of Event Grid event properties is documented at [Event Grid event schema](../event-grid/event-schema.md).
34
34
35
-
Here is an example of a client connection connected event:
35
+
Here's an example of a client connection connected event:
Copy file name to clipboardExpand all lines: articles/azure-signalr/signalr-concept-scale-aspnet-core.md
+11-4Lines changed: 11 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,11 +13,18 @@ ms.author: lianwei
13
13
14
14
## Developing SignalR apps
15
15
16
-
Currently, there are [two versions](/aspnet/core/signalr/version-differences) of SignalR you can use with your web applications: ASP.NET SignalR, and the new ASP.NET Core SignalR. ASP.NET Core SignalR is a rewrite of the previous version. As a result, ASP.NET Core SignalR isn't backward compatible with the earlier SignalR version. The APIs and behaviors are different. The Azure SignalR Service supports both versions.
16
+
SignalR is currently available in [two versions](/aspnet/core/signalr/version-differences) for use with web applications:
17
+
- ASP.NET SignalR
18
+
- new ASP.NET Core SignalR
17
19
18
-
With Azure SignalR Service, you have the ability to run your actual web application on multiple platforms (Windows, Linux, and macOS) while hosting with [Azure App Service](../app-service/overview.md), [IIS](/aspnet/core/host-and-deploy/iis/index), [Nginx](/aspnet/core/host-and-deploy/linux-nginx), [Apache](/aspnet/core/host-and-deploy/linux-apache), [Docker](/aspnet/core/host-and-deploy/docker/index). You can also use self-hosting in your own process.
20
+
ASP.NET Core SignalR is a rewrite of the previous version. As a result, ASP.NET Core SignalR isn't backward compatible with the earlier SignalR version. The APIs and behaviors are different. The Azure SignalR Service supports both versions.
19
21
20
-
If the goals for your application include: supporting the latest functionality for updating web clients with real-time content updates, running across multiple platforms (Azure, Windows, Linux, and macOS), and hosting in different environments, then the best choice could be using the Azure SignalR Service.
22
+
Azure SignalR Service lets you host your actual web application on multiple platforms (Windows, Linux, and macOS) [Azure App Service](../app-service/overview.md), [IIS](/aspnet/core/host-and-deploy/iis/index), [Nginx](/aspnet/core/host-and-deploy/linux-nginx), [Apache](/aspnet/core/host-and-deploy/linux-apache), [Docker](/aspnet/core/host-and-deploy/docker/index). You can also use self-hosting in your own process.
23
+
24
+
Azure SignalR Service is the best choice if the goals for your application include:
25
+
- supporting the latest functionality for updating web clients with real-time content updates,
26
+
- running across multiple platforms (Azure, Windows, Linux, and macOS)
27
+
- hosting in different environments
21
28
22
29
## Why not deploy SignalR myself?
23
30
@@ -27,7 +34,7 @@ One of the key reasons to use the Azure SignalR Service is simplicity. With Azur
27
34
28
35
Also, WebSockets are typically the preferred technique to support real-time content updates. However, load balancing a large number of persistent WebSocket connections becomes a complicated problem to solve as you scale. Common solutions use: DNS load balancing, hardware load balancers, and software load balancing. Azure SignalR Service handles this problem for you.
29
36
30
-
For ASP.NET Core SignalR, another reason might be you have no requirements to actually host a web application at all. The logic of your web application might use [Serverless computing](https://azure.microsoft.com/overview/serverless-computing/). For example, maybe your code is only hosted and executed on demand with [Azure Functions](../azure-functions/index.yml) triggers. This scenario can be tricky because your code only runs on-demand and doesn't maintain long connections with clients. Azure SignalR Service can handle this situation since the service already manages connections for you. For more information, see [overview on how to use SignalR Service with Azure Functions](signalr-concept-azure-functions.md). Since ASP.NET SignalR uses a different protocol, such Serverless mode isn't supported for ASP.NET SignalR.
37
+
For ASP.NET Core SignalR, another reason might be you have no requirements to actually host a web application at all. The logic of your web application might use [Serverless computing](https://azure.microsoft.com/overview/serverless-computing/). For example, maybe your code is only hosted and executed on demand with [Azure Functions](../azure-functions/index.yml) triggers. This scenario can be challenging because your code only runs on-demand and doesn't maintain long connections with clients. Azure SignalR Service can handle this situation since the service already manages connections for you. For more information, see [overview on how to use SignalR Service with Azure Functions](signalr-concept-azure-functions.md). Since ASP.NET SignalR uses a different protocol, such Serverless mode isn't supported for ASP.NET SignalR.
0 commit comments