Class CfnConfigurationRecorder

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.98.0 (build 00b106d)", date="2024-05-24T02:42:35.794Z") @Stability(Stable) public class CfnConfigurationRecorder extends CfnResource implements IInspectable
The AWS::Config::ConfigurationRecorder resource type describes the AWS resource types that AWS Config records for configuration changes.

The configuration recorder stores the configuration changes of the specified resources in your account as configuration items.

To enable AWS Config , you must create a configuration recorder and a delivery channel.

AWS Config uses the delivery channel to deliver the configuration changes to your Amazon S3 bucket or Amazon SNS topic. For more information, see AWS::Config::DeliveryChannel .

AWS CloudFormation starts the recorder as soon as the delivery channel is available.

To stop the recorder and delete it, delete the configuration recorder from your stack. To stop the recorder without deleting it, call the StopConfigurationRecorder action of the AWS Config API directly.

For more information, see Configuration Recorder in the AWS Config Developer Guide.

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.config.*;
 CfnConfigurationRecorder cfnConfigurationRecorder = CfnConfigurationRecorder.Builder.create(this, "MyCfnConfigurationRecorder")
         .roleArn("roleArn")
         // the properties below are optional
         .name("name")
         .recordingGroup(RecordingGroupProperty.builder()
                 .allSupported(false)
                 .exclusionByResourceTypes(ExclusionByResourceTypesProperty.builder()
                         .resourceTypes(List.of("resourceTypes"))
                         .build())
                 .includeGlobalResourceTypes(false)
                 .recordingStrategy(RecordingStrategyProperty.builder()
                         .useOnly("useOnly")
                         .build())
                 .resourceTypes(List.of("resourceTypes"))
                 .build())
         .recordingMode(RecordingModeProperty.builder()
                 .recordingFrequency("recordingFrequency")
                 // the properties below are optional
                 .recordingModeOverrides(List.of(RecordingModeOverrideProperty.builder()
                         .recordingFrequency("recordingFrequency")
                         .resourceTypes(List.of("resourceTypes"))
                         // the properties below are optional
                         .description("description")
                         .build()))
                 .build())
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnConfigurationRecorder

      protected CfnConfigurationRecorder(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnConfigurationRecorder

      protected CfnConfigurationRecorder(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnConfigurationRecorder

      @Stability(Stable) public CfnConfigurationRecorder(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnConfigurationRecorderProps 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

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      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:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrId

      @Stability(Stable) @NotNull public String getAttrId()
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getRoleArn

      @Stability(Stable) @NotNull public String getRoleArn()
      Amazon Resource Name (ARN) of the IAM role assumed by AWS Config and used by the configuration recorder.
    • setRoleArn

      @Stability(Stable) public void setRoleArn(@NotNull String value)
      Amazon Resource Name (ARN) of the IAM role assumed by AWS Config and used by the configuration recorder.
    • getName

      @Stability(Stable) @Nullable public String getName()
      The name of the configuration recorder.

      AWS Config automatically assigns the name of "default" when creating the configuration recorder.

    • setName

      @Stability(Stable) public void setName(@Nullable String value)
      The name of the configuration recorder.

      AWS Config automatically assigns the name of "default" when creating the configuration recorder.

    • getRecordingGroup

      @Stability(Stable) @Nullable public Object getRecordingGroup()
      Specifies which resource types AWS Config records for configuration changes.
    • setRecordingGroup

      @Stability(Stable) public void setRecordingGroup(@Nullable IResolvable value)
      Specifies which resource types AWS Config records for configuration changes.
    • setRecordingGroup

      @Stability(Stable) public void setRecordingGroup(@Nullable CfnConfigurationRecorder.RecordingGroupProperty value)
      Specifies which resource types AWS Config records for configuration changes.
    • getRecordingMode

      @Stability(Stable) @Nullable public Object getRecordingMode()
      Specifies the default recording frequency that AWS Config uses to record configuration changes.
    • setRecordingMode

      @Stability(Stable) public void setRecordingMode(@Nullable IResolvable value)
      Specifies the default recording frequency that AWS Config uses to record configuration changes.
    • setRecordingMode

      @Stability(Stable) public void setRecordingMode(@Nullable CfnConfigurationRecorder.RecordingModeProperty value)
      Specifies the default recording frequency that AWS Config uses to record configuration changes.