ResourceCleaner
This class encapsulates and extends the ROS resource type ALIYUN::ROS::ResourceCleaner
, which is used to create a resource cleaner.
Initializers
using AlibabaCloud.SDK.ROS.CDK.Ros;
new ResourceCleaner(Construct Scope, string Id, ResourceCleanerProps Props, bool EnableResourcePropertyConstraint = null);
Name | Type | Description |
---|---|---|
Scope |
AlibabaCloud.SDK.ROS.CDK.Core.Construct |
No description. |
Id |
string |
No description. |
Props |
ResourceCleanerProps |
No description. |
EnableResourcePropertyConstraint |
bool |
No description. |
Scope
Required
- Type: AlibabaCloud.SDK.ROS.CDK.Core.Construct
Id
Required
- Type: string
Props
Required
- Type: ResourceCleanerProps
EnableResourcePropertyConstraint
Optional
- Type: bool
Methods
Name | Description |
---|---|
ToString |
Returns a string representation of this construct. |
Synthesize |
Allows this construct to emit artifacts into the cloud assembly during synthesis. |
AddCondition |
No description. |
AddCount |
No description. |
AddDependency |
No description. |
AddResourceDesc |
No description. |
ApplyRemovalPolicy |
No description. |
GetAtt |
No description. |
SetMetadata |
No description. |
ToString
private string ToString()
Returns a string representation of this construct.
Synthesize
private void Synthesize(ISynthesisSession Session)
Allows this construct to emit artifacts into the cloud assembly during synthesis.
This method is usually implemented by framework-level constructs such as Stack
and Asset
as they participate in synthesizing the cloud assembly.
- Type: AlibabaCloud.SDK.ROS.CDK.Core.ISynthesisSession
The synthesis session.
AddCondition
private void AddCondition(RosCondition Condition)
- Type: AlibabaCloud.SDK.ROS.CDK.Core.RosCondition
AddCount
private void AddCount(object Count)
- Type: object
AddDependency
private void AddDependency(Resource Resource)
- Type: AlibabaCloud.SDK.ROS.CDK.Core.Resource
AddResourceDesc
private void AddResourceDesc(string Desc)
- Type: string
ApplyRemovalPolicy
private void ApplyRemovalPolicy(RemovalPolicy Policy)
- Type: AlibabaCloud.SDK.ROS.CDK.Core.RemovalPolicy
GetAtt
private IResolvable GetAtt(string Name)
- Type: string
SetMetadata
private void SetMetadata(string Key, object Value)
- Type: string
- Type: object
Static Functions
Name | Description |
---|---|
IsConstruct |
Return whether the given object is a Construct. |
IsConstruct
using AlibabaCloud.SDK.ROS.CDK.Ros;
ResourceCleaner.IsConstruct(object X);
Return whether the given object is a Construct.
- Type: object
Properties
Name | Type | Description |
---|---|---|
Node |
AlibabaCloud.SDK.ROS.CDK.Core.ConstructNode |
The construct tree node associated with this construct. |
Ref |
string |
No description. |
Stack |
AlibabaCloud.SDK.ROS.CDK.Core.Stack |
The stack in which this resource is defined. |
Resource |
AlibabaCloud.SDK.ROS.CDK.Core.RosResource |
No description. |
AttrCleanResult |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute CleanResult: The cleanup result. |
AttrNoCleanupResourceDetails |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute NoCleanupResourceDetails: The details of the resources that are scanned but filtered. |
AttrNoCleanupResourcePartialDetails |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute NoCleanupResourcePartialDetails: The partial details of the resources that are scanned but filtered. |
AttrResourceDetails |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute ResourceDetails: The details of resources to be cleaned up. |
AttrResourcePartialDetails |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute ResourcePartialDetails: The partial details of resources to be cleaned up. |
AttrResourceSummary |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute ResourceSummary: The details of resources to be cleaned up. |
AttrScanErrors |
AlibabaCloud.SDK.ROS.CDK.Core.IResolvable |
Attribute ScanErrors: The scan errors. |
Node
Required
public ConstructNode Node { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.ConstructNode
The construct tree node associated with this construct.
Ref
Required
public string Ref { get; }
- Type: string
Stack
Required
public Stack Stack { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.Stack
The stack in which this resource is defined.
Resource
Optional
public RosResource Resource { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.RosResource
AttrCleanResult
Required
public IResolvable AttrCleanResult { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute CleanResult: The cleanup result.
Valid values:
- Success: All resources are cleaned up successfully.
- ResourceFailure: Partial resources fail to clean up.
- Timeout: Timeout to clean up.
- CheckFailure: Pre check of cleanup fails.
- UnknownFailure: Unexpected failure.
- UserCancelled: Cleanup is cancelled by user.
- None: Cleanup is not triggered.
AttrNoCleanupResourceDetails
Required
public IResolvable AttrNoCleanupResourceDetails { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute NoCleanupResourceDetails: The details of the resources that are scanned but filtered.
Only resources with the resource types ResourceCleaner supports and the regions not filtered are scanned. The format is the same as ResourceDetails.
AttrNoCleanupResourcePartialDetails
Required
public IResolvable AttrNoCleanupResourcePartialDetails { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute NoCleanupResourcePartialDetails: The partial details of the resources that are scanned but filtered.
Only resources with the resource types ResourceCleaner supports and the regions not filtered are scanned. The format is the same as ResourcePartialDetails.
AttrResourceDetails
Required
public IResolvable AttrResourceDetails { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute ResourceDetails: The details of resources to be cleaned up.
The value is a list of dict. The dict contains the fields below:
- ResourceType: Resource type of the resource.
- RegionId: Region ID of the resource.
- ResourceId: ID of the resource.
- ResourceName: Name of the resource.
- CleanupType: Cleanup type of the resource. Valid values:
- Normal: The resource can be deleted normally.
- DeleteWithInstance: The resource will be deleted with the resource it belongs to. If the resource it belongs to is filtered or excluded, the deletion probably fails. CleanupTypeReasons give more information.
- UnableToDelete: Unable to delete the resource. CleanupTypeReasons give more information.
- CleanupTypeReasons: The information of the related CleanupType.
- ResourceStatus: Status of the resource. Valid values:
- Deleting: The resource is deleting.
- Failure: The deletion of the resource failed.
- Success: The resource is deleted.
- Skipped: The deletion of the resource is skipped.
- Pending: The deletion of the resource is not started.
- ResourceStatusReason: The information of the related ResourceStatus.
- Dependencies: The resources that need to be deleted before the deletion of the resource. The value is a list of dict. The dict contains the fields below:
- ResourceType: Resource type of the dependency resource.
- RegionId: Region ID of the dependency resource.
- ResourceId: ID of the dependency resource.
AttrResourcePartialDetails
Required
public IResolvable AttrResourcePartialDetails { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute ResourcePartialDetails: The partial details of resources to be cleaned up.
The value is a list of dict. The dict contains the fields below:
- ResourceType: Resource type of the resource.
- RegionId: Region ID of the resource.
- ResourceId: ID of the resource.
- ResourceName: Name of the resource.
- ResourceStatus: Status of the resource. Valid values:
- Deleting: The resource is deleting.
- Failure: The deletion of the resource failed.
- Success: The resource is deleted.
- Skipped: The deletion of the resource is skipped.
- Pending: The deletion of the resource is not started.
- ResourceStatusReason: The information of the related ResourceStatus.
AttrResourceSummary
Required
public IResolvable AttrResourceSummary { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute ResourceSummary: The details of resources to be cleaned up.
The value is a list of dict. The dict contains the fields below:
- ResourceType: Resource type of the resources.
- DeletingCount: Number of deleting resources of the resource type.
- SuccessCount: Number of deleted resources of the resource type.
- FailureCount: Number of resources that failed to delete of the resource type.
- SkippedCount: Number of skipped resources of the resource type.
- PendingCount: Number of resources that have not been deleted of the resource type.
- OtherCount: Number of other resources of the resource type.
- TotalCount: Number of total resources of the resource type.
AttrScanErrors
Required
public IResolvable AttrScanErrors { get; }
- Type: AlibabaCloud.SDK.ROS.CDK.Core.IResolvable
Attribute ScanErrors: The scan errors.
It takes effect only when property Mode is Loose. The value is a list of dict. The dict contains the fields below:
- ResourceType: Resource type for scanning.
- RegionId: Region ID for scanning.
- ErrorMessage: Error message of scanning with specified resource type and region ID.