Results 1 to 3 of 3
- 03-28-2011, 06:12 AM #1
Member
- Join Date
- Mar 2011
- Posts
- 10
- Rep Power
- 0
Connecting 3 machines through Sockets and ServerSockets
Hi All
I need to connect 3 machines which will be running a Java program and each will be assigned Process ID as P0, P1 or P2 such that
1. P0 starts and waits for other machines to connect to it
2. P1 starts and connects to P0
3. P2 starts and connects to both P1 and P0
After that these 3 machines will exchange messages between each other. I am not clear as to whether I should create both client Sockets and ServerSockets on all the 3 machines and how to connect them.
For machine P0, should I create client Socket ? With which machine should I connect it as it needs to read from both P1 and P2. Can someone help me with design. Each machine has to act as client as well as server.
Thanks and RegardsLast edited by Yogesh_P; 03-28-2011 at 06:17 AM.
- 03-28-2011, 02:30 PM #2
what do you mean with "After that these 3 machines will exchange messages between each other."? some kind of broadcast? look here for client and server examples.
- 03-28-2011, 03:06 PM #3
Member
- Join Date
- Mar 2011
- Posts
- 10
- Rep Power
- 0
3 machines need to implement totally ordered multicast i.e if there are some updates occuring on variable x and y at Process 0, 1 and 2 then all Processes must update those variables in same order. So for that every machine will send messages to other machines with their new x and y.
Regards
Similar Threads
-
JMF needed on target machines
By fatblacktone in forum New To JavaReplies: 1Last Post: 04-06-2010, 07:57 AM -
Problems with connecting two sockets on the same application.
By jrsofty in forum NetworkingReplies: 0Last Post: 12-01-2009, 01:04 PM -
JDK versions on web server and client machines
By sunjavaboy in forum New To JavaReplies: 1Last Post: 03-21-2008, 04:59 AM -
How to determine all the IP addresses of machines on local LAN??
By JavaEmpires in forum NetworkingReplies: 3Last Post: 01-19-2008, 06:05 AM -
Cluster using 2 machines
By Albert in forum Advanced JavaReplies: 2Last Post: 07-04-2007, 06:31 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks