• Post Reply Bookmark Topic Watch Topic
  • New Topic

separating threads

 
Alex Rugav
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how do you separate threads for a client and server app in which the server has an infinite loop for listening to the client . my Gui is freezing when the loop is running
 
Ravindra Rawat
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
With the given details it seems your server and clients are in the same JVM and server thread is in a infinite loop and does not relinquish control i.e no Thread.sleep() in loop.

Can you provide some details so that we can understand the problem better?

Cheers
Ravindra
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24213
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ravindra --

As per our policy on display names, you need to change yours to include both a first and last name. You can go here to fix yours. Thanks for your immediate attention.

Alex --

This could be as simple as replacing the existing event-handler code with this:

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!