SignalR How is a duplicate Connection Id handled?

后端 未结 3 1595
执念已碎
执念已碎 2021-01-19 05:46

I have created my own IConnectionIdGenerator implementation which for simpicty in my webforms application names the client connection Id by the EmailAddress.ToL

3条回答
  •  感动是毒
    2021-01-19 06:01

    Yes thats perfect, I came to a simlar conclusion.

    I also trying to think of a way to make client broadcast messages to the same email address group unique to the current url (so a progress bar on one page does not also update a progress bar on another)

    I will either make extend the group id to be something like emailAddress + currentURL so its just a combination of the two strings. However that would make any global site broadcasts (to all urls) difficult to do unless there is a way of getting the groups collection and parsing out the email addresses and sending the message to each email address + url combination.

    It may be better if I just tag on some client side check and send a progress bar Id as a parameter that is unique to the progress bar on the page that is ment to be updated.

提交回复
热议问题