Based on the Twitter Snowflake algorithm
functions list:
-
- string atom_next_id(void);
Get the next unique ID.
- string atom_next_id(void);
-
- array atom_explain(string ID);
Change unique ID to array includes: timestamp, datacenter id and worker id.
- array atom_explain(string ID);
<h3>install:</h3>
<pre><code>
$ cd ./atom
$ phpize
$ ./configure
$ make
$ sudo make install
</code></pre>
<h3>php.ini configure entries:</h3>
<pre><code>
[atom]
atom.datacenter = integer
atom.worker = intger
atom.twepoch = uint64
</code></pre>