Package org.apache.pinot.common.messages
Class SegmentRefreshMessage
- java.lang.Object
-
- org.apache.helix.HelixProperty
-
- org.apache.helix.model.Message
-
- org.apache.pinot.common.messages.SegmentRefreshMessage
-
public class SegmentRefreshMessage extends org.apache.helix.model.MessageThis (Helix) message is sent from the controller to servers and brokers when a request is received to refresh an existing segment. When server gets this message, it will check the crc of the local segment and the segment ZK metadata and download the refreshed segment if necessary. When broker gets this message, it will update the routing properties (time boundary, partition info etc.) based on the refreshed segment ZK metadata. NOTE: Changing this class to include new fields is a change in the protocol, so the new fields must be made optional, and coded in such a way that either controller, broker or server may be upgraded first. TODO: "tableName" and "segmentName" are new added fields. Change SegmentMessageHandlerFactory to use these 2 fields in the next release for backward-compatibility
-
-
Field Summary
Fields Modifier and Type Field Description static StringREFRESH_SEGMENT_MSG_SUB_TYPE
-
Constructor Summary
Constructors Constructor Description SegmentRefreshMessage(String tableNameWithType, String segmentName)Constructor for the sender.SegmentRefreshMessage(org.apache.helix.model.Message message)Constructor for the receiver.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetSegmentName()StringgetTableNameWithType()-
Methods inherited from class org.apache.helix.model.Message
addPartitionName, attachRelayMessage, createReplyMessage, getAttribute, getBucketSize, getCompletionDueTimeStamp, getCorrelationId, getCreateTimeStamp, getDebug, getExecuteStartTimeStamp, getExecutionSessionId, getExecutionTimeout, getExpiryPeriod, getFromState, getGeneration, getKey, getMsgId, getMsgSrc, getMsgState, getMsgSubType, getMsgType, getPartitionName, getPartitionNames, getReadTimeStamp, getRelayMessage, getRelayMessages, getRelaySrcHost, getRelayTime, getResourceGroupName, getResourceName, getResourceTag, getResultMap, getRetryCount, getSrcClusterName, getSrcInstanceType, getSrcSessionId, getStateModelDef, getStateModelFactoryName, getTgtName, getTgtSessionId, getToState, hasRelayMessages, isControlerMsg, isExpired, isParticipantStatusChangeType, isRelayMessage, isValid, setAttribute, setBucketSize, setCompletionDueTimeStamp, setCorrelationId, setCreateTimeStamp, setExecuteSessionId, setExecuteStartTimeStamp, setExecutionTimeout, setExpectedSessionId, setExpired, setExpiryPeriod, setFromState, setMsgId, setMsgState, setMsgSubType, setPartitionName, setReadTimeStamp, setRelayTime, setResourceGroupName, setResourceName, setResourceTag, setResultMap, setRetryCount, setSrcClusterName, setSrcInstanceType, setSrcName, setSrcSessionId, setStateModelDef, setStateModelFactoryName, setTgtName, setTgtSessionId, setToState
-
-
-
-
Field Detail
-
REFRESH_SEGMENT_MSG_SUB_TYPE
public static final String REFRESH_SEGMENT_MSG_SUB_TYPE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SegmentRefreshMessage
public SegmentRefreshMessage(String tableNameWithType, String segmentName)
Constructor for the sender.
-
SegmentRefreshMessage
public SegmentRefreshMessage(org.apache.helix.model.Message message)
Constructor for the receiver.- Parameters:
message- The incoming message that has been received from helix.- Throws:
IllegalArgumentException- if the message is not of right sub-type
-
-