-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Closed
Labels
Needs: DesignThis issue requires design work before implementating.This issue requires design work before implementating.area-signalrIncludes: SignalR clients and serversIncludes: SignalR clients and servers
Milestone
Description
There's a pattern where you're sending data that's already serialized from another system (like a message bus) to the clients without first de-serializing and re-serializing. Here's an example:
The above code gets a utf8 JSON encoded message from the queue, turns it into a string, then turns that string into a UserAchievement<string>
object. Then it calls IHubContext.User(...).SendAsync which turns that object back into a utf8 byte[] payload to send on the wire.
We should introduce a new type that encodes this information that IHubProtocols have native support for. Some considerations:
- If connected clients are various protocols, what do we do? Do we store type information so that we can de-serialize in the original format and re-serialize in the correct format?
Metadata
Metadata
Assignees
Labels
Needs: DesignThis issue requires design work before implementating.This issue requires design work before implementating.area-signalrIncludes: SignalR clients and serversIncludes: SignalR clients and servers