title: Can't connect to ws using Tinder Scarlet
body: <p>Trying to test connection to my ws, but server does not see any connection.
  I think i miss something, could u tell me what did i miss?</p>
  
  <p>Logs:</p>
  
  <p>D/Connection$connect: Should Connect</p>
  
  <p>D/Connection$connect: WaitingToRetry</p>
  
  <p>D/Connection$connect: On WebSocket Connection Failed</p>
  
  <p>D/Connection$connect: Should Connect</p>
  
  <p>D/Connection$connect: WaitingToRetry</p>
  
  <p>D/Connection$connect: On WebSocket Connection Failed</p>
  
  <p>There is my code:</p>
  
  <p>In MainActivity</p>
  
  <pre><code>override fun onCreate(savedInstanceState: Bundle?) {
      super.onCreate(savedInstanceState)
      setContentView(R.layout.activity_main)
  
      Connection.connect()
  }
  </code></pre>
  
  <p>Object(singleton)</p>
  
  <pre><code>object Connection {
      fun connect() {
  
          val okHttpClient = OkHttpClient.Builder()
              .readTimeout(0, TimeUnit.MILLISECONDS)
              .build()
  
          val protocol = OkHttpWebSocket(
              okHttpClient,
              OkHttpWebSocket.SimpleRequestFactory(
                  { Request.Builder().url("ws://someURL").build() },
                  { ShutdownReason.GRACEFUL }
              )
          )
  
          val configuration = Scarlet.Configuration(
              streamAdapterFactories = listOf(RxJava2StreamAdapterFactory())
          )
  
          val scarletInstance = Scarlet(protocol, configuration)
  
          val webSocketService = scarletInstance.create&lt;WebSocketService&gt;()
  
      webSocketService.observeStateTransition()
          .observeOn(Schedulers.io())
          .subscribe({ stateTransition -&gt;
              val event = stateTransition.event
              val description = when (event) {
                  is Event.OnLifecycleStateChange -&gt; when (event.lifecycleState) {
                      LifecycleState.Started -&gt; Timber.d("On Lifecycle Start")
                      LifecycleState.Stopped -&gt; Timber.d("On Lifecycle Stop")
                      LifecycleState.Completed -&gt; Timber.d("On Lifecycle Terminate")
                  }
                  is Event.OnProtocolEvent -&gt; {
                      when (stateTransition.toState) {
                          is State.WillConnect -&gt; Timber.d("WaitingToRetry")
                          is State.Connecting -&gt; Timber.d("Connecting")
                          is State.Connected -&gt; Timber.d("Connected")
                          is State.Disconnecting -&gt; Timber.d("Disconnecting")
                          State.Disconnected -&gt; Timber.d("Disconnected")
                          State.Destroyed -&gt; Timber.d("Destroyed")
                      }
                  }
                  Event.OnShouldConnect -&gt; Timber.d("Should Connect")
              }
          }, {
              e -&gt;
              Timber.e(e)
          })
  
      webSocketService.observeWebSocketEvent()
          .observeOn(Schedulers.io())
          .subscribe({
              event -&gt;
              val description = when(event){
                  is WebSocketEvent.OnConnectionOpened -&gt; Timber.d("On WebSocket Connection Opened")
                  is WebSocketEvent.OnMessageReceived -&gt; Timber.d("On WebSocket NewMessageUpdate Received")
                  is WebSocketEvent.OnConnectionClosing -&gt; Timber.d("On WebSocket Connection Closing")
                  is WebSocketEvent.OnConnectionClosed -&gt; Timber.d("On WebSocket Connection Closed")
                  is WebSocketEvent.OnConnectionFailed -&gt; Timber.d("On WebSocket Connection Failed")
              }
          },
              {
                  Timber.e(it)
              })
  
  
      }
  }
  </code></pre>
  
  <p>Interface</p>
  
  <pre><code>interface WebSocketService {
  @Receive
  fun observeStateTransition(): Flowable&lt;StateTransition&gt;
  
  @Receive
  fun observeWebSocketEvent(): Flowable&lt;WebSocketEvent&gt;
  }
  </code></pre>