Commit e090a5aa authored by Leonardo Aramaki's avatar Leonardo Aramaki

Removed the delay to connect. Connections attempts is now handled by exponential backoff retries

parent 86b727d8
...@@ -62,14 +62,20 @@ public class RxWebSocket { ...@@ -62,14 +62,20 @@ public class RxWebSocket {
} }
}), }),
BackpressureStrategy.BUFFER BackpressureStrategy.BUFFER
).delay(4, TimeUnit.SECONDS).publish(); ).publish();
} }
public boolean sendText(String message) throws IOException { public boolean sendText(String message) throws IOException {
if (webSocket == null) {
return false;
}
return webSocket.send(message); return webSocket.send(message);
} }
public boolean close(int code, String reason) throws IOException { public boolean close(int code, String reason) throws IOException {
if (webSocket == null) {
return false;
}
return webSocket.close(code, reason); return webSocket.close(code, reason);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment