Class SegmentIdProperties.Chain.PrefetchWorker

java.lang.Object
me.ahoo.cosid.spring.boot.starter.segment.SegmentIdProperties.Chain.PrefetchWorker
Enclosing class:
SegmentIdProperties.Chain

public static class SegmentIdProperties.Chain.PrefetchWorker extends Object
Configuration for the prefetch worker that manages segment prefetching.
  • Constructor Details

    • PrefetchWorker

      public PrefetchWorker()
  • Method Details

    • getPrefetchPeriod

      public Duration getPrefetchPeriod()
      Gets the prefetch period.
      Returns:
      the prefetch period duration
    • setPrefetchPeriod

      public void setPrefetchPeriod(Duration prefetchPeriod)
      Sets the prefetch period.
      Parameters:
      prefetchPeriod - the prefetch period to set
    • getCorePoolSize

      public int getCorePoolSize()
      Gets the core pool size for the executor.
      Returns:
      the core pool size
    • setCorePoolSize

      public void setCorePoolSize(int corePoolSize)
      Sets the core pool size for the executor.
      Parameters:
      corePoolSize - the core pool size to set
    • isShutdownHook

      public boolean isShutdownHook()
      Checks if shutdown hook is enabled.
      Returns:
      true if shutdown hook is enabled, false otherwise
    • setShutdownHook

      public void setShutdownHook(boolean shutdownHook)
      Sets whether to enable shutdown hook.
      Parameters:
      shutdownHook - true to enable shutdown hook, false to disable