Package com.linkedin.venice.meta
Class VersionImpl
java.lang.Object
com.linkedin.venice.meta.VersionImpl
- All Implemented Interfaces:
DataModelBackedStructure<StoreVersion>
,Version
,Comparable<Version>
Class defines the version of Venice store.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.linkedin.venice.meta.Version
Version.PushType
-
Field Summary
Fields inherited from interface com.linkedin.venice.meta.Version
REAL_TIME_TOPIC_SUFFIX, REPLICATION_METADATA_VERSION_ID_UNSET, SEPARATE_REAL_TIME_TOPIC_SUFFIX, STREAM_REPROCESSING_TOPIC_SUFFIX, VENICE_RE_PUSH_PUSH_ID_PREFIX, VENICE_TTL_RE_PUSH_PUSH_ID_PREFIX, VERSION_SEPARATOR
-
Constructor Summary
ConstructorDescriptionVersionImpl
(String storeName, int number) Deprecated.VersionImpl
(String storeName, int number, long createdTime, String pushJobId, int partitionCount, PartitionerConfig partitionerConfig, DataRecoveryVersionConfig dataRecoveryVersionConfig) VersionImpl
(String storeName, int number, String pushJobId) VersionImpl
(String storeName, int number, String pushJobId, int partitionCount) -
Method Summary
Modifier and TypeMethodDescriptionClone a new version based on current data in this version.int
Return the backed data model.boolean
getAge()
long
boolean
int
final int
int
int
int
int
final String
int
int
hashCode()
boolean
boolean
boolean
boolean
isHybrid()
boolean
boolean
boolean
boolean
boolean
boolean
boolean
Kafka topic name is composed by store name and version.void
setActiveActiveReplicationEnabled
(boolean activeActiveReplicationEnabled) void
void
setBlobTransferEnabled
(boolean blobTransferEnabled) void
setBufferReplayEnabledForHybrid
(boolean bufferReplayEnabledForHybrid) void
setChunkingEnabled
(boolean chunkingEnabled) void
setCompressionStrategy
(CompressionStrategy compressionStrategy) void
setDataRecoveryVersionConfig
(DataRecoveryVersionConfig dataRecoveryVersionConfig) void
setHybridStoreConfig
(HybridStoreConfig hybridConfig) void
setIncrementalPushEnabled
(boolean incrementalPushEnabled) void
setIsDavinciHeartbeatReported
(boolean isReported) void
setNativeReplicationEnabled
(boolean nativeReplicationEnabled) void
setNativeReplicationSourceFabric
(String nativeReplicationSourceFabric) void
setNumber
(int number) void
setPartitionCount
(int partitionCount) void
setPartitionerConfig
(PartitionerConfig partitionerConfig) void
setPushJobId
(String pushJobId) void
setPushStreamSourceAddress
(String address) void
setPushType
(Version.PushType pushType) void
setReplicationFactor
(int replicationFactor) void
setRepushSourceVersion
(int version) void
setRmdChunkingEnabled
(boolean rmdChunkingEnabled) void
setRmdVersionId
(int replicationMetadataVersionId) void
setSeparateRealTimeTopicEnabled
(boolean separateRealTimeTopicEnabled) void
setStatus
(VersionStatus status) void
setTargetSwapRegion
(String targetRegion) void
setTargetSwapRegionWaitTime
(int waitTime) void
setUseVersionLevelHybridConfig
(boolean versionLevelHybridConfig) void
setUseVersionLevelIncrementalPushEnabled
(boolean versionLevelIncrementalPushEnabled) void
setVersionSwapDeferred
(boolean deferVersionSwap) void
setViewConfigs
(Map<String, ViewConfig> viewConfigList) toString()
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.linkedin.venice.meta.Version
getTimestampMetadataVersionId, isLeaderFollowerModelEnabled, setLeaderFollowerModelEnabled, setTimestampMetadataVersionId
-
Constructor Details
-
VersionImpl
Deprecated.Use the constructor that specifies a pushJobId instead Currently used in tests only. -
VersionImpl
-
VersionImpl
-
VersionImpl
public VersionImpl(String storeName, int number, long createdTime, String pushJobId, int partitionCount, PartitionerConfig partitionerConfig, DataRecoveryVersionConfig dataRecoveryVersionConfig)
-
-
Method Details
-
getNumber
public final int getNumber() -
setNumber
public void setNumber(int number) -
getCreatedTime
public long getCreatedTime()- Specified by:
getCreatedTime
in interfaceVersion
-
getAge
-
setAge
-
getStatus
-
setStatus
-
getCompressionStrategy
- Specified by:
getCompressionStrategy
in interfaceVersion
-
setCompressionStrategy
- Specified by:
setCompressionStrategy
in interfaceVersion
-
isNativeReplicationEnabled
public boolean isNativeReplicationEnabled()- Specified by:
isNativeReplicationEnabled
in interfaceVersion
-
setNativeReplicationEnabled
public void setNativeReplicationEnabled(boolean nativeReplicationEnabled) - Specified by:
setNativeReplicationEnabled
in interfaceVersion
-
getPushStreamSourceAddress
- Specified by:
getPushStreamSourceAddress
in interfaceVersion
-
setPushStreamSourceAddress
- Specified by:
setPushStreamSourceAddress
in interfaceVersion
-
setBufferReplayEnabledForHybrid
public void setBufferReplayEnabledForHybrid(boolean bufferReplayEnabledForHybrid) - Specified by:
setBufferReplayEnabledForHybrid
in interfaceVersion
-
isChunkingEnabled
public boolean isChunkingEnabled()- Specified by:
isChunkingEnabled
in interfaceVersion
-
setChunkingEnabled
public void setChunkingEnabled(boolean chunkingEnabled) - Specified by:
setChunkingEnabled
in interfaceVersion
-
isRmdChunkingEnabled
public boolean isRmdChunkingEnabled()- Specified by:
isRmdChunkingEnabled
in interfaceVersion
-
setRmdChunkingEnabled
public void setRmdChunkingEnabled(boolean rmdChunkingEnabled) - Specified by:
setRmdChunkingEnabled
in interfaceVersion
-
getStoreName
- Specified by:
getStoreName
in interfaceVersion
-
getPushJobId
- Specified by:
getPushJobId
in interfaceVersion
-
setPushJobId
- Specified by:
setPushJobId
in interfaceVersion
-
getPushType
- Specified by:
getPushType
in interfaceVersion
-
setPushType
- Specified by:
setPushType
in interfaceVersion
-
setPartitionCount
public void setPartitionCount(int partitionCount) - Specified by:
setPartitionCount
in interfaceVersion
-
getPartitionCount
public int getPartitionCount()- Specified by:
getPartitionCount
in interfaceVersion
-
getPartitionerConfig
- Specified by:
getPartitionerConfig
in interfaceVersion
-
setPartitionerConfig
- Specified by:
setPartitionerConfig
in interfaceVersion
-
isVersionSwapDeferred
public boolean isVersionSwapDeferred()- Specified by:
isVersionSwapDeferred
in interfaceVersion
-
setVersionSwapDeferred
public void setVersionSwapDeferred(boolean deferVersionSwap) - Specified by:
setVersionSwapDeferred
in interfaceVersion
-
getReplicationFactor
public int getReplicationFactor()- Specified by:
getReplicationFactor
in interfaceVersion
-
setReplicationFactor
public void setReplicationFactor(int replicationFactor) - Specified by:
setReplicationFactor
in interfaceVersion
-
getMinActiveReplicas
public int getMinActiveReplicas()- Specified by:
getMinActiveReplicas
in interfaceVersion
-
getNativeReplicationSourceFabric
- Specified by:
getNativeReplicationSourceFabric
in interfaceVersion
-
setNativeReplicationSourceFabric
- Specified by:
setNativeReplicationSourceFabric
in interfaceVersion
-
isIncrementalPushEnabled
public boolean isIncrementalPushEnabled()- Specified by:
isIncrementalPushEnabled
in interfaceVersion
-
setIncrementalPushEnabled
public void setIncrementalPushEnabled(boolean incrementalPushEnabled) - Specified by:
setIncrementalPushEnabled
in interfaceVersion
-
isSeparateRealTimeTopicEnabled
public boolean isSeparateRealTimeTopicEnabled()- Specified by:
isSeparateRealTimeTopicEnabled
in interfaceVersion
-
setSeparateRealTimeTopicEnabled
public void setSeparateRealTimeTopicEnabled(boolean separateRealTimeTopicEnabled) - Specified by:
setSeparateRealTimeTopicEnabled
in interfaceVersion
-
isBlobTransferEnabled
public boolean isBlobTransferEnabled()- Specified by:
isBlobTransferEnabled
in interfaceVersion
-
setBlobTransferEnabled
public void setBlobTransferEnabled(boolean blobTransferEnabled) - Specified by:
setBlobTransferEnabled
in interfaceVersion
-
isUseVersionLevelIncrementalPushEnabled
public boolean isUseVersionLevelIncrementalPushEnabled()- Specified by:
isUseVersionLevelIncrementalPushEnabled
in interfaceVersion
-
setUseVersionLevelIncrementalPushEnabled
public void setUseVersionLevelIncrementalPushEnabled(boolean versionLevelIncrementalPushEnabled) - Specified by:
setUseVersionLevelIncrementalPushEnabled
in interfaceVersion
-
isHybrid
public boolean isHybrid() -
getHybridStoreConfig
- Specified by:
getHybridStoreConfig
in interfaceVersion
-
setHybridStoreConfig
- Specified by:
setHybridStoreConfig
in interfaceVersion
-
getViewConfigs
- Specified by:
getViewConfigs
in interfaceVersion
-
setViewConfigs
- Specified by:
setViewConfigs
in interfaceVersion
-
isUseVersionLevelHybridConfig
public boolean isUseVersionLevelHybridConfig()- Specified by:
isUseVersionLevelHybridConfig
in interfaceVersion
-
setUseVersionLevelHybridConfig
public void setUseVersionLevelHybridConfig(boolean versionLevelHybridConfig) - Specified by:
setUseVersionLevelHybridConfig
in interfaceVersion
-
isActiveActiveReplicationEnabled
public boolean isActiveActiveReplicationEnabled()- Specified by:
isActiveActiveReplicationEnabled
in interfaceVersion
-
setActiveActiveReplicationEnabled
public void setActiveActiveReplicationEnabled(boolean activeActiveReplicationEnabled) - Specified by:
setActiveActiveReplicationEnabled
in interfaceVersion
-
getDataRecoveryVersionConfig
- Specified by:
getDataRecoveryVersionConfig
in interfaceVersion
-
setDataRecoveryVersionConfig
- Specified by:
setDataRecoveryVersionConfig
in interfaceVersion
-
setRepushSourceVersion
public void setRepushSourceVersion(int version) - Specified by:
setRepushSourceVersion
in interfaceVersion
-
getRepushSourceVersion
public int getRepushSourceVersion()- Specified by:
getRepushSourceVersion
in interfaceVersion
-
getRmdVersionId
public int getRmdVersionId()- Specified by:
getRmdVersionId
in interfaceVersion
-
setRmdVersionId
public void setRmdVersionId(int replicationMetadataVersionId) - Specified by:
setRmdVersionId
in interfaceVersion
-
setTargetSwapRegion
- Specified by:
setTargetSwapRegion
in interfaceVersion
-
getTargetSwapRegion
- Specified by:
getTargetSwapRegion
in interfaceVersion
-
setTargetSwapRegionWaitTime
public void setTargetSwapRegionWaitTime(int waitTime) - Specified by:
setTargetSwapRegionWaitTime
in interfaceVersion
-
getTargetSwapRegionWaitTime
public int getTargetSwapRegionWaitTime()- Specified by:
getTargetSwapRegionWaitTime
in interfaceVersion
-
setIsDavinciHeartbeatReported
public void setIsDavinciHeartbeatReported(boolean isReported) - Specified by:
setIsDavinciHeartbeatReported
in interfaceVersion
-
getIsDavinciHeartbeatReported
public boolean getIsDavinciHeartbeatReported()- Specified by:
getIsDavinciHeartbeatReported
in interfaceVersion
-
dataModel
Description copied from interface:DataModelBackedStructure
Return the backed data model.- Specified by:
dataModel
in interfaceDataModelBackedStructure<StoreVersion>
- Returns:
-
toString
-
compareTo
- Specified by:
compareTo
in interfaceComparable<Version>
-
equals
-
hashCode
public int hashCode() -
cloneVersion
Clone a new version based on current data in this version.- Specified by:
cloneVersion
in interfaceVersion
- Returns:
- cloned version.
-
kafkaTopicName
Kafka topic name is composed by store name and version.The Json deserializer will think it should be a field called kafkaTopicName if we use "getKafkaTopicName" here. So use "kafkaTopicName" directly here to avoid error when deserializing.
- Specified by:
kafkaTopicName
in interfaceVersion
- Returns:
- kafka topic name.
-