Home arrow static arrow Java Programming [Archive] - How do it
Warning: Creating default object from empty value in /www/htdocs/w008deb8/wiki/components/com_staticxt/staticxt.php on line 51
Java Programming [Archive] - How do it
This topic has 3 replies on 1 page.

Posts:3
Registered: 7/1/04
How do it  
Jul 2, 2004 5:42 AM



 
Hi all,

I have two java applications running on two different servers.When ever client send a message through one java application I want to assign a unique ID inboth application which were running on different servers.,i have to send the acknowdegement to the client of status of the Message. with that Unique ID.

How can i do.

 

Posts:3,999
Registered: 00-05-26
Re: How do it  
Jul 2, 2004 11:50 AM (reply 1 of 3)



 
You'd prolly start with this:

java.rmi.dgc.VMID

and added what you need
 

Posts:3
Registered: 7/1/04
Re: How do it  
Jul 3, 2004 6:22 AM (reply 2 of 3)



 
Hi DMBDMB,

I thank you for ur reply,can you explain me in detail please,Better if you have any code snippt,

Thanking you
Norah

 

Posts:3,999
Registered: 00-05-26
Re: How do it  
Jul 3, 2004 7:13 PM (reply 3 of 3)



 
Well, doing

String uid = new VMID().toString();

will give you a unique id for this jvm, You can then keep your own counter to produce a unique id within this jvm and concatenate them together.
 
This topic has 3 replies on 1 page.