If you look at the docs for mod_unique it will generate a unique number in a properly 
configured server farm making it a good candidate for this process if you are worried 
about getting a unique number across several systems.

> -----Original Message-----
> From: Perrin Harkins [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, April 30, 2002 2:44 PM
> To: David Jacobs
> Cc: [EMAIL PROTECTED]
> Subject: Re: Cheap and unique
> 
> 
> David Jacobs wrote:
> > I'm converting a few CGI scripts that used the PID as a 
> cyclical unique 
> > number (in concert with TIMESTAMP - so it was TIMESTAMP.PID).
> > 
> > Our goal is to find a replacement function that is extremely cheap 
> > (cheaper than say, random(1000000)) and will never repeat. 
> Any ideas? 
> 
> Yes, mod_unique_id will do that, as will Sys::UniqueID and 
> Data::UUID on 
> CPAN.  Of course that random function is probably very 
> lightweight, but 
> it's not actually unique.
> 
> - Perrin
> 
> 

Reply via email to