Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds HubUtility to resolve hub names. #130

Merged
merged 2 commits into from
Jan 19, 2023

Conversation

JRWinter1
Copy link

Keeps HubContext name resolution consistent with OrleansHubLifetimeManager.

I understand this could be breaking to some consumers of the library. However, I thought Id' raise the PR to get the conversation going.

In my opinion, the OrleansHubLifetimeManager should not look for the typed client of the hub when resolving the hub name but maybe I am missing something.

I've also brought the HubContext in line with the actual implementation of hub context which will ensure consistency between the HubContext and OrleansHubLifetimeManager.

From MSDN:
public interface IHubContext<out THub> where THub : Hub
Ref:
https://docs.microsoft.com/en-us/dotnet/api/microsoft.aspnetcore.signalr.ihubcontext-1?view=aspnetcore-6.0

…n consistent with OrleansHubLifetimeManager.
@JRWinter1
Copy link
Author

It would be nice to support strongly typed HubContext too:

public interface IHubContext<THub,T> where THub : Hub<T> where T : class

But that is a separate piece of work and slightly more involved so I will try to pick up in the near future.

@galvesribeiro
Copy link
Member

Thanks @JRWinter1. Makes total sense. Since this is an internal thing, it should not be a breaking change as nobody should be relying on it. Nonetheless, I'll merge it as part of the v7.

Thanks!

@galvesribeiro galvesribeiro merged commit 9f3ec76 into OrleansContrib:master Jan 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants