Interview Question

Reply

Join Date: Sep 2006
Posts: 30
Reputation: sarath.koiloth is an unknown quantity at this point 
Solved Threads: 0
sarath.koiloth's Avatar
sarath.koiloth sarath.koiloth is offline Offline
Light Poster

Interview Question

 
0
  #1
Aug 26th, 2009
I attended one interview today,Interviewer asked me one question regarding the creation of unique identifier.

Question :

Consider same webapplication is deployed in 3 webserver.if any user registered in any of my application,a unique identifer is given to the user.It cannot be stored in a database.3 webserver should not produce the same uid again.How t implement this ?
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 83
Reputation: nmaillet is an unknown quantity at this point 
Solved Threads: 18
nmaillet nmaillet is offline Offline
Junior Poster in Training

Re: Interview Question

 
0
  #2
Aug 26th, 2009
Since there is no database is available, you could always check with the other web servers before using a UID. There could be two ways of implementing this:
- either each server keeps track of every UID used (synchronization errors could occur), or
- each server keeps a list of its own UID's (would longer to generate a UID, and if one server goes offline there could be problems)
Reply With Quote Quick reply to this message  
Join Date: Sep 2006
Posts: 30
Reputation: sarath.koiloth is an unknown quantity at this point 
Solved Threads: 0
sarath.koiloth's Avatar
sarath.koiloth sarath.koiloth is offline Offline
Light Poster

Re: Interview Question

 
0
  #3
Aug 27th, 2009
Thank you for your reply.How will they communicate with each other ?
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC