Closed Vlada31R closed 4 years ago
Hello @Vlada31R,
You cannot directly ping the server with this library but of course, you can use the connection methods to get the ping from server. I believe that you don't need to ping the server for your use-case, you have the Steam and encountered
error only.
Did you check these issues?
Also, I'm planning to add the ping the server functionality soon.
Hi, thank you for quick response. Yeah, I checked the issues. There are several possible solutions were mentioned:
@WrathChaos and maybe there are other opportunities to ping server with your library?
Hello @Vlada31R, Sorry for the late response. Actually you can fork the library and open a PR to finish this one: https://github.com/WrathChaos/StompClientLib/pull/25 Then we can fix the ping server problem at all. Really sorry but I have literally no time to integrate this logic and test it. I'm always open to any contribution. If you have time, please complete this PR :) I'm happy to merge it.
Hi, I see, thank you.
I will try to add this feature in this weekend but I cannot promise you @Vlada31R
Okay, thanks, I will try to do it. And I have one more assumption about the reason of "Stream and encountered" error. Could it be caused by using wss protocol? Thank you in advance!
@Vlada31R, Library itself uses the Facebook's SocketRocket which means it uses a WebSocket. Therefore, you have to use wss protocol. Honestly, I have no idea if you can use it without wss protocol or not.
I see, thank you very much!
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Hi, help me please. Using socketClient.socket?.send("\n") fails. I need to ping the server because I get "Stream and encountered" error, even after setting heart-beat.