Skip to content

[DEV-6821]fix(gotd/session.go): start gotd Client run in sepperate - #169

Open
suifri wants to merge 1 commit into
mainfrom
fix/DEV-6821-gotd-client-inifinity-reconnect-loop
Open

[DEV-6821]fix(gotd/session.go): start gotd Client run in sepperate#169
suifri wants to merge 1 commit into
mainfrom
fix/DEV-6821-gotd-client-inifinity-reconnect-loop

Conversation

@suifri

@suifri suifri commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

coroutine

Firs of all gotd client require internet connection to open WS conect to Telegram servers. As client that reported of this case use firewall configuration that blocked this connection - service didn`t start properely, cause gotd client use infinity reconnect mechanism and block service initialization and registration in service discovery provider. To handle this I decided to open new coroutine and initialized gotd client in this routine.
See: https://github.com/gotd/contrib/blob/master/bg/connect.go#L95

What changed:

  • add creation of new coroutine in init of gotd cient session
  • add context and channel handling in gotd init coroutine

coroutine

Firs of all gotd client require internet connection to open WS conect to
Telegram servers. As client that reported of this case use firewall
configuration that blocked this connection - service didn`t start
properely, cause gotd client use infinity reconnect mechanism and block
service initialization and registration in service discovery provider.
To handle this I decided to open new coroutine and initialized gotd
client in this routine.
See: https://github.com/gotd/contrib/blob/master/bg/connect.go#L95

What changed:
- add creation of new coroutine in init of gotd cient session
- add context and channel handling in gotd init coroutine
@suifri
suifri requested a review from kirychukyurii July 20, 2026 07:59
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.

1 participant