Forums Register Login

Unable to create 3000 Server Socket objects on Windows

+Pie Number of slices to send: Send
Hi,

I am developing an application, where the requirement of the application is to create 3000 server socket objects and listen to the incoming data. When I try to create 3000 socket server objects in the program, I am encountering an IOException stating that the BUFFER LIMIT is attained.

The program which is generating the 3000 Server Socket objects is being developed on Windows.

Q 1) Is this a limitation which Windows imposes?

Q 2) If this is not an Operating System issue then how do I get around with this problem.

Relevant answers are appreciated.

thank you
+Pie Number of slices to send: Send
This is kind of an unusual design. Normally you'd have a single ServerSocket, and then put a multi-threaded server behind it so that it can process multiple incoming requests. Can you tell us why so many server sockets are required? (What's more, since every ServerSocket runs on its own port, the clients need to know which port to connect to.)
+Pie Number of slices to send: Send
It's an OS limitation. As Ulf says, this is not the way things are normally done. What are you trying to achieve with this design?
+Pie Number of slices to send: Send
The requirement of the application is to simulate n number of servers. In this case the application needs to assign a unique port to each SocketServer and listen on that port. But I am unable to create beyond 325 server sockets.

So, is this a limitation which OS imposes or can i increase the buffer size.

Please understand the situation. The application needs to simulate n number of servers and server the requests.


Thank you
+Pie Number of slices to send: Send
As I already said, it's an OS limitation, unrelated to Java. You'd want to refer to Windows administation documents to learn how to raise this limit, if it's possible.

But if you're doing a simulation, then why use real ServerSockets? Do a simulation.
I just had the craziest dream. This tiny ad was in it.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 862 times.
Similar Threads
question regarding server socket if server socket is other machine
ObjectInputStream problems "connection reset"
sending xml file from server to client dynamically.
SocketConnection in Java and J2me
java.net.SocketException: Unrecognized Windows Sockets error: 10106: create
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 00:37:35.