• Post Reply Bookmark Topic Watch Topic
  • New Topic

fault tolerance client /server  RSS feed

 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

i use a very basic client/server socket program

very similar to sun:
http://java.sun.com/docs/books/tutorial/networking/sockets/clientServer.html

many client can connect to the server...

i would like to add a fault tolerance...

a client try to connect a few time... that don't work, the client try to the second server...

does a need to do something similar to



thanks
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Something like that. Here's a very similar method that starts up servers for me. Configuration has a list of ports separated by commas, eg 9000,9002,9004

This thread runs out and terminates shortly after this startup. The server threads run until told to stop and then close their own resources.

Does that kind of affirm your direction?
[ October 01, 2005: Message edited by: Stan James ]
 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ya

and client level what you do?
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nothing - the client is a browser. In another application we had code in a Swing client to fail over from one server to another after "n" tries. It could also fail back later ... exactly the same code again, just worked its way down an array of port numbers and then started over I think.
 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok but my client is not in a browser... for me the port change...
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!