Class: AWSCDK::Glue::CfnTable::TableInputProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Glue::CfnTable::TableInputProperty
- Defined in:
- glue/cfn_table.rb
Overview
A structure used to define a table.
Instance Attribute Summary collapse
-
#description ⇒ String?
readonly
A description of the table.
-
#name ⇒ String?
readonly
The table name.
-
#owner ⇒ String?
readonly
The table owner.
-
#parameters ⇒ Object?
readonly
These key-value pairs define properties associated with the table.
-
#partition_keys ⇒ AWSCDK::IResolvable, ...
readonly
A list of columns by which the table is partitioned.
-
#retention ⇒ Numeric?
readonly
The retention time for this table.
-
#storage_descriptor ⇒ AWSCDK::IResolvable, ...
readonly
A storage descriptor containing information about the physical storage of this table.
-
#table_type ⇒ String?
readonly
The type of this table.
-
#target_table ⇒ AWSCDK::IResolvable, ...
readonly
A
TableIdentifierstructure that describes a target table for resource linking. - #view_definition ⇒ AWSCDK::IResolvable, ... readonly
-
#view_expanded_text ⇒ String?
readonly
Included for Apache Hive compatibility.
-
#view_original_text ⇒ String?
readonly
Included for Apache Hive compatibility.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(description: nil, name: nil, owner: nil, parameters: nil, partition_keys: nil, retention: nil, storage_descriptor: nil, table_type: nil, target_table: nil, view_definition: nil, view_expanded_text: nil, view_original_text: nil) ⇒ TableInputProperty
constructor
A new instance of TableInputProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(description: nil, name: nil, owner: nil, parameters: nil, partition_keys: nil, retention: nil, storage_descriptor: nil, table_type: nil, target_table: nil, view_definition: nil, view_expanded_text: nil, view_original_text: nil) ⇒ TableInputProperty
Returns a new instance of TableInputProperty.
1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 |
# File 'glue/cfn_table.rb', line 1549 def initialize(description: nil, name: nil, owner: nil, parameters: nil, partition_keys: nil, retention: nil, storage_descriptor: nil, table_type: nil, target_table: nil, view_definition: nil, view_expanded_text: nil, view_original_text: nil) @description = description Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil? @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") unless @name.nil? @owner = owner Jsii::Type.check_type(@owner, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "owner") unless @owner.nil? @parameters = parameters Jsii::Type.check_type(@parameters, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "parameters") unless @parameters.nil? @partition_keys = partition_keys Jsii::Type.check_type(@partition_keys, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZ2x1ZS5DZm5UYWJsZS5Db2x1bW5Qcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "partitionKeys") unless @partition_keys.nil? @retention = retention Jsii::Type.check_type(@retention, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "retention") unless @retention.nil? @storage_descriptor = storage_descriptor.is_a?(Hash) ? ::AWSCDK::Glue::CfnTable::StorageDescriptorProperty.new(**storage_descriptor.transform_keys(&:to_sym)) : storage_descriptor Jsii::Type.check_type(@storage_descriptor, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19nbHVlLkNmblRhYmxlLlN0b3JhZ2VEZXNjcmlwdG9yUHJvcGVydHkifV19fQ==")), "storageDescriptor") unless @storage_descriptor.nil? @table_type = table_type Jsii::Type.check_type(@table_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "tableType") unless @table_type.nil? @target_table = target_table.is_a?(Hash) ? ::AWSCDK::Glue::CfnTable::TableIdentifierProperty.new(**target_table.transform_keys(&:to_sym)) : target_table Jsii::Type.check_type(@target_table, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19nbHVlLkNmblRhYmxlLlRhYmxlSWRlbnRpZmllclByb3BlcnR5In1dfX0=")), "targetTable") unless @target_table.nil? @view_definition = view_definition.is_a?(Hash) ? ::AWSCDK::Glue::CfnTable::ViewDefinitionProperty.new(**view_definition.transform_keys(&:to_sym)) : view_definition Jsii::Type.check_type(@view_definition, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19nbHVlLkNmblRhYmxlLlZpZXdEZWZpbml0aW9uUHJvcGVydHkifV19fQ==")), "viewDefinition") unless @view_definition.nil? @view_expanded_text = Jsii::Type.check_type(@view_expanded_text, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "viewExpandedText") unless @view_expanded_text.nil? @view_original_text = view_original_text Jsii::Type.check_type(@view_original_text, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "viewOriginalText") unless @view_original_text.nil? end |
Instance Attribute Details
#description ⇒ String? (readonly)
A description of the table.
1580 1581 1582 |
# File 'glue/cfn_table.rb', line 1580 def description @description end |
#name ⇒ String? (readonly)
The table name.
For Hive compatibility, this is folded to lowercase when it is stored.
1587 1588 1589 |
# File 'glue/cfn_table.rb', line 1587 def name @name end |
#owner ⇒ String? (readonly)
The table owner.
Included for Apache Hive compatibility. Not used in the normal course of AWS Glue operations.
1594 1595 1596 |
# File 'glue/cfn_table.rb', line 1594 def owner @owner end |
#parameters ⇒ Object? (readonly)
These key-value pairs define properties associated with the table.
1599 1600 1601 |
# File 'glue/cfn_table.rb', line 1599 def parameters @parameters end |
#partition_keys ⇒ AWSCDK::IResolvable, ... (readonly)
A list of columns by which the table is partitioned. Only primitive types are supported as partition keys.
When you create a table used by Amazon Athena, and you do not specify any partition_keys , you must at least set the value of partition_keys to an empty list. For example:
"PartitionKeys": []
1608 1609 1610 |
# File 'glue/cfn_table.rb', line 1608 def partition_keys @partition_keys end |
#retention ⇒ Numeric? (readonly)
The retention time for this table.
1613 1614 1615 |
# File 'glue/cfn_table.rb', line 1613 def retention @retention end |
#storage_descriptor ⇒ AWSCDK::IResolvable, ... (readonly)
A storage descriptor containing information about the physical storage of this table.
1618 1619 1620 |
# File 'glue/cfn_table.rb', line 1618 def storage_descriptor @storage_descriptor end |
#table_type ⇒ String? (readonly)
The type of this table.
AWS Glue will create tables with the EXTERNAL_TABLE type. Other services, such as Athena, may create tables with additional table types.
AWS Glue related table types:
- EXTERNAL_TABLE - Hive compatible attribute - indicates a non-Hive managed table.
- GOVERNED - Used by AWS Lake Formation . The AWS Glue Data Catalog understands
GOVERNED.
1630 1631 1632 |
# File 'glue/cfn_table.rb', line 1630 def table_type @table_type end |
#target_table ⇒ AWSCDK::IResolvable, ... (readonly)
A TableIdentifier structure that describes a target table for resource linking.
1635 1636 1637 |
# File 'glue/cfn_table.rb', line 1635 def target_table @target_table end |
#view_definition ⇒ AWSCDK::IResolvable, ... (readonly)
1638 1639 1640 |
# File 'glue/cfn_table.rb', line 1638 def view_definition @view_definition end |
#view_expanded_text ⇒ String? (readonly)
Included for Apache Hive compatibility.
Not used in the normal course of AWS Glue operations.
1645 1646 1647 |
# File 'glue/cfn_table.rb', line 1645 def @view_expanded_text end |
#view_original_text ⇒ String? (readonly)
Included for Apache Hive compatibility.
Not used in the normal course of AWS Glue operations. If the table is a VIRTUAL_VIEW , certain Athena configuration encoded in base64.
1652 1653 1654 |
# File 'glue/cfn_table.rb', line 1652 def view_original_text @view_original_text end |
Class Method Details
.jsii_properties ⇒ Object
1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 |
# File 'glue/cfn_table.rb', line 1654 def self.jsii_properties { :description => "description", :name => "name", :owner => "owner", :parameters => "parameters", :partition_keys => "partitionKeys", :retention => "retention", :storage_descriptor => "storageDescriptor", :table_type => "tableType", :target_table => "targetTable", :view_definition => "viewDefinition", :view_expanded_text => "viewExpandedText", :view_original_text => "viewOriginalText", } end |
Instance Method Details
#to_jsii ⇒ Object
1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 |
# File 'glue/cfn_table.rb', line 1671 def to_jsii result = {} result.merge!({ "description" => @description, "name" => @name, "owner" => @owner, "parameters" => @parameters, "partitionKeys" => @partition_keys, "retention" => @retention, "storageDescriptor" => @storage_descriptor, "tableType" => @table_type, "targetTable" => @target_table, "viewDefinition" => @view_definition, "viewExpandedText" => @view_expanded_text, "viewOriginalText" => @view_original_text, }) result.compact end |