Skip to content

Commit

Permalink
Add client connection info for Azure SignalR - Fixes #3390 (#3463)
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] authored Apr 8, 2024
1 parent 9a89cbf commit 6eb0480
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/Aspire.Hosting.Azure.SignalR/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,18 @@ var myService = builder.AddProject<Projects.MyService>()
.WithReference(signalR);
```

The `WithReference` method configures a connection in the `MyService` project named `sr`. In the _Program.cs_ file of `MyService`, the Azure SignalR connection can be consumed using the client library [Microsoft.Azure.SignalR](https://www.nuget.org/packages/Microsoft.Azure.SignalR):

```csharp
builder.Services.AddSignalR()
.AddNamedAzureSignalR("sr");
```

## Additional documentation

* https://github.com/dotnet/aspire/tree/main/src/Components/README.md
* https://learn.microsoft.com/dotnet/aspire/real-time/azure-signalr-scenario
* https://learn.microsoft.com/azure/azure-signalr/signalr-overview

## Feedback & contributing

Expand Down

0 comments on commit 6eb0480

Please sign in to comment.