Class CfnConfiguration
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.msk.CfnConfiguration
- All Implemented Interfaces:
IInspectable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.89.0 (build 2f74b3e)",
date="2023-10-26T00:56:10.519Z")
@Stability(Stable)
public class CfnConfiguration
extends CfnResource
implements IInspectable
Creates a new MSK configuration.
To see an example of how to use this operation, first save the following text to a file and name the file config-file.txt .
auto.create.topics.enable = true zookeeper.connection.timeout.ms = 1000 log.roll.ms = 604800000
Now run the following Python 3.6 script in the folder where you saved config-file.txt . This script uses the properties specified in config-file.txt to create a configuration named SalesClusterConfiguration . This configuration can work with Apache Kafka versions 1.1.1 and 2.1.0.
import boto3 client = boto3.client('kafka') config_file = open('config-file.txt', 'r') server_properties = config_file.read() response = client.create_configuration( Name='SalesClusterConfiguration', Description='The configuration to use on all sales clusters.', KafkaVersions=['1.1.1', '2.1.0'], ServerProperties=server_properties
) print(response)
Example:
// 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.*;
CfnConfiguration cfnConfiguration = CfnConfiguration.Builder.create(this, "MyCfnConfiguration")
.name("name")
.serverProperties("serverProperties")
// the properties below are optional
.description("description")
.kafkaVersionsList(List.of("kafkaVersionsList"))
.latestRevision(LatestRevisionProperty.builder()
.creationTime("creationTime")
.description("description")
.revision(123)
.build())
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnConfiguration.static interfaceExample:Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnConfiguration(software.amazon.jsii.JsiiObjectRef objRef) CfnConfiguration(software.constructs.Construct scope, String id, CfnConfigurationProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe description of the configuration.Latest revision of the configuration.getName()The name of the configuration.Contents of the server.properties file.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetDescription(String value) The description of the configuration.voidsetKafkaVersionsList(List<String> value) voidsetLatestRevision(IResolvable value) Latest revision of the configuration.voidLatest revision of the configuration.voidThe name of the configuration.voidsetServerProperties(String value) Contents of the server.properties file.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnConfiguration
protected CfnConfiguration(software.amazon.jsii.JsiiObjectRef objRef) -
CfnConfiguration
protected CfnConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnConfiguration
@Stability(Stable) public CfnConfiguration(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnConfigurationProps props) - Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
-
getAttrLatestRevisionCreationTime
-
getAttrLatestRevisionDescription
-
getAttrLatestRevisionRevision
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getName
The name of the configuration. -
setName
The name of the configuration. -
getServerProperties
Contents of the server.properties file. When using the API, you must ensure that the contents of the file are base64 encoded. When using the console, the SDK, or the CLI, the contents of server.properties can be in plaintext. -
setServerProperties
Contents of the server.properties file. When using the API, you must ensure that the contents of the file are base64 encoded. When using the console, the SDK, or the CLI, the contents of server.properties can be in plaintext. -
getDescription
The description of the configuration. -
setDescription
The description of the configuration. -
getKafkaVersionsList
-
setKafkaVersionsList
-
getLatestRevision
Latest revision of the configuration. -
setLatestRevision
Latest revision of the configuration. -
setLatestRevision
@Stability(Stable) public void setLatestRevision(@Nullable CfnConfiguration.LatestRevisionProperty value) Latest revision of the configuration.
-