Package org.apache.kafka.clients.admin
Class NewMirrorTopic
java.lang.Object
org.apache.kafka.clients.admin.NewMirrorTopic
Supplemental new topic data for creating a topic that is a mirror of another.
Constructor Summary
ConstructorsConstructorDescriptionNewMirrorTopic(String linkName, String sourceTopic) Prepares a new topic that mirrors its data from a source topic, starting from the earliest available offsets of the partitions.NewMirrorTopic(String linkName, String sourceTopic, OffsetSpec startOffsetSpec) Prepares a new topic that mirrors its data from a source topic, starting from the offsets determined by the providedstartOffsetSpec.Method Summary
Modifier and TypeMethodDescriptionbooleaninthashCode()linkName()The name of the cluster link over which the topic will mirror from.Deprecated.This method is being deprecated because mirrorTopic is not an accurate name to describe a method that returns the source topic's name.The name of the topic to be mirrored over the cluster link, i.e.toString()
Constructor Details
NewMirrorTopic
Prepares a new topic that mirrors its data from a source topic, starting from the earliest available offsets of the partitions.- Parameters:
linkName- the name of the cluster link over which the topic will mirror fromsourceTopic- the name of the topic to be mirrored over the cluster link
NewMirrorTopic
Prepares a new topic that mirrors its data from a source topic, starting from the offsets determined by the providedstartOffsetSpec.- Parameters:
linkName- the name of the cluster link over which the topic will mirror fromsourceTopic- the name of the topic to be mirrored over the cluster linkstartOffsetSpec- the offset spec used to determine the first offset from which each partition will be mirrored. By default, mirroring starts from the first available offset for each source partition. A start offset spec can be provided to start mirroring from the latest offset or offset with a specified timestamp.
Method Details
linkName
The name of the cluster link over which the topic will mirror from.mirrorTopic
Deprecated.This method is being deprecated because mirrorTopic is not an accurate name to describe a method that returns the source topic's name.Use
sourceTopic()} instead.The name of the topic to be mirrored over the cluster link, i.e. the source topic's name.sourceTopic
The name of the topic to be mirrored over the cluster link, i.e. the source topic's name.startOffsetSpec
toString
equals
hashCode
public int hashCode()