Skip to content

Application crashes on loss of internet connectivity when starting a WebSocket connection #75

@rahatur

Description

@rahatur

If internet connectivity is lost (even for couple of seconds) during a SignalR hub connection then a RuntimeException is thrown. Which causes the entire application to crash. Instead can we throw some sort of network exception?

Sample existing code:

if (this.state.hubConnectionState != HubConnectionState.CONNECTING) {
    return Completable.error(new RuntimeException("Connection closed while trying to connect."));
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions