Interface IdSegmentDistributor

All Superinterfaces:
Grouped
All Known Subinterfaces:
GroupedIdSegmentDistributor
All Known Implementing Classes:
DefaultGroupedIdSegmentDistributor, DefaultGroupedIdSegmentDistributor.GroupedBinding, IdSegmentDistributor.Atomic, IdSegmentDistributor.Mock, JdbcIdSegmentDistributor, MongoIdSegmentDistributor, ProxyIdSegmentDistributor, SpringRedisIdSegmentDistributor, ZookeeperIdSegmentDistributor

public interface IdSegmentDistributor extends Grouped
Id Segment Distributor.
  • Field Details

  • Method Details

    • getNamespace

      @Nonnull String getNamespace()
    • getName

      @Nonnull String getName()
    • getNamespacedName

      default String getNamespacedName()
    • getNamespacedName

      static String getNamespacedName(String namespace, String name)
    • getStep

      long getStep()
    • getStep

      default long getStep(int segments)
    • allowReset

      default boolean allowReset()
    • nextMaxId

      long nextMaxId(long step)
    • nextMaxId

      default long nextMaxId()
    • nextIdSegment

      @Nonnull default IdSegment nextIdSegment()
    • nextIdSegment

      @Nonnull default IdSegment nextIdSegment(long ttl)
    • nextIdSegment

      @Nonnull default IdSegment nextIdSegment(int segments, long ttl)
    • nextIdSegmentChain

      @Nonnull default IdSegmentChain nextIdSegmentChain(IdSegmentChain previousChain)
    • nextIdSegmentChain

      @Nonnull default IdSegmentChain nextIdSegmentChain(IdSegmentChain previousChain, int segments, long ttl)
    • ensureStep

      static void ensureStep(long step)