Package icu.congee.id.generator.elasticflake
package icu.congee.id.generator.elasticflake
-
ClassesClassDescriptionA
Base64.InputStreamwill read data from anotherjava.io.InputStream, given in the constructor, and encode/decode to/from Base64 notation on the fly.ABase64.OutputStreamwill write data to anotherjava.io.OutputStream, given in the constructor, and encode/decode to/from Base64 notation on the fly.These are essentially flake ids (http://boundary.com/blog/2012/01/12/flake-a-decentralized-k-ordered-unique-id-generator-in-erlang) but we use 6 (not 8) bytes for timestamp, and use 3 (not 2) bytes for sequence number.