• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

socket

 
Sarada Bhasker
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can my servlet have a serversocket in that?
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13058
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A ServerSocket in a servlet class would not be a good idea since the Thread executing the accept() method would just sit there. You can certainly have a servlet communicate with another Java program that is running a ServerSocket.
Bill
 
Sarada Bhasker
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply. How can I make the servlet communicate with program running serversocket? Can you show an eg? Do I need to have a socket connection for the servlet and pipe it to client?
Thanks in advance

[This message has been edited by Sarada Bhasker (edited November 27, 2000).]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic