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

feat(hub connection): throttle reconnect on disconnect #70

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

joseph118
Copy link

No description provided.

@joseph118 joseph118 marked this pull request as ready for review January 22, 2025 11:35
@joseph118 joseph118 requested a review from a team as a code owner January 22, 2025 11:35
@@ -288,4 +283,41 @@ export class HubConnection<THub> {
return data;
}

private getReconnectOnDisconnect$(): Observable<void> {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
private getReconnectOnDisconnect$(): Observable<void> {
private reconnectOnDisconnect$(): Observable<void> {

@@ -288,4 +283,41 @@ export class HubConnection<THub> {
return data;
}

private getReconnectOnDisconnect$(): Observable<void> {
let retryCount = 0;
const timer$ = (): Observable<void> => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor but would rename

Suggested change
const timer$ = (): Observable<void> => {
const delay$ = (): Observable<void> => {

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.

2 participants