ServerSocket Problem..

Hi.Is it possible for more than one thread having a ServerSocket instance each to listen at the same port and accept connections without affecting connections on other threads.?
[191 byte] By [elroydsilvaa] at [2007-11-26 20:04:40]
# 1
How all these threads will know who should accept new incoming connection? Your idea?
Michael.Nazarov@sun.coma at 2007-7-9 23:05:12 > top of Java-index,Core,Core APIs...
# 2
What are you trying to accomplish?I have always done server-side implementations with a single loop waiting for new connections, and then spawning a new thread for the new connection to handle the workload ( read/write/process ).
Salamzana at 2007-7-9 23:05:13 > top of Java-index,Core,Core APIs...
# 3
Why would you need two of these threads?
ejpa at 2007-7-9 23:05:13 > top of Java-index,Core,Core APIs...
# 4
In case if the load increases won't the connections have to wait?
elroydsilvaa at 2007-7-9 23:05:13 > top of Java-index,Core,Core APIs...
# 5
instead of trying multple threads .... scan data ... then ... invoke diff fuctions ... accordingly ... this will reduce complexity and overhead...
omkara.Javaa at 2007-7-9 23:05:13 > top of Java-index,Core,Core APIs...
# 6
Whatever that means. You don't need two ServerSockets on the same port to run two accepting threads. Both threads can accept from the same ServerSocket, if you think you have a good reason for doing that, such as multiple CPUs. If you don't have that there is no point in any of
ejpa at 2007-7-9 23:05:13 > top of Java-index,Core,Core APIs...