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-howto-use.md
+18-15Lines changed: 18 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,15 +10,18 @@ ms.author: lianwei
10
10
11
11
# Use Azure SignalR Service
12
12
13
+
14
+
This article shows you how to use SDK in your app server side to connect to SignalR Service when you are using SignalR in your app server.
15
+
13
16
## Create an Azure SignalR Service instance
14
17
15
18
Follow [Quickstart: Use an ARM template to deploy Azure SignalR](./signalr-quickstart-azure-signalr-service-arm-template.md) to create a SignalR service instance.
16
19
17
-
## For ASP.NET Core SignalR
20
+
## For ASP.NET Core SignalR
18
21
19
-
### 1. Install the SDK
22
+
### Install the SDK
20
23
21
-
Run the command to install SignalR Service SDK to your ASP.NET Core project.
24
+
Run the command to install SignalR Service SDK to your ASP.NET Core project.
22
25
23
26
```bash
24
27
dotnet add package Microsoft.Azure.SignalR
@@ -42,7 +45,7 @@ public void Configure(IApplicationBuilder app)
42
45
}
43
46
```
44
47
45
-
### 2. Configure Connection String
48
+
### Configure connection string
46
49
47
50
There are two approaches to configure SignalR Service's connection string in your application.
48
51
@@ -62,7 +65,7 @@ There are two approaches to configure SignalR Service's connection string in you
62
65
.AddAzureSignalR(options=>options.ConnectionString="<replace with your connection string>");
63
66
```
64
67
65
-
### 3. Configure options
68
+
### Configure options
66
69
67
70
Thereareafew [options](https://github.com/Azure/azure-signalr/blob/dev/src/Microsoft.Azure.SignalR/ServiceOptions.cs) you can customize when using Azure SignalR Service SDK.
68
71
@@ -106,7 +109,7 @@ You can increase this value to avoid client disconnect.
106
109
#### `AccessTokenAlgorithm`
107
110
108
111
-Defaultvalueis `HS256`
109
-
- Thisoptionprovideschoiceof [`SecurityAlgorithms`](https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/blob/dev/src/Microsoft.IdentityModel.Tokens/SecurityAlgorithms.cs) when generate access token. Now supported optional values are `HS256` and `HS512`. Note `HS512` is more secure but the generated token is comparatively longer than that using `HS256`.
112
+
- Thisoptionprovideschoiceof [`SecurityAlgorithms`](https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/blob/dev/src/Microsoft.IdentityModel.Tokens/SecurityAlgorithms.cs) when generate access token. Now supported optional values are `HS256` and `HS512`. Note that `HS512` is more secure but the generated token is comparatively longer than that using `HS256`.
110
113
111
114
#### `ServerStickyMode`
112
115
@@ -145,7 +148,7 @@ You can increase this value to avoid client disconnect.
@@ -198,7 +201,7 @@ Set the connection string in the `web.config` file, to the `connectionStrings` s
198
201
</configuration>
199
202
```
200
203
201
-
### 3. Configure options
204
+
### Configure options
202
205
203
206
Thereareafew [options](https://github.com/Azure/azure-signalr/blob/dev/src/Microsoft.Azure.SignalR.AspNet/ServiceOptions.cs) you can customize when using Azure SignalR Service SDK.
204
207
@@ -241,7 +244,7 @@ You can increase this value to avoid client disconnect.
241
244
#### `AccessTokenAlgorithm`
242
245
243
246
-Defaultvalueis `HS256`
244
-
- Thisoptionprovideschoiceof [`SecurityAlgorithms`](https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/blob/dev/src/Microsoft.IdentityModel.Tokens/SecurityAlgorithms.cs) when generate access token. Now supported optional values are `HS256` and `HS512`. Note `HS512` is more secure but the generated token is comparatively longer than that using `HS256`.
247
+
- Thisoptionprovideschoiceof [`SecurityAlgorithms`](https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/blob/dev/src/Microsoft.IdentityModel.Tokens/SecurityAlgorithms.cs) when generate access token. Now supported optional values are `HS256` and `HS512`. Note that `HS512` is more secure but the generated token is comparatively longer than that using `HS256`.
245
248
246
249
#### `ServerStickyMode`
247
250
@@ -271,7 +274,7 @@ app.Map("/signalr",subApp => subApp.RunAzureSignalR(this.GetType().FullName, new
0 commit comments