interface TableProps
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.S3Tables.Alpha.TableProps |
![]() | software.amazon.awscdk.services.s3tables.alpha.TableProps |
![]() | aws_cdk.aws_s3tables_alpha.TableProps |
![]() | @aws-cdk/aws-s3tables-alpha ยป TableProps |
Properties for creating a new S3 Table.
Example
// Build a table
const sampleTable = new Table(scope, 'ExampleTable', {
tableName: 'example_table',
namespace: namespace,
openTableFormat: OpenTableFormat.ICEBERG,
withoutMetadata: true,
});
// Build a table with an Iceberg Schema
const sampleTableWithSchema = new Table(scope, 'ExampleSchemaTable', {
tableName: 'example_table_with_schema',
namespace: namespace,
openTableFormat: OpenTableFormat.ICEBERG,
icebergMetadata: {
icebergSchema: {
schemaFieldList: [
{
name: 'id',
type: 'int',
required: true,
},
{
name: 'name',
type: 'string',
},
],
},
},
compaction: {
status: Status.ENABLED,
targetFileSizeMb: 128,
},
snapshotManagement: {
status: Status.ENABLED,
maxSnapshotAgeHours: 48,
minSnapshotsToKeep: 5,
},
});
Properties
Name | Type | Description |
---|---|---|
namespace | INamespace | The namespace under which this table is created. |
open | Open | Format of this table. |
table | string | Name of this table, unique within the namespace. |
compaction? | Compaction | Settings governing the Compaction maintenance action. |
iceberg | Iceberg | Contains details about the metadata for an Iceberg table. |
removal | Removal | Controls what happens to this table it it stoped being managed by cloudformation. |
snapshot | Snapshot | Contains details about the snapshot management settings for an Iceberg table. |
without | boolean | If true, indicates that you don't want to specify a schema for the table. |
namespace
Type:
INamespace
The namespace under which this table is created.
openTableFormat
Type:
Open
Format of this table.
Currently, the only supported value is OpenTableFormat.ICEBERG.
tableName
Type:
string
Name of this table, unique within the namespace.
compaction?
Type:
Compaction
(optional, default: Amazon S3 selects the best compaction strategy based on your table sort order.)
Settings governing the Compaction maintenance action.
See also: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-tables-maintenance.html
icebergMetadata?
Type:
Iceberg
(optional, default: table is created without any metadata)
Contains details about the metadata for an Iceberg table.
removalPolicy?
Type:
Removal
(optional, default: RETAIN)
Controls what happens to this table it it stoped being managed by cloudformation.
snapshotManagement?
Type:
Snapshot
(optional, default: enabled: MinimumSnapshots is 1 by default and MaximumSnapshotAge is 120 hours by default.)
Contains details about the snapshot management settings for an Iceberg table.
withoutMetadata?
Type:
boolean
(optional, default: false)
If true, indicates that you don't want to specify a schema for the table.
This property is mutually exclusive to 'IcebergMetadata'.