java.net.ProtocolException: Expected HTTP 101 response but was '200 OK'

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via GitHub by akroston
, 1 year ago
Expected HTTP 101 response but was '200 OK'
via GitHub by remy-phelipot
, 1 year ago
Expected HTTP 101 response but was '200 OK'
via GitHub by foxish
, 11 months ago
Expected HTTP 101 response but was '200 OK'
via GitHub by rarora13
, 1 year ago
Expected HTTP 101 response but was '503 Endpoint Creation Failed'
java.net.ProtocolException: Expected HTTP 101 response but was '200 OK'
at okhttp3.ws.WebSocketCall.createWebSocket(WebSocketCall.java:122)
at okhttp3.ws.WebSocketCall.access$000(WebSocketCall.java:41)
at okhttp3.ws.WebSocketCall$1.onResponse(WebSocketCall.java:97)
at okhttp3.RealCall$AsyncCall.execute(RealCall.java:126)
at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

Users with the same issue

You are the first who have seen this exception.

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.