WorkerNodeEntityDefaultUidGenerator63 bits for timestampBits, workerIdBits, sequenceBitsRingBufferRingBuffer and BufferedUidProvider, default use scheduleRingBuffer, BufferedUidProvider, and whether use schedule paddingUidGenerator extends
from DefaultUidGenerator, based on a lock free RingBuffer
The spring properties you can specified as below:(BitsAllocator.getMaxSequence() + 1) <<
CachedUidGenerator.boostPower, Default as
paddingFactor: Represents a percent value of (0 - 100).UidGenerator
The unique id has 64bits (long), default allocated as blow:RejectedPutBufferHandler, we just do loggingWorkerIdAssigner,
the worker id will be discarded after assigned to the UidGeneratorValuedEnum such as Parse, value of...RejectedTakeBufferHandler, throws RuntimeException after loggingWorkerNodeEntity by node hostAtomicLong to prevent the FalseSharing problem
The CPU cache line commonly be 64 bytes, here is a sample of cache line after padding:AtomicLongRejectedTakeBufferHandler will be appliedValuedEnum defines an enumeration which is bounded to a value, you
may implements this interface when you defines such kind of enumeration, that
you can use EnumUtils to simplify parse and valueOf operation.DefaultUidGeneratorCopyright © 2020. All rights reserved.