SnapshotManagementProperty
- class aws_cdk.aws_s3tables_alpha.SnapshotManagementProperty(*, max_snapshot_age_hours=None, min_snapshots_to_keep=None, status=None)
Bases:
object
(experimental) Contains details about the snapshot management settings for an Iceberg table.
A snapshot is expired when it exceeds MinSnapshotsToKeep and MaxSnapshotAgeHours.
- Parameters:
max_snapshot_age_hours (
Union
[int
,float
,None
]) – (experimental) The maximum age of a snapshot before it can be expired. Default: - No maximum agemin_snapshots_to_keep (
Union
[int
,float
,None
]) – (experimental) The minimum number of snapshots to keep. Default: - No minimum numberstatus (
Optional
[Status
]) – (experimental) Indicates whether the SnapshotManagement maintenance action is enabled. Default: - Not specified
- Default:
No snapshot management settings
- Stability:
experimental
- ExampleMetadata:
infused
Example:
# Build a table sample_table = Table(scope, "ExampleTable", table_name="example_table", namespace=namespace, open_table_format=OpenTableFormat.ICEBERG, without_metadata=True ) # Build a table with an Iceberg Schema sample_table_with_schema = Table(scope, "ExampleSchemaTable", table_name="example_table_with_schema", namespace=namespace, open_table_format=OpenTableFormat.ICEBERG, iceberg_metadata=IcebergMetadataProperty( iceberg_schema=IcebergSchemaProperty( schema_field_list=[SchemaFieldProperty( name="id", type="int", required=True ), SchemaFieldProperty( name="name", type="string" ) ] ) ), compaction=CompactionProperty( status=Status.ENABLED, target_file_size_mb=128 ), snapshot_management=SnapshotManagementProperty( status=Status.ENABLED, max_snapshot_age_hours=48, min_snapshots_to_keep=5 ) )
Attributes
- max_snapshot_age_hours
(experimental) The maximum age of a snapshot before it can be expired.
- Default:
No maximum age
- Stability:
experimental
- min_snapshots_to_keep
(experimental) The minimum number of snapshots to keep.
- Default:
No minimum number
- Stability:
experimental
- status
(experimental) Indicates whether the SnapshotManagement maintenance action is enabled.
- Default:
Not specified
- Stability:
experimental