I have client and server threads in my applications. When I run these applications as standalone applications, these threads exchange data.
But when I start the client as JUnit and the server as standalone, the client thread dies within a few seconds.
I could not understand why this behavior.
When the JUnit runner completes, all spawned threads, etc. are also killed (since this is most likely done in a separate JVM instance).
( ) , , ( GroboUtils, , , -). , , , Java concurrency.
, , Future s. Future.get , , JUnit. .
Future
Future.get