public static class TierObjectStore.TierStateRestoreSnapshotMetadata extends Object implements TierObjectStore.ObjectStoreMetadata
Modifier and Type | Field and Description |
---|---|
static int |
VERSION_V0 |
static int |
VERSION_V1 |
Constructor and Description |
---|
TierStateRestoreSnapshotMetadata(TierPartitionForceRestore metadata) |
TierStateRestoreSnapshotMetadata(TopicIdPartition topicIdPartition,
long startOffset,
long endOffset,
String contentHash,
Algorithm checksumAlgorithm) |
TierStateRestoreSnapshotMetadata(TopicIdPartition topicIdPartition,
long startOffset,
long endOffset,
String contentHash,
Algorithm checksumAlgorithm,
int metadataVersion) |
Modifier and Type | Method and Description |
---|---|
Algorithm |
checksumAlgorithm() |
boolean |
equals(Object o) |
int |
hashCode() |
Map<String,String> |
objectMetadata(Optional<String> clusterIdOpt,
Optional<Integer> brokerIdOpt)
Converts an ObjectStoreMetadata to a map of metadata that may be useful to place on
objects in object storage, if this functionality is present in the object store
implementation of choice
|
TierObjectStore.OpaqueData |
opaqueData() |
String |
toPath(String keyPrefix,
TierObjectStore.FileType fileType)
Converts the ObjectStoreMetadata to an object store key path, taking into account a
given key prefix and file type
|
TopicIdPartition |
topicIdPartition() |
String |
toString() |
int |
version() |
public static final int VERSION_V0
public static final int VERSION_V1
public TierStateRestoreSnapshotMetadata(TopicIdPartition topicIdPartition, long startOffset, long endOffset, String contentHash, Algorithm checksumAlgorithm, int metadataVersion)
public TierStateRestoreSnapshotMetadata(TierPartitionForceRestore metadata)
public TierStateRestoreSnapshotMetadata(TopicIdPartition topicIdPartition, long startOffset, long endOffset, String contentHash, Algorithm checksumAlgorithm)
public int version()
public TopicIdPartition topicIdPartition()
public Algorithm checksumAlgorithm()
public Map<String,String> objectMetadata(Optional<String> clusterIdOpt, Optional<Integer> brokerIdOpt)
TierObjectStore.ObjectStoreMetadata
objectMetadata
in interface TierObjectStore.ObjectStoreMetadata
clusterIdOpt
- optional kafka cluster idbrokerIdOpt
- optional kafka broker idpublic TierObjectStore.OpaqueData opaqueData()
opaqueData
in interface TierObjectStore.ObjectStoreMetadata
public String toPath(String keyPrefix, TierObjectStore.FileType fileType)
TierObjectStore.ObjectStoreMetadata
toPath
in interface TierObjectStore.ObjectStoreMetadata
keyPrefix
- object key prefixfileType
- object file type