Class DispatcherContext.Builder
java.lang.Object
org.apache.hadoop.ozone.container.common.transport.server.ratis.DispatcherContext.Builder
- Enclosing class:
DispatcherContext
Builder class for building DispatcherContext.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds and returns DispatcherContext instance.setContainer2BCSIDMap(Map<Long, Long> map) Sets the container2BCSIDMap to contain all the containerIds per RaftGroup.setLogIndex(long index) Sets the logIndex for the container request from Ratis.setReleaseSupported(boolean releaseSupported) setStage(DispatcherContext.WriteChunkStage writeChunkStage) Sets the WriteChunkStage.setTerm(long currentTerm) Sets the current term for the container request from Ratis.
-
Method Details
-
setStage
Sets the WriteChunkStage.- Parameters:
writeChunkStage- WriteChunk Stage- Returns:
- DispatcherContext.Builder
-
setTerm
Sets the current term for the container request from Ratis.- Parameters:
currentTerm- current term- Returns:
- DispatcherContext.Builder
-
setLogIndex
Sets the logIndex for the container request from Ratis.- Parameters:
index- log index- Returns:
- DispatcherContext.Builder
-
setContainer2BCSIDMap
Sets the container2BCSIDMap to contain all the containerIds per RaftGroup.- Parameters:
map- container2BCSIDMap- Returns:
- Builder
-
setReleaseSupported
-
build
Builds and returns DispatcherContext instance.- Returns:
- DispatcherContext
-