Skip to content
v2.278.0

ReplicationInfoProperty Struct ​

Specifies configuration for replication between a source and target Kafka cluster.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_msk as msk } from 'aws-cdk-lib';
const replicationInfoProperty: msk.CfnReplicator.ReplicationInfoProperty = {
  consumerGroupReplication: {
    consumerGroupsToReplicate: ['consumerGroupsToReplicate'],

    // the properties below are optional
    consumerGroupOffsetSyncMode: 'consumerGroupOffsetSyncMode',
    consumerGroupsToExclude: ['consumerGroupsToExclude'],
    detectAndCopyNewConsumerGroups: false,
    synchroniseConsumerGroupOffsets: false,
  },
  targetCompressionType: 'targetCompressionType',
  topicReplication: {
    topicsToReplicate: ['topicsToReplicate'],

    // the properties below are optional
    copyAccessControlListsForTopics: false,
    copyTopicConfigurations: false,
    detectAndCopyNewTopics: false,
    startingPosition: {
      type: 'type',
    },
    topicNameConfiguration: {
      type: 'type',
    },
    topicsToExclude: ['topicsToExclude'],
  },

  // the properties below are optional
  sourceKafkaClusterArn: 'sourceKafkaClusterArn',
  sourceKafkaClusterId: 'sourceKafkaClusterId',
  targetKafkaClusterArn: 'targetKafkaClusterArn',
  targetKafkaClusterId: 'targetKafkaClusterId',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_msk as msk

replication_info_property = msk.CfnReplicator.ReplicationInfoProperty(
    consumer_group_replication=msk.CfnReplicator.ConsumerGroupReplicationProperty(
        consumer_groups_to_replicate=["consumerGroupsToReplicate"],

        # the properties below are optional
        consumer_group_offset_sync_mode="consumerGroupOffsetSyncMode",
        consumer_groups_to_exclude=["consumerGroupsToExclude"],
        detect_and_copy_new_consumer_groups=False,
        synchronise_consumer_group_offsets=False
    ),
    target_compression_type="targetCompressionType",
    topic_replication=msk.CfnReplicator.TopicReplicationProperty(
        topics_to_replicate=["topicsToReplicate"],

        # the properties below are optional
        copy_access_control_lists_for_topics=False,
        copy_topic_configurations=False,
        detect_and_copy_new_topics=False,
        starting_position=msk.CfnReplicator.ReplicationStartingPositionProperty(
            type="type"
        ),
        topic_name_configuration=msk.CfnReplicator.ReplicationTopicNameConfigurationProperty(
            type="type"
        ),
        topics_to_exclude=["topicsToExclude"]
    ),

    # the properties below are optional
    source_kafka_cluster_arn="sourceKafkaClusterArn",
    source_kafka_cluster_id="sourceKafkaClusterId",
    target_kafka_cluster_arn="targetKafkaClusterArn",
    target_kafka_cluster_id="targetKafkaClusterId"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.msk.*;

ReplicationInfoProperty replicationInfoProperty = ReplicationInfoProperty.builder()
        .consumerGroupReplication(ConsumerGroupReplicationProperty.builder()
                .consumerGroupsToReplicate(List.of("consumerGroupsToReplicate"))

                // the properties below are optional
                .consumerGroupOffsetSyncMode("consumerGroupOffsetSyncMode")
                .consumerGroupsToExclude(List.of("consumerGroupsToExclude"))
                .detectAndCopyNewConsumerGroups(false)
                .synchroniseConsumerGroupOffsets(false)
                .build())
        .targetCompressionType("targetCompressionType")
        .topicReplication(TopicReplicationProperty.builder()
                .topicsToReplicate(List.of("topicsToReplicate"))

                // the properties below are optional
                .copyAccessControlListsForTopics(false)
                .copyTopicConfigurations(false)
                .detectAndCopyNewTopics(false)
                .startingPosition(ReplicationStartingPositionProperty.builder()
                        .type("type")
                        .build())
                .topicNameConfiguration(ReplicationTopicNameConfigurationProperty.builder()
                        .type("type")
                        .build())
                .topicsToExclude(List.of("topicsToExclude"))
                .build())

        // the properties below are optional
        .sourceKafkaClusterArn("sourceKafkaClusterArn")
        .sourceKafkaClusterId("sourceKafkaClusterId")
        .targetKafkaClusterArn("targetKafkaClusterArn")
        .targetKafkaClusterId("targetKafkaClusterId")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.MSK;

var replicationInfoProperty = new ReplicationInfoProperty {
    ConsumerGroupReplication = new ConsumerGroupReplicationProperty {
        ConsumerGroupsToReplicate = new [] { "consumerGroupsToReplicate" },

        // the properties below are optional
        ConsumerGroupOffsetSyncMode = "consumerGroupOffsetSyncMode",
        ConsumerGroupsToExclude = new [] { "consumerGroupsToExclude" },
        DetectAndCopyNewConsumerGroups = false,
        SynchroniseConsumerGroupOffsets = false
    },
    TargetCompressionType = "targetCompressionType",
    TopicReplication = new TopicReplicationProperty {
        TopicsToReplicate = new [] { "topicsToReplicate" },

        // the properties below are optional
        CopyAccessControlListsForTopics = false,
        CopyTopicConfigurations = false,
        DetectAndCopyNewTopics = false,
        StartingPosition = new ReplicationStartingPositionProperty {
            Type = "type"
        },
        TopicNameConfiguration = new ReplicationTopicNameConfigurationProperty {
            Type = "type"
        },
        TopicsToExclude = new [] { "topicsToExclude" }
    },

    // the properties below are optional
    SourceKafkaClusterArn = "sourceKafkaClusterArn",
    SourceKafkaClusterId = "sourceKafkaClusterId",
    TargetKafkaClusterArn = "targetKafkaClusterArn",
    TargetKafkaClusterId = "targetKafkaClusterId"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

replicationInfoProperty := &ReplicationInfoProperty{
	ConsumerGroupReplication: &ConsumerGroupReplicationProperty{
		ConsumerGroupsToReplicate: []*string{
			jsii.String("consumerGroupsToReplicate"),
		},

		// the properties below are optional
		ConsumerGroupOffsetSyncMode: jsii.String("consumerGroupOffsetSyncMode"),
		ConsumerGroupsToExclude: []*string{
			jsii.String("consumerGroupsToExclude"),
		},
		DetectAndCopyNewConsumerGroups: jsii.Boolean(false),
		SynchroniseConsumerGroupOffsets: jsii.Boolean(false),
	},
	TargetCompressionType: jsii.String("targetCompressionType"),
	TopicReplication: &TopicReplicationProperty{
		TopicsToReplicate: []*string{
			jsii.String("topicsToReplicate"),
		},

		// the properties below are optional
		CopyAccessControlListsForTopics: jsii.Boolean(false),
		CopyTopicConfigurations: jsii.Boolean(false),
		DetectAndCopyNewTopics: jsii.Boolean(false),
		StartingPosition: &ReplicationStartingPositionProperty{
			Type: jsii.String("type"),
		},
		TopicNameConfiguration: &ReplicationTopicNameConfigurationProperty{
			Type: jsii.String("type"),
		},
		TopicsToExclude: []*string{
			jsii.String("topicsToExclude"),
		},
	},

	// the properties below are optional
	SourceKafkaClusterArn: jsii.String("sourceKafkaClusterArn"),
	SourceKafkaClusterId: jsii.String("sourceKafkaClusterId"),
	TargetKafkaClusterArn: jsii.String("targetKafkaClusterArn"),
	TargetKafkaClusterId: jsii.String("targetKafkaClusterId"),
}

Properties ​

consumerGroupReplicationIResolvable | CfnReplicator.ConsumerGroupReplicationPropertyconsumer_group_replicationtyping.Union[IResolvable, ConsumerGroupReplicationProperty]consumerGroupReplicationIResolvableConsumerGroupReplicationIResolvableConsumerGroupReplicationinterface{} required #
Configuration relating to consumer group replication.
sourceKafkaClusterArnoptionalstringsource_kafka_cluster_arnoptionalstrsourceKafkaClusterArnoptionalStringSourceKafkaClusterArnoptionalstringSourceKafkaClusterArnoptional*string #
The ARN of the source Kafka cluster.
sourceKafkaClusterIdoptionalstringsource_kafka_cluster_idoptionalstrsourceKafkaClusterIdoptionalStringSourceKafkaClusterIdoptionalstringSourceKafkaClusterIdoptional*string #
The ID of the source Kafka cluster.
targetCompressionTypestringtarget_compression_typestrtargetCompressionTypeStringTargetCompressionTypestringTargetCompressionType*string required #
The compression type to use when producing records to target cluster.
targetKafkaClusterArnoptionalstringtarget_kafka_cluster_arnoptionalstrtargetKafkaClusterArnoptionalStringTargetKafkaClusterArnoptionalstringTargetKafkaClusterArnoptional*string #
The ARN of the target Kafka cluster.
targetKafkaClusterIdoptionalstringtarget_kafka_cluster_idoptionalstrtargetKafkaClusterIdoptionalStringTargetKafkaClusterIdoptionalstringTargetKafkaClusterIdoptional*string #
The ID of the target Kafka cluster.
topicReplicationIResolvable | CfnReplicator.TopicReplicationPropertytopic_replicationtyping.Union[IResolvable, TopicReplicationProperty]topicReplicationIResolvableTopicReplicationIResolvableTopicReplicationinterface{} required #
Configuration relating to topic replication.