-
Notifications
You must be signed in to change notification settings - Fork 103
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
fix auto reconnect after stop bug #707
Conversation
747af20
to
289dfd6
Compare
src/Microsoft.Azure.SignalR.Common/ServiceConnections/ServiceConnectionBase.cs
Outdated
Show resolved
Hide resolved
af9fd4b
to
3b85319
Compare
src/Microsoft.Azure.SignalR.Common/ServiceConnections/ServiceConnectionContainerBase.cs
Outdated
Show resolved
Hide resolved
src/Microsoft.Azure.SignalR.Common/ServiceConnections/WeakServiceConnectionContainer.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.SignalR.E2ETests/Management/ServiceHubContextE2EFacts.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.SignalR.E2ETests/Management/ServiceHubContextE2EFacts.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.Azure.SignalR.E2ETests/Management/ServiceHubContextE2EFacts.cs
Show resolved
Hide resolved
private readonly ServiceProvider _serviceProvider; | ||
|
||
// for test only | ||
internal IServiceConnectionContainer ConnectionContainer { get; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why we don't move this property into its relevant TestServiceHubContext
class?
And even if we have to define an internal
property here, we can use
get => _serviceProvider.GetService<IServiceConnectionContainer>()
instead of initializing it in the constructor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
init in .ctor is better as it is only set once
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we create a inner class and make all metheds and fields only placed in this inner class? this makes the outer class clean.
No description provided.