TooTallNate / Java-WebSocket

A barebones WebSocket client and server implementation written in 100% Java.
http://tootallnate.github.io/Java-WebSocket
MIT License
10.36k stars 2.57k forks source link

WebSocket Client doesn't terminate after close or closeConnection #1357

Closed BenedictLelanz closed 9 months ago

BenedictLelanz commented 9 months ago

After creating a connection in my WebSocketClient extending class with

super(URI.create("wss://"+WEBSITE+":443"));

and

super.connect()

I have the problem that the application doesn't terminate although I called the close() method or the closeConnection() method after a while. Maybe some Threads are still running? I know I could trigger System.exit(), but in my case I need to open and close connections over a long time again and again. It would be horrible if there will be more and more threads running in the background and slowing down the system.

Is this a bug? Or do Ihave to trigger some special method?

PhilipRoman commented 9 months ago

Can you please post a small program which reproduces this issue?

BenedictLelanz commented 9 months ago

I'm sorry, I just realized it was my fault :D