Package io.milvus.param.control
Class LoadBalanceParam.Builder
java.lang.Object
io.milvus.param.control.LoadBalanceParam.Builder
- Enclosing class:
LoadBalanceParam
Builder for
LoadBalanceParam class.-
Method Summary
Modifier and TypeMethodDescriptionaddDestinationNodeID(@NonNull Long destNodeID) Adds the destination query node by ID to which the sealed segments will be balanced.addSegmentID(@NonNull Long segmentID) Adds a sealed segments by ID to be balanced.build()Verifies parameters and creates a newLoadBalanceParaminstance.withCollectionName(@NonNull String collectionName) Sets the collection name.withDatabaseName(String databaseName) Sets the database name.withDestinationNodeID(@NonNull List<Long> destNodeIDs) Sets the destination query node by ID array to which the sealed segments will be balance.withSegmentIDs(@NonNull List<Long> segmentIDs) Sets a sealed segments by ID array to be balanced.withSourceNodeID(@NonNull Long srcNodeID) Sets the source query node by ID in which the sealed segments were loaded.
-
Method Details
-
withDatabaseName
Sets the database name. database name can be nil.- Parameters:
databaseName- database name- Returns:
Builder
-
withCollectionName
Sets the collection name. Collection name cannot be empty or null.- Parameters:
collectionName- collection name- Returns:
Builder
-
withSourceNodeID
Sets the source query node by ID in which the sealed segments were loaded.- Parameters:
srcNodeID- source query node id- Returns:
Builder
-
addDestinationNodeID
Adds the destination query node by ID to which the sealed segments will be balanced.- Parameters:
destNodeID- destination query node id- Returns:
Builder
-
withDestinationNodeID
Sets the destination query node by ID array to which the sealed segments will be balance.- Parameters:
destNodeIDs- destination query node id array- Returns:
Builder
-
addSegmentID
Adds a sealed segments by ID to be balanced.- Parameters:
segmentID- sealed segment id- Returns:
Builder
-
withSegmentIDs
Sets a sealed segments by ID array to be balanced.- Parameters:
segmentIDs- sealed segments id array- Returns:
Builder
-
build
Verifies parameters and creates a newLoadBalanceParaminstance.- Returns:
LoadBalanceParam- Throws:
ParamException
-