dotnet / dotnet/aspnetcore

Deduplicate SignalR group messages across connections

Open
#61,809 2 comments 0 reactions 0 assignees View on GitHub
area-signalr
Dominant language
C#
Stars
38.4k
Forks
10.9k
Avg merge
2d 10h
Merged PRs (30d)
281

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Is your feature request related to a problem? Please describe the problem.

When a SignalR connection is part of multiple groups, the connection will receive a message destined for the N-groups the connection is a part of also N-times. This leads to unnecessary overhead on the server, the network connection, and the client processing the messages.

### Describe the solution you'd like

A common solution for this problem is to deduplicate on the client. This however does not take away the unnecessary network traffic, and requires client side processing.

Both `DefaultHubLifetimeManager` and `RedisHubLifetimeManager` know which connections belong to a group. Hence filtering can be done easily server side.

### Additional context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.