StompProtocolAndroid icon indicating copy to clipboard operation
StompProtocolAndroid copied to clipboard

Could not find method org.java_websocket.client.WebSocketClient.setSocket

Open adek445 opened this issue 7 years ago • 4 comments

Hello, yesterday I've made android client to connect with ws but today something happend and got this error: I/dalvikvm: Could not find method org.java_websocket.client.WebSocketClient.setSocket, referenced from method ua.naiksoftware.stomp.WebSocketsConnectionProvider.createWebSocketConnection

You know what could that be? What is interesting messages are still sending to ws, but doesn't receive anything.

adek445 avatar Aug 09 '17 11:08 adek445

Are you using JWS or OkHttp as your connection provider? Are you including one or both of them in your Gradle dependencies?

forresthopkinsa avatar Aug 09 '17 15:08 forresthopkinsa

I'm including both of them. So i should use one of them? But if I use one of them I've got something like that: Could not find class 'okhttp3.OkHttpClient', referenced from method ua.naiksoftware.stomp.Stomp.getOkHttpClient or Could not find class 'org.java_websocekt.WebSocket', referenced from method ua.naiksoftware.stomp.Stomp.over

But, it's like warning and everything else working.

I've made new project and do eveything again and it's working. Sorry for trouble. Have a nice day.

adek445 avatar Aug 10 '17 07:08 adek445

Yeah, I was going to suggest that you use both. Glad it's working.

forresthopkinsa avatar Aug 10 '17 17:08 forresthopkinsa

Use this library its working fine, replace server url and port with your custom server url and your port. https://github.com/SayyedUmar/Stomp-Android-Client

testGumar avatar May 01 '19 07:05 testGumar