Interface LifecyclePolicyResourceSelection
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
LifecyclePolicyResourceSelection.Jsii$Proxy
@Generated(value="jsii-pacmak/1.120.0 (build 192dc88)",
date="2025-12-05T22:26:50.095Z")
@Stability(Experimental)
public interface LifecyclePolicyResourceSelection
extends software.amazon.jsii.JsiiSerializable
(experimental) Selection criteria for the resources that the lifecycle policy applies to.
Example:
LifecyclePolicy disabledPolicy = LifecyclePolicy.Builder.create(this, "DisabledPolicy")
.lifecyclePolicyName("my-disabled-policy")
.description("A lifecycle policy that is temporarily disabled")
.status(LifecyclePolicyStatus.DISABLED)
.resourceType(LifecyclePolicyResourceType.AMI_IMAGE)
.details(List.of(LifecyclePolicyDetail.builder()
.action(LifecyclePolicyAction.builder().type(LifecyclePolicyActionType.DELETE).build())
.filter(LifecyclePolicyFilter.builder().ageFilter(LifecyclePolicyAgeFilter.builder().age(Duration.days(30)).build()).build())
.build()))
.resourceSelection(LifecyclePolicyResourceSelection.builder()
.tags(Map.of("Environment", "testing"))
.build())
.tags(Map.of(
"Owner", "DevOps",
"CostCenter", "Engineering"))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forLifecyclePolicyResourceSelectionstatic final classAn implementation forLifecyclePolicyResourceSelection -
Method Summary
Modifier and TypeMethodDescriptionbuilder()default List<IRecipeBase> (experimental) The list of image recipes or container recipes to apply the lifecycle policy to.getTags()(experimental) Selects EC2 Image Builder images containing any of the provided tags.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getRecipes
(experimental) The list of image recipes or container recipes to apply the lifecycle policy to.Default: - none if tag selections are provided. Otherwise, at least one recipe or tag selection must be provided
-
getTags
(experimental) Selects EC2 Image Builder images containing any of the provided tags.Default: - none if recipe selections are provided. Otherwise, at least one recipe or tag selection must be provided
-
builder
-