-3

Can i create multiple sockets in java one for listening from a client and others for forwarding data to back-end servers? I have done the program of multi-threaded server which is echoing the messages of client coming on a specific port..Specifically i want to take input from one socket and forward it to another socket in same program, in this scenario one socket which will act as a server for a client and another socket which will be client for another server.

Taimoor
  • 1
  • 1
  • 3
    Possible duplicate of [Is it possible to run a socket server and socket client on the same machine?](https://stackoverflow.com/questions/10069059/is-it-possible-to-run-a-socket-server-and-socket-client-on-the-same-machine) – OcelotcR Jan 03 '18 at 11:49

1 Answers1

1

Yes. You can support multiple sockets in one application.

Steve11235
  • 2,849
  • 1
  • 17
  • 18