Class CfnTagSyncTask

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.110.0 (build 336b265)", date="2025-04-22T23:08:19.566Z") @Stability(Stable) public class CfnTagSyncTask extends CfnResource implements IInspectable
Onboards and syncs resources tagged with a specific tag key-value pair to an application.

Minimum permissions

To run this command, you must have the following permissions:

  • resource-groups:StartTagSyncTask
  • resource-groups:CreateGroup
  • iam:PassRole for the role you provide to create a tag-sync task

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.resourcegroups.*;
 CfnTagSyncTask cfnTagSyncTask = CfnTagSyncTask.Builder.create(this, "MyCfnTagSyncTask")
         .group("group")
         .roleArn("roleArn")
         .tagKey("tagKey")
         .tagValue("tagValue")
         .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

    • CfnTagSyncTask

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

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

      @Stability(Stable) public CfnTagSyncTask(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnTagSyncTaskProps 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.
    • getAttrGroupArn

      @Stability(Stable) @NotNull public String getAttrGroupArn()
      The Amazon resource name (ARN) of the application group.
    • getAttrGroupName

      @Stability(Stable) @NotNull public String getAttrGroupName()
      The name of the application group.
    • getAttrStatus

      @Stability(Stable) @NotNull public String getAttrStatus()
      The status of the tag-sync task.

      Valid values include:

      • ACTIVE - The tag-sync task is actively managing resources in the application by adding or removing the awsApplication tag from resources when they are tagged or untagged with the specified tag key-value pair.
      • ERROR - The tag-sync task is not actively managing resources in the application. Review the ErrorMessage for more information about resolving the error.
    • getAttrTaskArn

      @Stability(Stable) @NotNull public String getAttrTaskArn()
      The Amazon resource name (ARN) of the tag-sync task.
    • getCfnProperties

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

      @Stability(Stable) @NotNull public String getGroup()
      The Amazon resource name (ARN) or name of the application group for which you want to create a tag-sync task.
    • setGroup

      @Stability(Stable) public void setGroup(@NotNull String value)
      The Amazon resource name (ARN) or name of the application group for which you want to create a tag-sync task.
    • getRoleArn

      @Stability(Stable) @NotNull public String getRoleArn()
      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.
    • setRoleArn

      @Stability(Stable) public void setRoleArn(@NotNull String value)
      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.
    • getTagKey

      @Stability(Stable) @NotNull public String getTagKey()
      The tag key.
    • setTagKey

      @Stability(Stable) public void setTagKey(@NotNull String value)
      The tag key.
    • getTagValue

      @Stability(Stable) @NotNull public String getTagValue()
      The tag value.
    • setTagValue

      @Stability(Stable) public void setTagValue(@NotNull String value)
      The tag value.