Class DispatcherContext.Builder

java.lang.Object
org.apache.hadoop.ozone.container.common.transport.server.ratis.DispatcherContext.Builder
Enclosing class:
DispatcherContext

public static final class DispatcherContext.Builder extends Object
Builder class for building DispatcherContext.
  • Method Details

    • setStage

      Sets the WriteChunkStage.
      Parameters:
      writeChunkStage - WriteChunk Stage
      Returns:
      DispatcherContext.Builder
    • setTerm

      public DispatcherContext.Builder setTerm(long currentTerm)
      Sets the current term for the container request from Ratis.
      Parameters:
      currentTerm - current term
      Returns:
      DispatcherContext.Builder
    • setLogIndex

      public DispatcherContext.Builder setLogIndex(long index)
      Sets the logIndex for the container request from Ratis.
      Parameters:
      index - log index
      Returns:
      DispatcherContext.Builder
    • setContainer2BCSIDMap

      public DispatcherContext.Builder setContainer2BCSIDMap(Map<Long,Long> map)
      Sets the container2BCSIDMap to contain all the containerIds per RaftGroup.
      Parameters:
      map - container2BCSIDMap
      Returns:
      Builder
    • setReleaseSupported

      public DispatcherContext.Builder setReleaseSupported(boolean releaseSupported)
    • build

      public DispatcherContext build()
      Builds and returns DispatcherContext instance.
      Returns:
      DispatcherContext