-
Notifications
You must be signed in to change notification settings - Fork 172
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
[Relay] Regenerate socket URL on error disconnection #769
Conversation
try socketConnectionHandler?.handleDisconnect(closeCode: closeCode) | ||
} | ||
|
||
private func setUpSocketConnection() { |
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.
is this function called by anyone?
host: relayHost, | ||
projectId: projectId |
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.
could we maybe add host and projectId to the url factory init? they wan't change anyway
let dispatcher = Dispatcher( | ||
relayHost: relayHost, | ||
projectId: projectId, | ||
clientIdStorage: clientIdStorage, |
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.
would adding RelayClientFactory, like we have for other clients solve the init problem for Dispatcher and RelayClient?
var socket: WebSocketConnecting | ||
var socketConnectionHandler: SocketConnectionHandler | ||
|
||
var socket: WebSocketConnecting? |
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.
does it have to be optional?
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.
if tested manually and works then looks good to me
lgtm, I think it's better to recreate websocket instance |
Due Dilligence