awscdkgluealpha

package module
v2.139.0-alpha.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 16 Imported by: 1

README

AWS Glue Construct Library

---

The APIs of higher level constructs in this module are experimental and under active development. They are subject to non-backward compatible changes or removal in any future version. These are not subject to the Semantic Versioning model and breaking changes will be announced in the release notes. This means that while you may use them, you may need to update your source code when upgrading to a newer version of this package.


This module is part of the AWS Cloud Development Kit project.

Job

A Job encapsulates a script that connects to data sources, processes them, and then writes output to a data target.

There are 3 types of jobs supported by AWS Glue: Spark ETL, Spark Streaming, and Python Shell jobs.

The glue.JobExecutable allows you to specify the type of job, the language to use and the code assets required by the job.

glue.Code allows you to refer to the different code assets required by the job, either from an existing S3 location or from a local file path.

glue.ExecutionClass allows you to specify FLEX or STANDARD. FLEX is appropriate for non-urgent jobs such as pre-production jobs, testing, and one-time data loads.

Spark Jobs

These jobs run in an Apache Spark environment managed by AWS Glue.

ETL Jobs

An ETL job processes data in batches using Apache Spark.

var bucket bucket

glue.NewJob(this, jsii.String("ScalaSparkEtlJob"), &JobProps{
	Executable: glue.JobExecutable_ScalaEtl(&ScalaJobExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		Script: glue.Code_FromBucket(bucket, jsii.String("src/com/example/HelloWorld.scala")),
		ClassName: jsii.String("com.example.HelloWorld"),
		ExtraJars: []code{
			glue.*code_*FromBucket(bucket, jsii.String("jars/HelloWorld.jar")),
		},
	}),
	WorkerType: glue.WorkerType_G_8X(),
	Description: jsii.String("an example Scala ETL job"),
})
Streaming Jobs

A Streaming job is similar to an ETL job, except that it performs ETL on data streams. It uses the Apache Spark Structured Streaming framework. Some Spark job features are not available to streaming ETL jobs.

glue.NewJob(this, jsii.String("PythonSparkStreamingJob"), &JobProps{
	Executable: glue.JobExecutable_PythonStreaming(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
	Description: jsii.String("an example Python Streaming job"),
})
Python Shell Jobs

A Python shell job runs Python scripts as a shell and supports a Python version that depends on the AWS Glue version you are using. This can be used to schedule and run tasks that don't require an Apache Spark environment. Currently, three flavors are supported:

  • PythonVersion.TWO (2.7; EOL)
  • PythonVersion.THREE (3.6)
  • PythonVersion.THREE_NINE (3.9)
var bucket bucket

glue.NewJob(this, jsii.String("PythonShellJob"), &JobProps{
	Executable: glue.JobExecutable_PythonShell(&PythonShellExecutableProps{
		GlueVersion: glue.GlueVersion_V1_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromBucket(bucket, jsii.String("script.py")),
	}),
	Description: jsii.String("an example Python Shell job"),
})
Ray Jobs

These jobs run in a Ray environment managed by AWS Glue.

glue.NewJob(this, jsii.String("RayJob"), &JobProps{
	Executable: glue.JobExecutable_PythonRay(&PythonRayExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		PythonVersion: glue.PythonVersion_THREE_NINE,
		Runtime: glue.Runtime_RAY_TWO_FOUR(),
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
	WorkerType: glue.WorkerType_Z_2X(),
	WorkerCount: jsii.Number(2),
	Description: jsii.String("an example Ray job"),
})
Enable Spark UI

Enable Spark UI setting the sparkUI property.

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

The sparkUI property also allows the specification of an s3 bucket and a bucket prefix.

See documentation for more information on adding jobs in Glue.

Connection

A Connection allows Glue jobs, crawlers and development endpoints to access certain types of data stores. For example, to create a network connection to connect to a data source within a VPC:

var securityGroup securityGroup
var subnet subnet

glue.NewConnection(this, jsii.String("MyConnection"), &ConnectionProps{
	Type: glue.ConnectionType_NETWORK(),
	// The security groups granting AWS Glue inbound access to the data source within the VPC
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	// The VPC subnet which contains the data source
	Subnet: Subnet,
})

For RDS Connection by JDBC, it is recommended to manage credentials using AWS Secrets Manager. To use Secret, specify SECRET_ID in properties like the following code. Note that in this case, the subnet must have a route to the AWS Secrets Manager VPC endpoint or to the AWS Secrets Manager endpoint through a NAT gateway.

var securityGroup securityGroup
var subnet subnet
var db databaseCluster

glue.NewConnection(this, jsii.String("RdsConnection"), &ConnectionProps{
	Type: glue.ConnectionType_JDBC(),
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	Subnet: Subnet,
	Properties: map[string]*string{
		"JDBC_CONNECTION_URL": fmt.Sprintf("jdbc:mysql://%v/databasename", db.clusterEndpoint.socketAddress),
		"JDBC_ENFORCE_SSL": jsii.String("false"),
		"SECRET_ID": db.secret.secretName,
	},
})

If you need to use a connection type that doesn't exist as a static member on ConnectionType, you can instantiate a ConnectionType object, e.g: new glue.ConnectionType('NEW_TYPE').

See Adding a Connection to Your Data Store and Connection Structure documentation for more information on the supported data stores and their configurations.

SecurityConfiguration

A SecurityConfiguration is a set of security properties that can be used by AWS Glue to encrypt data at rest.

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

By default, a shared KMS key is created for use with the encryption configurations that require one. You can also supply your own key for each encryption config, for example, for CloudWatch encryption:

var key key

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
		KmsKey: key,
	},
})

See documentation for more info for Glue encrypting data written by Crawlers, Jobs, and Development Endpoints.

Database

A Database is a logical grouping of Tables in the Glue Catalog.

glue.NewDatabase(this, jsii.String("MyDatabase"), &DatabaseProps{
	DatabaseName: jsii.String("my_database"),
	Description: jsii.String("my_database_description"),
})

Table

A Glue table describes a table of data in S3: its structure (column names and types), location of data (S3 objects with a common prefix in a S3 bucket), and format for the files (Json, Avro, Parquet, etc.):

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
		&column{
			Name: jsii.String("col2"),
			Type: glue.Schema_Array(glue.Schema_STRING()),
			Comment: jsii.String("col2 is an array of strings"),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

By default, a S3 bucket will be created to store the table's data but you can manually pass the bucket and s3Prefix:

var myBucket bucket
var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Bucket: myBucket,
	S3Prefix: jsii.String("my-table/"),
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Glue tables can be configured to contain user-defined properties, to describe the physical storage of table data, through the storageParameters property:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	StorageParameters: []storageParameter{
		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
		glue.*storageParameter_Custom(jsii.String("separatorChar"), jsii.String(",")),
	},
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Glue tables can also be configured to contain user-defined table properties through the parameters property:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Parameters: map[string]*string{
		"key1": jsii.String("val1"),
		"key2": jsii.String("val2"),
	},
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})
Partition Keys

To improve query performance, a table can specify partitionKeys on which data is stored and queried separately. For example, you might partition a table by year and month to optimize queries based on a time window:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})
Partition Indexes

Another way to improve query performance is to specify partition indexes. If no partition indexes are present on the table, AWS Glue loads all partitions of the table and filters the loaded partitions using the query expression. The query takes more time to run as the number of partitions increase. With an index, the query will try to fetch a subset of the partitions instead of loading all partitions of the table.

The keys of a partition index must be a subset of the partition keys of the table. You can have a maximum of 3 partition indexes per table. To specify a partition index, you can use the partitionIndexes property:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	PartitionIndexes: []partitionIndex{
		&partitionIndex{
			IndexName: jsii.String("my-index"),
			 // optional
			KeyNames: []*string{
				jsii.String("year"),
			},
		},
	},
	 // supply up to 3 indexes
	DataFormat: glue.DataFormat_JSON(),
})

Alternatively, you can call the addPartitionIndex() function on a table:

var myTable table

myTable.AddPartitionIndex(&PartitionIndex{
	IndexName: jsii.String("my-index"),
	KeyNames: []*string{
		jsii.String("year"),
	},
})
Partition Filtering

If you have a table with a large number of partitions that grows over time, consider using AWS Glue partition indexing and filtering.

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
	EnablePartitionFiltering: jsii.Boolean(true),
})
Glue Connections

Glue connections allow external data connections to third party databases and data warehouses. However, these connections can also be assigned to Glue Tables, allowing you to query external data sources using the Glue Data Catalog.

Whereas S3Table will point to (and if needed, create) a bucket to store the tables' data, ExternalTable will point to an existing table in a data source. For example, to create a table in Glue that points to a table in Redshift:

var myConnection connection
var myDatabase database

glue.NewExternalTable(this, jsii.String("MyTable"), &ExternalTableProps{
	Connection: myConnection,
	ExternalDataLocation: jsii.String("default_db_public_example"),
	 // A table in Redshift
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Encryption

You can enable encryption on a Table's data:

  • S3Managed - (default) Server side encryption (SSE-S3) with an Amazon S3-managed key.
var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_S3_MANAGED,
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})
  • Kms - Server-side encryption (SSE-KMS) with an AWS KMS Key managed by the account owner.
var myDatabase database

// KMS key is created automatically
// KMS key is created automatically
glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_KMS,
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

// with an explicit KMS key
// with an explicit KMS key
glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_KMS,
	EncryptionKey: kms.NewKey(this, jsii.String("MyKey")),
	// ...
	Database: myDatabase,
	Columns: []*column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})
  • KmsManaged - Server-side encryption (SSE-KMS), like Kms, except with an AWS KMS Key managed by the AWS Key Management Service.
var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_KMS_MANAGED,
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})
  • ClientSideKms - Client-side encryption (CSE-KMS) with an AWS KMS Key managed by the account owner.
var myDatabase database

// KMS key is created automatically
// KMS key is created automatically
glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_CLIENT_SIDE_KMS,
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

// with an explicit KMS key
// with an explicit KMS key
glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_CLIENT_SIDE_KMS,
	EncryptionKey: kms.NewKey(this, jsii.String("MyKey")),
	// ...
	Database: myDatabase,
	Columns: []*column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Note: you cannot provide a Bucket when creating the S3Table if you wish to use server-side encryption (KMS, KMS_MANAGED or S3_MANAGED).

Types

A table's schema is a collection of columns, each of which have a name and a type. Types are recursive structures, consisting of primitive and complex types:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Columns: []column{
		&column{
			Name: jsii.String("primitive_column"),
			Type: glue.Schema_STRING(),
		},
		&column{
			Name: jsii.String("array_column"),
			Type: glue.Schema_Array(glue.Schema_INTEGER()),
			Comment: jsii.String("array<integer>"),
		},
		&column{
			Name: jsii.String("map_column"),
			Type: glue.Schema_Map(glue.Schema_STRING(), glue.Schema_TIMESTAMP()),
			Comment: jsii.String("map<string,string>"),
		},
		&column{
			Name: jsii.String("struct_column"),
			Type: glue.Schema_Struct([]*column{
				&column{
					Name: jsii.String("nested_column"),
					Type: glue.Schema_DATE(),
					Comment: jsii.String("nested comment"),
				},
			}),
			Comment: jsii.String("struct<nested_column:date COMMENT 'nested comment'>"),
		},
	},
	// ...
	Database: myDatabase,
	DataFormat: glue.DataFormat_JSON(),
})
Primitives
Numeric
Name Type Comments
FLOAT Constant A 32-bit single-precision floating point number
INTEGER Constant A 32-bit signed value in two's complement format, with a minimum value of -2^31 and a maximum value of 2^31-1
DOUBLE Constant A 64-bit double-precision floating point number
BIG_INT Constant A 64-bit signed INTEGER in two’s complement format, with a minimum value of -2^63 and a maximum value of 2^63 -1
SMALL_INT Constant A 16-bit signed INTEGER in two’s complement format, with a minimum value of -2^15 and a maximum value of 2^15-1
TINY_INT Constant A 8-bit signed INTEGER in two’s complement format, with a minimum value of -2^7 and a maximum value of 2^7-1
Date and time
Name Type Comments
DATE Constant A date in UNIX format, such as YYYY-MM-DD.
TIMESTAMP Constant Date and time instant in the UNiX format, such as yyyy-mm-dd hh:mm:ss[.f...]. For example, TIMESTAMP '2008-09-15 03:04:05.324'. This format uses the session time zone.
String
Name Type Comments
STRING Constant A string literal enclosed in single or double quotes
decimal(precision: number, scale?: number) Function precision is the total number of digits. scale (optional) is the number of digits in fractional part with a default of 0. For example, use these type definitions: decimal(11,5), decimal(15)
char(length: number) Function Fixed length character data, with a specified length between 1 and 255, such as char(10)
varchar(length: number) Function Variable length character data, with a specified length between 1 and 65535, such as varchar(10)
Miscellaneous
Name Type Comments
BOOLEAN Constant Values are true and false
BINARY Constant Value is in binary
Complex
Name Type Comments
array(itemType: Type) Function An array of some other type
map(keyType: Type, valueType: Type) Function A map of some primitive key type to any value type
struct(collumns: Column[]) Function Nested structure containing individually named and typed collumns

Data Quality Ruleset

A DataQualityRuleset specifies a data quality ruleset with DQDL rules applied to a specified AWS Glue table. For example, to create a data quality ruleset for a given table:

glue.NewDataQualityRuleset(this, jsii.String("MyDataQualityRuleset"), &DataQualityRulesetProps{
	ClientToken: jsii.String("client_token"),
	Description: jsii.String("description"),
	RulesetName: jsii.String("ruleset_name"),
	RulesetDqdl: jsii.String("ruleset_dqdl"),
	Tags: map[string]*string{
		"key1": jsii.String("value1"),
		"key2": jsii.String("value2"),
	},
	TargetTable: glue.NewDataQualityTargetTable(jsii.String("database_name"), jsii.String("table_name")),
})

For more information, see AWS Glue Data Quality.

Documentation

Overview

The CDK Construct Library for AWS::Glue

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connection_IsConstruct

func Connection_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func Connection_IsOwnedResource

func Connection_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func Connection_IsResource

func Connection_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func DataQualityRuleset_IsConstruct

func DataQualityRuleset_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func DataQualityRuleset_IsOwnedResource

func DataQualityRuleset_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func DataQualityRuleset_IsResource

func DataQualityRuleset_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func Database_IsConstruct

func Database_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func Database_IsOwnedResource

func Database_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func Database_IsResource

func Database_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func ExternalTable_IsConstruct

func ExternalTable_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func ExternalTable_IsOwnedResource

func ExternalTable_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func ExternalTable_IsResource

func ExternalTable_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func Job_IsConstruct

func Job_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func Job_IsOwnedResource

func Job_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func Job_IsResource

func Job_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func NewAssetCode_Override

func NewAssetCode_Override(a AssetCode, path *string, options *awss3assets.AssetOptions)

Experimental.

func NewClassificationString_Override

func NewClassificationString_Override(c ClassificationString, value *string)

Experimental.

func NewCode_Override

func NewCode_Override(c Code)

Experimental.

func NewConnectionType_Override

func NewConnectionType_Override(c ConnectionType, name *string)

Experimental.

func NewConnection_Override

func NewConnection_Override(c Connection, scope constructs.Construct, id *string, props *ConnectionProps)

Experimental.

func NewDataFormat_Override

func NewDataFormat_Override(d DataFormat, props *DataFormatProps)

Experimental.

func NewDataQualityRuleset_Override

func NewDataQualityRuleset_Override(d DataQualityRuleset, scope constructs.Construct, id *string, props *DataQualityRulesetProps)

Experimental.

func NewDataQualityTargetTable_Override

func NewDataQualityTargetTable_Override(d DataQualityTargetTable, databaseName *string, tableName *string)

Experimental.

func NewDatabase_Override

func NewDatabase_Override(d Database, scope constructs.Construct, id *string, props *DatabaseProps)

Experimental.

func NewExternalTable_Override

func NewExternalTable_Override(e ExternalTable, scope constructs.Construct, id *string, props *ExternalTableProps)

Experimental.

func NewInputFormat_Override

func NewInputFormat_Override(i InputFormat, className *string)

Experimental.

func NewJob_Override

func NewJob_Override(j Job, scope constructs.Construct, id *string, props *JobProps)

Experimental.

func NewOutputFormat_Override

func NewOutputFormat_Override(o OutputFormat, className *string)

Experimental.

func NewS3Code_Override

func NewS3Code_Override(s S3Code, bucket awss3.IBucket, key *string)

Experimental.

func NewS3Table_Override

func NewS3Table_Override(s S3Table, scope constructs.Construct, id *string, props *S3TableProps)

Experimental.

func NewSchema_Override

func NewSchema_Override(s Schema)

Experimental.

func NewSecurityConfiguration_Override

func NewSecurityConfiguration_Override(s SecurityConfiguration, scope constructs.Construct, id *string, props *SecurityConfigurationProps)

Experimental.

func NewSerializationLibrary_Override

func NewSerializationLibrary_Override(s SerializationLibrary, className *string)

Experimental.

func NewStorageParameter_Override

func NewStorageParameter_Override(s StorageParameter, key *string, value *string)

Experimental.

func NewTableBase_Override

func NewTableBase_Override(t TableBase, scope constructs.Construct, id *string, props *TableBaseProps)

Experimental.

func NewTable_Override deprecated

func NewTable_Override(t Table, scope constructs.Construct, id *string, props *S3TableProps)

Deprecated: Use {@link S3Table } instead.

func S3Table_IsConstruct

func S3Table_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func S3Table_IsOwnedResource

func S3Table_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func S3Table_IsResource

func S3Table_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func SecurityConfiguration_IsConstruct

func SecurityConfiguration_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func SecurityConfiguration_IsOwnedResource

func SecurityConfiguration_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func SecurityConfiguration_IsResource

func SecurityConfiguration_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func TableBase_IsConstruct

func TableBase_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Experimental.

func TableBase_IsOwnedResource

func TableBase_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Experimental.

func TableBase_IsResource

func TableBase_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Experimental.

func Table_IsConstruct

func Table_IsConstruct(x interface{}) *bool

Checks if `x` is a construct.

Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.

Returns: true if `x` is an object created from a class which extends `Construct`. Deprecated: Use {@link S3Table } instead.

func Table_IsOwnedResource

func Table_IsOwnedResource(construct constructs.IConstruct) *bool

Returns true if the construct was created by CDK, and false otherwise. Deprecated: Use {@link S3Table } instead.

func Table_IsResource

func Table_IsResource(construct constructs.IConstruct) *bool

Check whether the given construct is a Resource. Deprecated: Use {@link S3Table } instead.

Types

type AssetCode

type AssetCode interface {
	Code
	// Called when the Job is initialized to allow this object to bind.
	// Experimental.
	Bind(scope constructs.Construct, grantable awsiam.IGrantable) *CodeConfig
}

Job Code from a local file.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

var dockerImage dockerImage
var grantable iGrantable
var localBundling iLocalBundling

assetCode := glue_alpha.NewAssetCode(jsii.String("path"), &AssetOptions{
	AssetHash: jsii.String("assetHash"),
	AssetHashType: cdk.AssetHashType_SOURCE,
	Bundling: &BundlingOptions{
		Image: dockerImage,

		// the properties below are optional
		BundlingFileAccess: cdk.BundlingFileAccess_VOLUME_COPY,
		Command: []*string{
			jsii.String("command"),
		},
		Entrypoint: []*string{
			jsii.String("entrypoint"),
		},
		Environment: map[string]*string{
			"environmentKey": jsii.String("environment"),
		},
		Local: localBundling,
		Network: jsii.String("network"),
		OutputType: cdk.BundlingOutput_ARCHIVED,
		Platform: jsii.String("platform"),
		SecurityOpt: jsii.String("securityOpt"),
		User: jsii.String("user"),
		Volumes: []dockerVolume{
			&dockerVolume{
				ContainerPath: jsii.String("containerPath"),
				HostPath: jsii.String("hostPath"),

				// the properties below are optional
				Consistency: cdk.DockerVolumeConsistency_CONSISTENT,
			},
		},
		VolumesFrom: []*string{
			jsii.String("volumesFrom"),
		},
		WorkingDirectory: jsii.String("workingDirectory"),
	},
	DeployTime: jsii.Boolean(false),
	Exclude: []*string{
		jsii.String("exclude"),
	},
	FollowSymlinks: cdk.SymlinkFollowMode_NEVER,
	IgnoreMode: cdk.IgnoreMode_GLOB,
	Readers: []*iGrantable{
		grantable,
	},
})

Experimental.

func AssetCode_FromAsset

func AssetCode_FromAsset(path *string, options *awss3assets.AssetOptions) AssetCode

Job code from a local disk path. Experimental.

func Code_FromAsset

func Code_FromAsset(path *string, options *awss3assets.AssetOptions) AssetCode

Job code from a local disk path. Experimental.

func NewAssetCode

func NewAssetCode(path *string, options *awss3assets.AssetOptions) AssetCode

Experimental.

func S3Code_FromAsset

func S3Code_FromAsset(path *string, options *awss3assets.AssetOptions) AssetCode

Job code from a local disk path. Experimental.

type ClassificationString

type ClassificationString interface {
	// Experimental.
	Value() *string
}

Classification string given to tables with this data format.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

classificationString := glue_alpha.ClassificationString_AVRO()

See: https://docs.aws.amazon.com/glue/latest/dg/add-classifier.html#classifier-built-in

Experimental.

func ClassificationString_AVRO

func ClassificationString_AVRO() ClassificationString

func ClassificationString_CSV

func ClassificationString_CSV() ClassificationString

func ClassificationString_JSON

func ClassificationString_JSON() ClassificationString

func ClassificationString_ORC

func ClassificationString_ORC() ClassificationString

func ClassificationString_PARQUET

func ClassificationString_PARQUET() ClassificationString

func ClassificationString_XML

func ClassificationString_XML() ClassificationString

func NewClassificationString

func NewClassificationString(value *string) ClassificationString

Experimental.

type CloudWatchEncryption

type CloudWatchEncryption struct {
	// Encryption mode.
	// Experimental.
	Mode CloudWatchEncryptionMode `field:"required" json:"mode" yaml:"mode"`
	// The KMS key to be used to encrypt the data.
	// Default: A key will be created if one is not provided.
	//
	// Experimental.
	KmsKey awskms.IKey `field:"optional" json:"kmsKey" yaml:"kmsKey"`
}

CloudWatch Logs encryption configuration.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

Experimental.

type CloudWatchEncryptionMode

type CloudWatchEncryptionMode string

Encryption mode for CloudWatch Logs.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

See: https://docs.aws.amazon.com/glue/latest/webapi/API_CloudWatchEncryption.html#Glue-Type-CloudWatchEncryption-CloudWatchEncryptionMode

Experimental.

const (
	// Server-side encryption (SSE) with an AWS KMS key managed by the account owner.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingKMSEncryption.html
	//
	// Experimental.
	CloudWatchEncryptionMode_KMS CloudWatchEncryptionMode = "KMS"
)

type Code

type Code interface {
	// Called when the Job is initialized to allow this object to bind.
	// Experimental.
	Bind(scope constructs.Construct, grantable awsiam.IGrantable) *CodeConfig
}

Represents a Glue Job's Code assets (an asset can be a scripts, a jar, a python file or any other file).

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

Experimental.

type CodeConfig

type CodeConfig struct {
	// The location of the code in S3.
	// Experimental.
	S3Location *awss3.Location `field:"required" json:"s3Location" yaml:"s3Location"`
}

Result of binding `Code` into a `Job`.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

codeConfig := &CodeConfig{
	S3Location: &Location{
		BucketName: jsii.String("bucketName"),
		ObjectKey: jsii.String("objectKey"),

		// the properties below are optional
		ObjectVersion: jsii.String("objectVersion"),
	},
}

Experimental.

type Column

type Column struct {
	// Name of the column.
	// Experimental.
	Name *string `field:"required" json:"name" yaml:"name"`
	// Type of the column.
	// Experimental.
	Type *Type `field:"required" json:"type" yaml:"type"`
	// Coment describing the column.
	// Default: none.
	//
	// Experimental.
	Comment *string `field:"optional" json:"comment" yaml:"comment"`
}

A column of a table.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

column := &Column{
	Name: jsii.String("name"),
	Type: &Type{
		InputString: jsii.String("inputString"),
		IsPrimitive: jsii.Boolean(false),
	},

	// the properties below are optional
	Comment: jsii.String("comment"),
}

Experimental.

type ColumnCountMismatchHandlingAction

type ColumnCountMismatchHandlingAction string

Identifies if the file contains less or more values for a row than the number of columns specified in the external table definition.

This property is only available for an uncompressed text file format. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"column_count_mismatch_handling"_

Experimental.

const (
	// Column count mismatch handling is turned off.
	// Experimental.
	ColumnCountMismatchHandlingAction_DISABLED ColumnCountMismatchHandlingAction = "DISABLED"
	// Fail the query if the column count mismatch is detected.
	// Experimental.
	ColumnCountMismatchHandlingAction_FAIL ColumnCountMismatchHandlingAction = "FAIL"
	// Fill missing values with NULL and ignore the additional values in each row.
	// Experimental.
	ColumnCountMismatchHandlingAction_SET_TO_NULL ColumnCountMismatchHandlingAction = "SET_TO_NULL"
	// Drop all rows that contain column count mismatch error from the scan.
	// Experimental.
	ColumnCountMismatchHandlingAction_DROP_ROW ColumnCountMismatchHandlingAction = "DROP_ROW"
)

type CompressionType

type CompressionType string

The compression type.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	StorageParameters: []storageParameter{
		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
		glue.*storageParameter_Custom(jsii.String("separatorChar"), jsii.String(",")),
	},
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"compression_type"_

Experimental.

const (
	// No compression.
	// Experimental.
	CompressionType_NONE CompressionType = "NONE"
	// Burrows-Wheeler compression.
	// Experimental.
	CompressionType_BZIP2 CompressionType = "BZIP2"
	// Deflate compression.
	// Experimental.
	CompressionType_GZIP CompressionType = "GZIP"
	// Compression algorithm focused on high compression and decompression speeds, rather than the maximum possible compression.
	// Experimental.
	CompressionType_SNAPPY CompressionType = "SNAPPY"
)

type Connection

type Connection interface {
	awscdk.Resource
	IConnection
	// The ARN of the connection.
	// Experimental.
	ConnectionArn() *string
	// The name of the connection.
	// Experimental.
	ConnectionName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// Add additional connection parameters.
	// Experimental.
	AddProperty(key *string, value *string)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

An AWS Glue connection to a data source.

Example:

var securityGroup securityGroup
var subnet subnet

glue.NewConnection(this, jsii.String("MyConnection"), &ConnectionProps{
	Type: glue.ConnectionType_NETWORK(),
	// The security groups granting AWS Glue inbound access to the data source within the VPC
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	// The VPC subnet which contains the data source
	Subnet: Subnet,
})

Experimental.

func NewConnection

func NewConnection(scope constructs.Construct, id *string, props *ConnectionProps) Connection

Experimental.

type ConnectionOptions

type ConnectionOptions struct {
	// The name of the connection.
	// Default: cloudformation generated name.
	//
	// Experimental.
	ConnectionName *string `field:"optional" json:"connectionName" yaml:"connectionName"`
	// The description of the connection.
	// Default: no description.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// A list of criteria that can be used in selecting this connection.
	//
	// This is useful for filtering the results of https://awscli.amazonaws.com/v2/documentation/api/latest/reference/glue/get-connections.html
	// Default: no match criteria.
	//
	// Experimental.
	MatchCriteria *[]*string `field:"optional" json:"matchCriteria" yaml:"matchCriteria"`
	// Key-Value pairs that define parameters for the connection.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-connect.html
	//
	// Default: empty properties.
	//
	// Experimental.
	Properties *map[string]*string `field:"optional" json:"properties" yaml:"properties"`
	// The list of security groups needed to successfully make this connection e.g. to successfully connect to VPC.
	// Default: no security group.
	//
	// Experimental.
	SecurityGroups *[]awsec2.ISecurityGroup `field:"optional" json:"securityGroups" yaml:"securityGroups"`
	// The VPC subnet to connect to resources within a VPC.
	//
	// See more at https://docs.aws.amazon.com/glue/latest/dg/start-connecting.html.
	// Default: no subnet.
	//
	// Experimental.
	Subnet awsec2.ISubnet `field:"optional" json:"subnet" yaml:"subnet"`
}

Base Connection Options.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var securityGroup securityGroup
var subnet subnet

connectionOptions := &ConnectionOptions{
	ConnectionName: jsii.String("connectionName"),
	Description: jsii.String("description"),
	MatchCriteria: []*string{
		jsii.String("matchCriteria"),
	},
	Properties: map[string]*string{
		"propertiesKey": jsii.String("properties"),
	},
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	Subnet: subnet,
}

Experimental.

type ConnectionProps

type ConnectionProps struct {
	// The name of the connection.
	// Default: cloudformation generated name.
	//
	// Experimental.
	ConnectionName *string `field:"optional" json:"connectionName" yaml:"connectionName"`
	// The description of the connection.
	// Default: no description.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// A list of criteria that can be used in selecting this connection.
	//
	// This is useful for filtering the results of https://awscli.amazonaws.com/v2/documentation/api/latest/reference/glue/get-connections.html
	// Default: no match criteria.
	//
	// Experimental.
	MatchCriteria *[]*string `field:"optional" json:"matchCriteria" yaml:"matchCriteria"`
	// Key-Value pairs that define parameters for the connection.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-connect.html
	//
	// Default: empty properties.
	//
	// Experimental.
	Properties *map[string]*string `field:"optional" json:"properties" yaml:"properties"`
	// The list of security groups needed to successfully make this connection e.g. to successfully connect to VPC.
	// Default: no security group.
	//
	// Experimental.
	SecurityGroups *[]awsec2.ISecurityGroup `field:"optional" json:"securityGroups" yaml:"securityGroups"`
	// The VPC subnet to connect to resources within a VPC.
	//
	// See more at https://docs.aws.amazon.com/glue/latest/dg/start-connecting.html.
	// Default: no subnet.
	//
	// Experimental.
	Subnet awsec2.ISubnet `field:"optional" json:"subnet" yaml:"subnet"`
	// The type of the connection.
	// Experimental.
	Type ConnectionType `field:"required" json:"type" yaml:"type"`
}

Construction properties for `Connection`.

Example:

var securityGroup securityGroup
var subnet subnet

glue.NewConnection(this, jsii.String("MyConnection"), &ConnectionProps{
	Type: glue.ConnectionType_NETWORK(),
	// The security groups granting AWS Glue inbound access to the data source within the VPC
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	// The VPC subnet which contains the data source
	Subnet: Subnet,
})

Experimental.

type ConnectionType

type ConnectionType interface {
	// The name of this ConnectionType, as expected by Connection resource.
	// Experimental.
	Name() *string
	// The connection type name as expected by Connection resource.
	// Experimental.
	ToString() *string
}

The type of the glue connection.

If you need to use a connection type that doesn't exist as a static member, you can instantiate a `ConnectionType` object, e.g: `new ConnectionType('NEW_TYPE')`.

Example:

var securityGroup securityGroup
var subnet subnet

glue.NewConnection(this, jsii.String("MyConnection"), &ConnectionProps{
	Type: glue.ConnectionType_NETWORK(),
	// The security groups granting AWS Glue inbound access to the data source within the VPC
	SecurityGroups: []iSecurityGroup{
		securityGroup,
	},
	// The VPC subnet which contains the data source
	Subnet: Subnet,
})

Experimental.

func ConnectionType_JDBC

func ConnectionType_JDBC() ConnectionType

func ConnectionType_KAFKA

func ConnectionType_KAFKA() ConnectionType

func ConnectionType_MONGODB

func ConnectionType_MONGODB() ConnectionType

func ConnectionType_NETWORK

func ConnectionType_NETWORK() ConnectionType

func NewConnectionType

func NewConnectionType(name *string) ConnectionType

Experimental.

type ContinuousLoggingProps

type ContinuousLoggingProps struct {
	// Enable continouous logging.
	// Experimental.
	Enabled *bool `field:"required" json:"enabled" yaml:"enabled"`
	// Apply the provided conversion pattern.
	//
	// This is a Log4j Conversion Pattern to customize driver and executor logs.
	// Default: `%d{yy/MM/dd HH:mm:ss} %p %c{1}: %m%n`.
	//
	// Experimental.
	ConversionPattern *string `field:"optional" json:"conversionPattern" yaml:"conversionPattern"`
	// Specify a custom CloudWatch log group name.
	// Default: - a log group is created with name `/aws-glue/jobs/logs-v2/`.
	//
	// Experimental.
	LogGroup awslogs.ILogGroup `field:"optional" json:"logGroup" yaml:"logGroup"`
	// Specify a custom CloudWatch log stream prefix.
	// Default: - the job run ID.
	//
	// Experimental.
	LogStreamPrefix *string `field:"optional" json:"logStreamPrefix" yaml:"logStreamPrefix"`
	// Filter out non-useful Apache Spark driver/executor and Apache Hadoop YARN heartbeat log messages.
	// Default: true.
	//
	// Experimental.
	Quiet *bool `field:"optional" json:"quiet" yaml:"quiet"`
}

Properties for enabling Continuous Logging for Glue Jobs.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var logGroup logGroup

continuousLoggingProps := &ContinuousLoggingProps{
	Enabled: jsii.Boolean(false),

	// the properties below are optional
	ConversionPattern: jsii.String("conversionPattern"),
	LogGroup: logGroup,
	LogStreamPrefix: jsii.String("logStreamPrefix"),
	Quiet: jsii.Boolean(false),
}

See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html

Experimental.

type DataFormat

type DataFormat interface {
	// Classification string given to tables with this data format.
	// Experimental.
	ClassificationString() ClassificationString
	// `InputFormat` for this data format.
	// Experimental.
	InputFormat() InputFormat
	// `OutputFormat` for this data format.
	// Experimental.
	OutputFormat() OutputFormat
	// Serialization library for this data format.
	// Experimental.
	SerializationLibrary() SerializationLibrary
}

Defines the input/output formats and ser/de for a single DataFormat.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Experimental.

func DataFormat_APACHE_LOGS

func DataFormat_APACHE_LOGS() DataFormat

func DataFormat_AVRO

func DataFormat_AVRO() DataFormat

func DataFormat_CLOUDTRAIL_LOGS

func DataFormat_CLOUDTRAIL_LOGS() DataFormat

func DataFormat_CSV

func DataFormat_CSV() DataFormat

func DataFormat_JSON

func DataFormat_JSON() DataFormat

func DataFormat_LOGSTASH

func DataFormat_LOGSTASH() DataFormat

func DataFormat_ORC

func DataFormat_ORC() DataFormat

func DataFormat_PARQUET

func DataFormat_PARQUET() DataFormat

func DataFormat_TSV

func DataFormat_TSV() DataFormat

func NewDataFormat

func NewDataFormat(props *DataFormatProps) DataFormat

Experimental.

type DataFormatProps

type DataFormatProps struct {
	// `InputFormat` for this data format.
	// Experimental.
	InputFormat InputFormat `field:"required" json:"inputFormat" yaml:"inputFormat"`
	// `OutputFormat` for this data format.
	// Experimental.
	OutputFormat OutputFormat `field:"required" json:"outputFormat" yaml:"outputFormat"`
	// Serialization library for this data format.
	// Experimental.
	SerializationLibrary SerializationLibrary `field:"required" json:"serializationLibrary" yaml:"serializationLibrary"`
	// Classification string given to tables with this data format.
	// Default: - No classification is specified.
	//
	// Experimental.
	ClassificationString ClassificationString `field:"optional" json:"classificationString" yaml:"classificationString"`
}

Properties of a DataFormat instance.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

var classificationString classificationString
var inputFormat inputFormat
var outputFormat outputFormat
var serializationLibrary serializationLibrary

dataFormatProps := &DataFormatProps{
	InputFormat: inputFormat,
	OutputFormat: outputFormat,
	SerializationLibrary: serializationLibrary,

	// the properties below are optional
	ClassificationString: classificationString,
}

Experimental.

type DataQualityRuleset

type DataQualityRuleset interface {
	awscdk.Resource
	IDataQualityRuleset
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// ARN of this ruleset.
	// Experimental.
	RulesetArn() *string
	// Name of this ruleset.
	// Experimental.
	RulesetName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue Data Quality ruleset.

Example:

glue.NewDataQualityRuleset(this, jsii.String("MyDataQualityRuleset"), &DataQualityRulesetProps{
	ClientToken: jsii.String("client_token"),
	Description: jsii.String("description"),
	RulesetName: jsii.String("ruleset_name"),
	RulesetDqdl: jsii.String("ruleset_dqdl"),
	Tags: map[string]*string{
		"key1": jsii.String("value1"),
		"key2": jsii.String("value2"),
	},
	TargetTable: glue.NewDataQualityTargetTable(jsii.String("database_name"), jsii.String("table_name")),
})

Experimental.

func NewDataQualityRuleset

func NewDataQualityRuleset(scope constructs.Construct, id *string, props *DataQualityRulesetProps) DataQualityRuleset

Experimental.

type DataQualityRulesetProps

type DataQualityRulesetProps struct {
	// The dqdl of the ruleset.
	// Experimental.
	RulesetDqdl *string `field:"required" json:"rulesetDqdl" yaml:"rulesetDqdl"`
	// The target table of the ruleset.
	// Experimental.
	TargetTable DataQualityTargetTable `field:"required" json:"targetTable" yaml:"targetTable"`
	// The client token of the ruleset.
	// Experimental.
	ClientToken *string `field:"optional" json:"clientToken" yaml:"clientToken"`
	// The description of the ruleset.
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// The name of the ruleset.
	// Default: cloudformation generated name.
	//
	// Experimental.
	RulesetName *string `field:"optional" json:"rulesetName" yaml:"rulesetName"`
	// Key-Value pairs that define tags for the ruleset.
	// Default: empty tags.
	//
	// Experimental.
	Tags *map[string]*string `field:"optional" json:"tags" yaml:"tags"`
}

Construction properties for `DataQualityRuleset`.

Example:

glue.NewDataQualityRuleset(this, jsii.String("MyDataQualityRuleset"), &DataQualityRulesetProps{
	ClientToken: jsii.String("client_token"),
	Description: jsii.String("description"),
	RulesetName: jsii.String("ruleset_name"),
	RulesetDqdl: jsii.String("ruleset_dqdl"),
	Tags: map[string]*string{
		"key1": jsii.String("value1"),
		"key2": jsii.String("value2"),
	},
	TargetTable: glue.NewDataQualityTargetTable(jsii.String("database_name"), jsii.String("table_name")),
})

Experimental.

type DataQualityTargetTable

type DataQualityTargetTable interface {
	// The database name of the target table.
	// Experimental.
	DatabaseName() *string
	// The table name of the target table.
	// Experimental.
	TableName() *string
}

Properties of a DataQualityTargetTable.

Example:

glue.NewDataQualityRuleset(this, jsii.String("MyDataQualityRuleset"), &DataQualityRulesetProps{
	ClientToken: jsii.String("client_token"),
	Description: jsii.String("description"),
	RulesetName: jsii.String("ruleset_name"),
	RulesetDqdl: jsii.String("ruleset_dqdl"),
	Tags: map[string]*string{
		"key1": jsii.String("value1"),
		"key2": jsii.String("value2"),
	},
	TargetTable: glue.NewDataQualityTargetTable(jsii.String("database_name"), jsii.String("table_name")),
})

Experimental.

func NewDataQualityTargetTable

func NewDataQualityTargetTable(databaseName *string, tableName *string) DataQualityTargetTable

Experimental.

type Database

type Database interface {
	awscdk.Resource
	IDatabase
	// ARN of the Glue catalog in which this database is stored.
	// Experimental.
	CatalogArn() *string
	// The catalog id of the database (usually, the AWS account id).
	// Experimental.
	CatalogId() *string
	// ARN of this database.
	// Experimental.
	DatabaseArn() *string
	// Name of this database.
	// Experimental.
	DatabaseName() *string
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// Location URI of this database.
	// Experimental.
	LocationUri() *string
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue database.

Example:

import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var stack stack
var accountId string

tagKey := "aws"
tagValues := []*string{
	"dev",
}

database := awscdkgluealpha.NewDatabase(this, jsii.String("Database"))

table := awscdkgluealpha.NewS3Table(this, jsii.String("Table"), &S3TableProps{
	Database: Database,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: awscdkgluealpha.Schema_STRING(),
		},
		&column{
			Name: jsii.String("col2"),
			Type: awscdkgluealpha.Schema_STRING(),
		},
	},
	DataFormat: awscdkgluealpha.DataFormat_CSV(),
})

synthesizer := stack.Synthesizer.(defaultStackSynthesizer)
awscdk.NewCfnDataLakeSettings(this, jsii.String("DataLakeSettings"), &CfnDataLakeSettingsProps{
	Admins: []interface{}{
		&DataLakePrincipalProperty{
			DataLakePrincipalIdentifier: stack.FormatArn(&ArnComponents{
				Service: jsii.String("iam"),
				Resource: jsii.String("role"),
				Region: jsii.String(""),
				Account: accountId,
				ResourceName: jsii.String("Admin"),
			}),
		},
		&DataLakePrincipalProperty{
			// The CDK cloudformation execution role.
			DataLakePrincipalIdentifier: synthesizer.cloudFormationExecutionRoleArn.replace(jsii.String("${AWS::Partition}"), jsii.String("aws")),
		},
	},
})

tag := awscdk.NewCfnTag(this, jsii.String("Tag"), &CfnTagProps{
	CatalogId: accountId,
	TagKey: jsii.String(TagKey),
	TagValues: TagValues,
})

lfTagPairProperty := &LFTagPairProperty{
	CatalogId: accountId,
	TagKey: jsii.String(TagKey),
	TagValues: TagValues,
}

tagAssociation := awscdk.NewCfnTagAssociation(this, jsii.String("TagAssociation"), &CfnTagAssociationProps{
	LfTags: []interface{}{
		lfTagPairProperty,
	},
	Resource: &ResourceProperty{
		TableWithColumns: &TableWithColumnsResourceProperty{
			DatabaseName: database.DatabaseName,
			ColumnNames: []*string{
				jsii.String("col1"),
				jsii.String("col2"),
			},
			CatalogId: accountId,
			Name: table.TableName,
		},
	},
})

tagAssociation.Node.AddDependency(tag)
tagAssociation.Node.AddDependency(table)

Experimental.

func NewDatabase

func NewDatabase(scope constructs.Construct, id *string, props *DatabaseProps) Database

Experimental.

type DatabaseProps

type DatabaseProps struct {
	// The name of the database.
	// Default: - generated by CDK.
	//
	// Experimental.
	DatabaseName *string `field:"optional" json:"databaseName" yaml:"databaseName"`
	// A description of the database.
	// Default: - no database description.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// The location of the database (for example, an HDFS path).
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-database-databaseinput.html
	//
	// Default: undefined. This field is optional in AWS::Glue::Database DatabaseInput
	//
	// Experimental.
	LocationUri *string `field:"optional" json:"locationUri" yaml:"locationUri"`
}

Example:

glue.NewDatabase(this, jsii.String("MyDatabase"), &DatabaseProps{
	DatabaseName: jsii.String("my_database"),
	Description: jsii.String("my_database_description"),
})

Experimental.

type ExecutionClass

type ExecutionClass string

The ExecutionClass whether the job is run with a standard or flexible execution class. See: https://docs.aws.amazon.com/glue/latest/dg/add-job.html

Experimental.

const (
	// The flexible execution class is appropriate for time-insensitive jobs whose start and completion times may vary.
	// Experimental.
	ExecutionClass_FLEX ExecutionClass = "FLEX"
	// The standard execution class is ideal for time-sensitive workloads that require fast job startup and dedicated resources.
	// Experimental.
	ExecutionClass_STANDARD ExecutionClass = "STANDARD"
)

type ExternalTable

type ExternalTable interface {
	TableBase
	// This table's columns.
	// Experimental.
	Columns() *[]*Column
	// Indicates whether the table's data is compressed or not.
	// Experimental.
	Compressed() *bool
	// The connection associated to this table.
	// Experimental.
	Connection() IConnection
	// Database this table belongs to.
	// Experimental.
	Database() IDatabase
	// Format of this table's data files.
	// Experimental.
	DataFormat() DataFormat
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// The tables' properties associated with the table.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Experimental.
	Parameters() *map[string]*string
	// This table's partition indexes.
	// Experimental.
	PartitionIndexes() *[]*PartitionIndex
	// This table's partition keys if the table is partitioned.
	// Experimental.
	PartitionKeys() *[]*Column
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// The tables' storage descriptor properties.
	// Experimental.
	StorageParameters() *[]StorageParameter
	// ARN of this table.
	// Experimental.
	TableArn() *string
	// Name of this table.
	// Experimental.
	TableName() *string
	// Experimental.
	TableResource() awsglue.CfnTable
	// Add a partition index to the table.
	//
	// You can have a maximum of 3 partition
	// indexes to a table. Partition index keys must be a subset of the table's
	// partition keys.
	// See: https://docs.aws.amazon.com/glue/latest/dg/partition-indexes.html
	//
	// Experimental.
	AddPartitionIndex(index *PartitionIndex)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Grant the given identity custom permissions.
	// Experimental.
	Grant(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant read permissions to the table.
	// Experimental.
	GrantRead(grantee awsiam.IGrantable) awsiam.Grant
	// Grant read and write permissions to the table.
	// Experimental.
	GrantReadWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Grant the given identity custom permissions to ALL underlying resources of the table.
	//
	// Permissions will be granted to the catalog, the database, and the table.
	// Experimental.
	GrantToUnderlyingResources(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant write permissions to the table.
	// Experimental.
	GrantWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue table that targets an external data location (e.g. A table in a Redshift Cluster).

Example:

var myConnection connection
var myDatabase database

glue.NewExternalTable(this, jsii.String("MyTable"), &ExternalTableProps{
	Connection: myConnection,
	ExternalDataLocation: jsii.String("default_db_public_example"),
	 // A table in Redshift
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Experimental.

func NewExternalTable

func NewExternalTable(scope constructs.Construct, id *string, props *ExternalTableProps) ExternalTable

Experimental.

type ExternalTableProps

type ExternalTableProps struct {
	// Columns of the table.
	// Experimental.
	Columns *[]*Column `field:"required" json:"columns" yaml:"columns"`
	// Database in which to store the table.
	// Experimental.
	Database IDatabase `field:"required" json:"database" yaml:"database"`
	// Storage type of the table's data.
	// Experimental.
	DataFormat DataFormat `field:"required" json:"dataFormat" yaml:"dataFormat"`
	// Indicates whether the table's data is compressed or not.
	// Default: false.
	//
	// Experimental.
	Compressed *bool `field:"optional" json:"compressed" yaml:"compressed"`
	// Description of the table.
	// Default: generated.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// Enables partition filtering.
	// See: https://docs.aws.amazon.com/athena/latest/ug/glue-best-practices.html#glue-best-practices-partition-index
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	EnablePartitionFiltering *bool `field:"optional" json:"enablePartitionFiltering" yaml:"enablePartitionFiltering"`
	// The key/value pairs define properties associated with the table.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	Parameters *map[string]*string `field:"optional" json:"parameters" yaml:"parameters"`
	// Partition indexes on the table.
	//
	// A maximum of 3 indexes
	// are allowed on a table. Keys in the index must be part
	// of the table's partition keys.
	// Default: table has no partition indexes.
	//
	// Experimental.
	PartitionIndexes *[]*PartitionIndex `field:"optional" json:"partitionIndexes" yaml:"partitionIndexes"`
	// Partition columns of the table.
	// Default: table is not partitioned.
	//
	// Experimental.
	PartitionKeys *[]*Column `field:"optional" json:"partitionKeys" yaml:"partitionKeys"`
	// The user-supplied properties for the description of the physical storage of this table.
	//
	// These properties help describe the format of the data that is stored within the crawled data sources.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	//
	// Some keys will be auto-populated by glue crawlers, however, you can override them by specifying the key and value in this property.
	//
	// Example:
	//      declare const glueDatabase: glue.IDatabase;
	//      const table = new glue.Table(this, 'Table', {
	//        storageParameters: [
	//            glue.StorageParameter.skipHeaderLineCount(1),
	//            glue.StorageParameter.compressionType(glue.CompressionType.GZIP),
	//            glue.StorageParameter.custom('foo', 'bar'), // Will have no effect
	//            glue.StorageParameter.custom('separatorChar', ','), // Will describe the separator char used in the data
	//            glue.StorageParameter.custom(glue.StorageParameters.WRITE_PARALLEL, 'off'),
	//        ],
	//        // ...
	//        database: glueDatabase,
	//        columns: [{
	//            name: 'col1',
	//            type: glue.Schema.STRING,
	//        }],
	//        dataFormat: glue.DataFormat.CSV,
	//      });
	//
	// See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	StorageParameters *[]StorageParameter `field:"optional" json:"storageParameters" yaml:"storageParameters"`
	// Indicates whether the table data is stored in subdirectories.
	// Default: false.
	//
	// Experimental.
	StoredAsSubDirectories *bool `field:"optional" json:"storedAsSubDirectories" yaml:"storedAsSubDirectories"`
	// Name of the table.
	// Default: - generated by CDK.
	//
	// Experimental.
	TableName *string `field:"optional" json:"tableName" yaml:"tableName"`
	// The connection the table will use when performing reads and writes.
	// Default: - No connection.
	//
	// Experimental.
	Connection IConnection `field:"required" json:"connection" yaml:"connection"`
	// The data source location of the glue table, (e.g. `default_db_public_example` for Redshift).
	//
	// If this property is set, it will override both `bucket` and `s3Prefix`.
	// Default: - No outsourced data source location.
	//
	// Experimental.
	ExternalDataLocation *string `field:"required" json:"externalDataLocation" yaml:"externalDataLocation"`
}

Example:

var myConnection connection
var myDatabase database

glue.NewExternalTable(this, jsii.String("MyTable"), &ExternalTableProps{
	Connection: myConnection,
	ExternalDataLocation: jsii.String("default_db_public_example"),
	 // A table in Redshift
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Experimental.

type GlueVersion

type GlueVersion interface {
	// The name of this GlueVersion, as expected by Job resource.
	// Experimental.
	Name() *string
}

AWS Glue version determines the versions of Apache Spark and Python that are available to the job.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

See: https://docs.aws.amazon.com/glue/latest/dg/add-job.html.

If you need to use a GlueVersion that doesn't exist as a static member, you can instantiate a `GlueVersion` object, e.g: `GlueVersion.of('1.5')`.

Experimental.

func GlueVersion_Of

func GlueVersion_Of(version *string) GlueVersion

Custom Glue version. Experimental.

func GlueVersion_V0_9

func GlueVersion_V0_9() GlueVersion

func GlueVersion_V1_0

func GlueVersion_V1_0() GlueVersion

func GlueVersion_V2_0

func GlueVersion_V2_0() GlueVersion

func GlueVersion_V3_0

func GlueVersion_V3_0() GlueVersion

func GlueVersion_V4_0

func GlueVersion_V4_0() GlueVersion

type IConnection

type IConnection interface {
	awscdk.IResource
	// The ARN of the connection.
	// Experimental.
	ConnectionArn() *string
	// The name of the connection.
	// Experimental.
	ConnectionName() *string
}

Interface representing a created or an imported `Connection`. Experimental.

func Connection_FromConnectionArn

func Connection_FromConnectionArn(scope constructs.Construct, id *string, connectionArn *string) IConnection

Creates a Connection construct that represents an external connection. Experimental.

func Connection_FromConnectionName

func Connection_FromConnectionName(scope constructs.Construct, id *string, connectionName *string) IConnection

Creates a Connection construct that represents an external connection. Experimental.

type IDataQualityRuleset

type IDataQualityRuleset interface {
	awscdk.IResource
	// The ARN of the ruleset.
	// Experimental.
	RulesetArn() *string
	// The name of the ruleset.
	// Experimental.
	RulesetName() *string
}

Experimental.

func DataQualityRuleset_FromRulesetArn

func DataQualityRuleset_FromRulesetArn(scope constructs.Construct, id *string, rulesetArn *string) IDataQualityRuleset

Experimental.

func DataQualityRuleset_FromRulesetName

func DataQualityRuleset_FromRulesetName(scope constructs.Construct, id *string, rulesetName *string) IDataQualityRuleset

Experimental.

type IDatabase

type IDatabase interface {
	awscdk.IResource
	// The ARN of the catalog.
	// Experimental.
	CatalogArn() *string
	// The catalog id of the database (usually, the AWS account id).
	// Experimental.
	CatalogId() *string
	// The ARN of the database.
	// Experimental.
	DatabaseArn() *string
	// The name of the database.
	// Experimental.
	DatabaseName() *string
}

Experimental.

func Database_FromDatabaseArn

func Database_FromDatabaseArn(scope constructs.Construct, id *string, databaseArn *string) IDatabase

Experimental.

type IJob

type IJob interface {
	awsiam.IGrantable
	awscdk.IResource
	// Create a CloudWatch metric.
	// See: https://docs.aws.amazon.com/glue/latest/dg/monitoring-awsglue-with-cloudwatch-metrics.html
	//
	// Experimental.
	Metric(metricName *string, type_ MetricType, props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Create a CloudWatch Metric indicating job failure.
	// Experimental.
	MetricFailure(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Create a CloudWatch Metric indicating job success.
	// Experimental.
	MetricSuccess(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Create a CloudWatch Metric indicating job timeout.
	// Experimental.
	MetricTimeout(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Defines a CloudWatch event rule triggered when something happens with this job.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnEvent(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Defines a CloudWatch event rule triggered when this job moves to the FAILED state.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnFailure(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Defines a CloudWatch event rule triggered when this job moves to the input jobState.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnStateChange(id *string, jobState JobState, options *awsevents.OnEventOptions) awsevents.Rule
	// Defines a CloudWatch event rule triggered when this job moves to the SUCCEEDED state.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnSuccess(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Defines a CloudWatch event rule triggered when this job moves to the TIMEOUT state.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnTimeout(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// The ARN of the job.
	// Experimental.
	JobArn() *string
	// The name of the job.
	// Experimental.
	JobName() *string
}

Interface representing a created or an imported `Job`. Experimental.

func Job_FromJobAttributes

func Job_FromJobAttributes(scope constructs.Construct, id *string, attrs *JobAttributes) IJob

Creates a Glue Job. Experimental.

type ISecurityConfiguration

type ISecurityConfiguration interface {
	awscdk.IResource
	// The name of the security configuration.
	// Experimental.
	SecurityConfigurationName() *string
}

Interface representing a created or an imported `SecurityConfiguration`. Experimental.

func SecurityConfiguration_FromSecurityConfigurationName

func SecurityConfiguration_FromSecurityConfigurationName(scope constructs.Construct, id *string, securityConfigurationName *string) ISecurityConfiguration

Creates a Connection construct that represents an external security configuration. Experimental.

type ITable

type ITable interface {
	awscdk.IResource
	// Experimental.
	TableArn() *string
	// Experimental.
	TableName() *string
}

Experimental.

func ExternalTable_FromTableArn

func ExternalTable_FromTableArn(scope constructs.Construct, id *string, tableArn *string) ITable

Experimental.

func ExternalTable_FromTableAttributes

func ExternalTable_FromTableAttributes(scope constructs.Construct, id *string, attrs *TableAttributes) ITable

Creates a Table construct that represents an external table. Experimental.

func S3Table_FromTableArn

func S3Table_FromTableArn(scope constructs.Construct, id *string, tableArn *string) ITable

Experimental.

func S3Table_FromTableAttributes

func S3Table_FromTableAttributes(scope constructs.Construct, id *string, attrs *TableAttributes) ITable

Creates a Table construct that represents an external table. Experimental.

func TableBase_FromTableArn

func TableBase_FromTableArn(scope constructs.Construct, id *string, tableArn *string) ITable

Experimental.

func TableBase_FromTableAttributes

func TableBase_FromTableAttributes(scope constructs.Construct, id *string, attrs *TableAttributes) ITable

Creates a Table construct that represents an external table. Experimental.

func Table_FromTableArn deprecated

func Table_FromTableArn(scope constructs.Construct, id *string, tableArn *string) ITable

Deprecated: Use {@link S3Table } instead.

func Table_FromTableAttributes

func Table_FromTableAttributes(scope constructs.Construct, id *string, attrs *TableAttributes) ITable

Creates a Table construct that represents an external table. Deprecated: Use {@link S3Table } instead.

type InputFormat

type InputFormat interface {
	// Experimental.
	ClassName() *string
}

Absolute class name of the Hadoop `InputFormat` to use when reading table files.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

inputFormat := glue_alpha.InputFormat_AVRO()

Experimental.

func InputFormat_AVRO

func InputFormat_AVRO() InputFormat

func InputFormat_CLOUDTRAIL

func InputFormat_CLOUDTRAIL() InputFormat

func InputFormat_ORC

func InputFormat_ORC() InputFormat

func InputFormat_PARQUET

func InputFormat_PARQUET() InputFormat

func InputFormat_TEXT

func InputFormat_TEXT() InputFormat

func NewInputFormat

func NewInputFormat(className *string) InputFormat

Experimental.

func OutputFormat_AVRO

func OutputFormat_AVRO() InputFormat

func OutputFormat_ORC

func OutputFormat_ORC() InputFormat

type InvalidCharHandlingAction

type InvalidCharHandlingAction string

Specifies the action to perform when query results contain invalid UTF-8 character values. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"invalid_char_handling"_

Experimental.

const (
	// Doesn't perform invalid character handling.
	// Experimental.
	InvalidCharHandlingAction_DISABLED InvalidCharHandlingAction = "DISABLED"
	// Cancels queries that return data containing invalid UTF-8 values.
	// Experimental.
	InvalidCharHandlingAction_FAIL InvalidCharHandlingAction = "FAIL"
	// Replaces invalid UTF-8 values with null.
	// Experimental.
	InvalidCharHandlingAction_SET_TO_NULL InvalidCharHandlingAction = "SET_TO_NULL"
	// Replaces each value in the row with null.
	// Experimental.
	InvalidCharHandlingAction_DROP_ROW InvalidCharHandlingAction = "DROP_ROW"
	// Replaces the invalid character with the replacement character you specify using `REPLACEMENT_CHAR`.
	// Experimental.
	InvalidCharHandlingAction_REPLACE InvalidCharHandlingAction = "REPLACE"
)

type Job

type Job interface {
	awscdk.Resource
	IJob
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The principal this Glue Job is running as.
	// Experimental.
	GrantPrincipal() awsiam.IPrincipal
	// The ARN of the job.
	// Experimental.
	JobArn() *string
	// The name of the job.
	// Experimental.
	JobName() *string
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The IAM role Glue assumes to run this job.
	// Experimental.
	Role() awsiam.IRole
	// The Spark UI logs location if Spark UI monitoring and debugging is enabled.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Experimental.
	SparkUILoggingLocation() *SparkUILoggingLocation
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Create a CloudWatch metric.
	// See: https://docs.aws.amazon.com/glue/latest/dg/monitoring-awsglue-with-cloudwatch-metrics.html
	//
	// Experimental.
	Metric(metricName *string, type_ MetricType, props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Return a CloudWatch Metric indicating job failure.
	//
	// This metric is based on the Rule returned by no-args onFailure() call.
	// Experimental.
	MetricFailure(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Return a CloudWatch Metric indicating job success.
	//
	// This metric is based on the Rule returned by no-args onSuccess() call.
	// Experimental.
	MetricSuccess(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Return a CloudWatch Metric indicating job timeout.
	//
	// This metric is based on the Rule returned by no-args onTimeout() call.
	// Experimental.
	MetricTimeout(props *awscloudwatch.MetricOptions) awscloudwatch.Metric
	// Create a CloudWatch Event Rule for this Glue Job when it's in a given state.
	// See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types
	//
	// Experimental.
	OnEvent(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Return a CloudWatch Event Rule matching FAILED state.
	// Experimental.
	OnFailure(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Create a CloudWatch Event Rule for the transition into the input jobState.
	// Experimental.
	OnStateChange(id *string, jobState JobState, options *awsevents.OnEventOptions) awsevents.Rule
	// Create a CloudWatch Event Rule matching JobState.SUCCEEDED.
	// Experimental.
	OnSuccess(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Return a CloudWatch Event Rule matching TIMEOUT state.
	// Experimental.
	OnTimeout(id *string, options *awsevents.OnEventOptions) awsevents.Rule
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue Job.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

Experimental.

func NewJob

func NewJob(scope constructs.Construct, id *string, props *JobProps) Job

Experimental.

type JobAttributes

type JobAttributes struct {
	// The name of the job.
	// Experimental.
	JobName *string `field:"required" json:"jobName" yaml:"jobName"`
	// The IAM role assumed by Glue to run this job.
	// Default: - undefined.
	//
	// Experimental.
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
}

Attributes for importing `Job`.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var role role

jobAttributes := &JobAttributes{
	JobName: jsii.String("jobName"),

	// the properties below are optional
	Role: role,
}

Experimental.

type JobBookmarksEncryption

type JobBookmarksEncryption struct {
	// Encryption mode.
	// Experimental.
	Mode JobBookmarksEncryptionMode `field:"required" json:"mode" yaml:"mode"`
	// The KMS key to be used to encrypt the data.
	// Default: A key will be created if one is not provided.
	//
	// Experimental.
	KmsKey awskms.IKey `field:"optional" json:"kmsKey" yaml:"kmsKey"`
}

Job bookmarks encryption configuration.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

Experimental.

type JobBookmarksEncryptionMode

type JobBookmarksEncryptionMode string

Encryption mode for Job Bookmarks.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

See: https://docs.aws.amazon.com/glue/latest/webapi/API_JobBookmarksEncryption.html#Glue-Type-JobBookmarksEncryption-JobBookmarksEncryptionMode

Experimental.

const (
	// Client-side encryption (CSE) with an AWS KMS key managed by the account owner.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html
	//
	// Experimental.
	JobBookmarksEncryptionMode_CLIENT_SIDE_KMS JobBookmarksEncryptionMode = "CLIENT_SIDE_KMS"
)

type JobExecutable

type JobExecutable interface {
	// Called during Job initialization to get JobExecutableConfig.
	// Experimental.
	Bind() *JobExecutableConfig
}

The executable properties related to the Glue job's GlueVersion, JobType and code.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

Experimental.

func JobExecutable_Of

func JobExecutable_Of(config *JobExecutableConfig) JobExecutable

Create a custom JobExecutable. Experimental.

func JobExecutable_PythonEtl

func JobExecutable_PythonEtl(props *PythonSparkJobExecutableProps) JobExecutable

Create Python executable props for Apache Spark ETL job. Experimental.

func JobExecutable_PythonRay

func JobExecutable_PythonRay(props *PythonRayExecutableProps) JobExecutable

Create Python executable props for Ray jobs. Experimental.

func JobExecutable_PythonShell

func JobExecutable_PythonShell(props *PythonShellExecutableProps) JobExecutable

Create Python executable props for python shell jobs. Experimental.

func JobExecutable_PythonStreaming

func JobExecutable_PythonStreaming(props *PythonSparkJobExecutableProps) JobExecutable

Create Python executable props for Apache Spark Streaming job. Experimental.

func JobExecutable_ScalaEtl

func JobExecutable_ScalaEtl(props *ScalaJobExecutableProps) JobExecutable

Create Scala executable props for Apache Spark ETL job. Experimental.

func JobExecutable_ScalaStreaming

func JobExecutable_ScalaStreaming(props *ScalaJobExecutableProps) JobExecutable

Create Scala executable props for Apache Spark Streaming job. Experimental.

type JobExecutableConfig

type JobExecutableConfig struct {
	// Glue version.
	// See: https://docs.aws.amazon.com/glue/latest/dg/release-notes.html
	//
	// Experimental.
	GlueVersion GlueVersion `field:"required" json:"glueVersion" yaml:"glueVersion"`
	// The language of the job (Scala or Python).
	//
	// Equivalent to a job parameter `--job-language`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Experimental.
	Language JobLanguage `field:"required" json:"language" yaml:"language"`
	// The script that is executed by a job.
	// Experimental.
	Script Code `field:"required" json:"script" yaml:"script"`
	// Specify the type of the job whether it's an Apache Spark ETL or streaming one or if it's a Python shell job.
	// Experimental.
	Type JobType `field:"required" json:"type" yaml:"type"`
	// The Scala class that serves as the entry point for the job.
	//
	// This applies only if your the job langauage is Scala.
	// Equivalent to a job parameter `--class`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no scala className specified.
	//
	// Experimental.
	ClassName *string `field:"optional" json:"className" yaml:"className"`
	// Additional files, such as configuration files that AWS Glue copies to the working directory of your script before executing it.
	//
	// Equivalent to a job parameter `--extra-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no extra files specified.
	//
	// Experimental.
	ExtraFiles *[]Code `field:"optional" json:"extraFiles" yaml:"extraFiles"`
	// Additional Java .jar files that AWS Glue adds to the Java classpath before executing your script. Equivalent to a job parameter `--extra-jars`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no extra jars specified.
	//
	// Experimental.
	ExtraJars *[]Code `field:"optional" json:"extraJars" yaml:"extraJars"`
	// Setting this value to true prioritizes the customer's extra JAR files in the classpath.
	//
	// Equivalent to a job parameter `--user-jars-first`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - extra jars are not prioritized.
	//
	// Experimental.
	ExtraJarsFirst *bool `field:"optional" json:"extraJarsFirst" yaml:"extraJarsFirst"`
	// Additional Python files that AWS Glue adds to the Python path before executing your script.
	//
	// Equivalent to a job parameter `--extra-py-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no extra python files specified.
	//
	// Experimental.
	ExtraPythonFiles *[]Code `field:"optional" json:"extraPythonFiles" yaml:"extraPythonFiles"`
	// The Python version to use.
	// Default: - no python version specified.
	//
	// Experimental.
	PythonVersion PythonVersion `field:"optional" json:"pythonVersion" yaml:"pythonVersion"`
	// The Runtime to use.
	// Default: - no runtime specified.
	//
	// Experimental.
	Runtime Runtime `field:"optional" json:"runtime" yaml:"runtime"`
	// Additional Python modules that AWS Glue adds to the Python path before executing your script.
	//
	// Equivalent to a job parameter `--s3-py-modules`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/author-job-ray-job-parameters.html
	//
	// Default: - no extra python files specified.
	//
	// Experimental.
	S3PythonModules *[]Code `field:"optional" json:"s3PythonModules" yaml:"s3PythonModules"`
}

Result of binding a `JobExecutable` into a `Job`.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdkgluealpha"

var code code
var glueVersion glueVersion
var jobType jobType
var runtime runtime

jobExecutableConfig := &JobExecutableConfig{
	GlueVersion: glueVersion,
	Language: glue_alpha.JobLanguage_SCALA,
	Script: code,
	Type: jobType,

	// the properties below are optional
	ClassName: jsii.String("className"),
	ExtraFiles: []*code{
		code,
	},
	ExtraJars: []*code{
		code,
	},
	ExtraJarsFirst: jsii.Boolean(false),
	ExtraPythonFiles: []*code{
		code,
	},
	PythonVersion: glue_alpha.PythonVersion_TWO,
	Runtime: runtime,
	S3PythonModules: []*code{
		code,
	},
}

Experimental.

type JobLanguage

type JobLanguage string

Runtime language of the Glue job. Experimental.

const (
	// Scala.
	// Experimental.
	JobLanguage_SCALA JobLanguage = "SCALA"
	// Python.
	// Experimental.
	JobLanguage_PYTHON JobLanguage = "PYTHON"
)

type JobProps

type JobProps struct {
	// The job's executable properties.
	// Experimental.
	Executable JobExecutable `field:"required" json:"executable" yaml:"executable"`
	// The `Connection`s used for this job.
	//
	// Connections are used to connect to other AWS Service or resources within a VPC.
	// Default: [] - no connections are added to the job.
	//
	// Experimental.
	Connections *[]IConnection `field:"optional" json:"connections" yaml:"connections"`
	// Enables continuous logging with the specified props.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - continuous logging is disabled.
	//
	// Experimental.
	ContinuousLogging *ContinuousLoggingProps `field:"optional" json:"continuousLogging" yaml:"continuousLogging"`
	// The default arguments for this job, specified as name-value pairs.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html for a list of reserved parameters
	//
	// Default: - no arguments.
	//
	// Experimental.
	DefaultArguments *map[string]*string `field:"optional" json:"defaultArguments" yaml:"defaultArguments"`
	// The description of the job.
	// Default: - no value.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// Enables the collection of metrics for job profiling.
	//
	// Equivalent to a job parameter `--enable-metrics`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no profiling metrics emitted.
	//
	// Experimental.
	EnableProfilingMetrics *bool `field:"optional" json:"enableProfilingMetrics" yaml:"enableProfilingMetrics"`
	// The ExecutionClass whether the job is run with a standard or flexible execution class.
	// See: https://docs.aws.amazon.com/glue/latest/dg/add-job.html
	//
	// Default: - STANDARD.
	//
	// Experimental.
	ExecutionClass ExecutionClass `field:"optional" json:"executionClass" yaml:"executionClass"`
	// The name of the job.
	// Default: - a name is automatically generated.
	//
	// Experimental.
	JobName *string `field:"optional" json:"jobName" yaml:"jobName"`
	// The number of AWS Glue data processing units (DPUs) that can be allocated when this job runs.
	//
	// Cannot be used for Glue version 2.0 and later - workerType and workerCount should be used instead.
	// Default: - 10 when job type is Apache Spark ETL or streaming, 0.0625 when job type is Python shell
	//
	// Experimental.
	MaxCapacity *float64 `field:"optional" json:"maxCapacity" yaml:"maxCapacity"`
	// The maximum number of concurrent runs allowed for the job.
	//
	// An error is returned when this threshold is reached. The maximum value you can specify is controlled by a service limit.
	// Default: 1.
	//
	// Experimental.
	MaxConcurrentRuns *float64 `field:"optional" json:"maxConcurrentRuns" yaml:"maxConcurrentRuns"`
	// The maximum number of times to retry this job after a job run fails.
	// Default: 0.
	//
	// Experimental.
	MaxRetries *float64 `field:"optional" json:"maxRetries" yaml:"maxRetries"`
	// The number of minutes to wait after a job run starts, before sending a job run delay notification.
	// Default: - no delay notifications.
	//
	// Experimental.
	NotifyDelayAfter awscdk.Duration `field:"optional" json:"notifyDelayAfter" yaml:"notifyDelayAfter"`
	// The IAM role assumed by Glue to run this job.
	//
	// If providing a custom role, it needs to trust the Glue service principal (glue.amazonaws.com) and be granted sufficient permissions.
	// See: https://docs.aws.amazon.com/glue/latest/dg/getting-started-access.html
	//
	// Default: - a role is automatically generated.
	//
	// Experimental.
	Role awsiam.IRole `field:"optional" json:"role" yaml:"role"`
	// The `SecurityConfiguration` to use for this job.
	// Default: - no security configuration.
	//
	// Experimental.
	SecurityConfiguration ISecurityConfiguration `field:"optional" json:"securityConfiguration" yaml:"securityConfiguration"`
	// Enables the Spark UI debugging and monitoring with the specified props.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - Spark UI debugging and monitoring is disabled.
	//
	// Experimental.
	SparkUI *SparkUIProps `field:"optional" json:"sparkUI" yaml:"sparkUI"`
	// The tags to add to the resources on which the job runs.
	// Default: {} - no tags.
	//
	// Experimental.
	Tags *map[string]*string `field:"optional" json:"tags" yaml:"tags"`
	// The maximum time that a job run can consume resources before it is terminated and enters TIMEOUT status.
	// Default: cdk.Duration.hours(48)
	//
	// Experimental.
	Timeout awscdk.Duration `field:"optional" json:"timeout" yaml:"timeout"`
	// The number of workers of a defined `WorkerType` that are allocated when a job runs.
	// Default: - differs based on specific Glue version/worker type.
	//
	// Experimental.
	WorkerCount *float64 `field:"optional" json:"workerCount" yaml:"workerCount"`
	// The type of predefined worker that is allocated when a job runs.
	// Default: - differs based on specific Glue version.
	//
	// Experimental.
	WorkerType WorkerType `field:"optional" json:"workerType" yaml:"workerType"`
}

Construction properties for `Job`.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

Experimental.

type JobState

type JobState string

Job states emitted by Glue to CloudWatch Events. See: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/EventTypes.html#glue-event-types for more information.

Experimental.

const (
	// State indicating job run succeeded.
	// Experimental.
	JobState_SUCCEEDED JobState = "SUCCEEDED"
	// State indicating job run failed.
	// Experimental.
	JobState_FAILED JobState = "FAILED"
	// State indicating job run timed out.
	// Experimental.
	JobState_TIMEOUT JobState = "TIMEOUT"
	// State indicating job is starting.
	// Experimental.
	JobState_STARTING JobState = "STARTING"
	// State indicating job is running.
	// Experimental.
	JobState_RUNNING JobState = "RUNNING"
	// State indicating job is stopping.
	// Experimental.
	JobState_STOPPING JobState = "STOPPING"
	// State indicating job stopped.
	// Experimental.
	JobState_STOPPED JobState = "STOPPED"
)

type JobType

type JobType interface {
	// The name of this JobType, as expected by Job resource.
	// Experimental.
	Name() *string
}

The job type.

If you need to use a JobType that doesn't exist as a static member, you can instantiate a `JobType` object, e.g: `JobType.of('other name')`.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

jobType := glue_alpha.JobType_ETL()

Experimental.

func JobType_ETL

func JobType_ETL() JobType

func JobType_Of

func JobType_Of(name *string) JobType

Custom type name. Experimental.

func JobType_PYTHON_SHELL

func JobType_PYTHON_SHELL() JobType

func JobType_RAY

func JobType_RAY() JobType

func JobType_STREAMING

func JobType_STREAMING() JobType

type MetricType

type MetricType string

The Glue CloudWatch metric type. See: https://docs.aws.amazon.com/glue/latest/dg/monitoring-awsglue-with-cloudwatch-metrics.html

Experimental.

const (
	// A value at a point in time.
	// Experimental.
	MetricType_GAUGE MetricType = "GAUGE"
	// An aggregate number.
	// Experimental.
	MetricType_COUNT MetricType = "COUNT"
)

type NumericOverflowHandlingAction

type NumericOverflowHandlingAction string

Specifies the action to perform when ORC data contains an integer (for example, BIGINT or int64) that is larger than the column definition (for example, SMALLINT or int16). See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"numeric_overflow_handling"_

Experimental.

const (
	// Invalid character handling is turned off.
	// Experimental.
	NumericOverflowHandlingAction_DISABLED NumericOverflowHandlingAction = "DISABLED"
	// Cancel the query when the data includes invalid characters.
	// Experimental.
	NumericOverflowHandlingAction_FAIL NumericOverflowHandlingAction = "FAIL"
	// Set invalid characters to null.
	// Experimental.
	NumericOverflowHandlingAction_SET_TO_NULL NumericOverflowHandlingAction = "SET_TO_NULL"
	// Set each value in the row to null.
	// Experimental.
	NumericOverflowHandlingAction_DROP_ROW NumericOverflowHandlingAction = "DROP_ROW"
)

type OrcColumnMappingType

type OrcColumnMappingType string

Specifies how to map columns when the table uses ORC data format. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"orc.schema.resolution"_

Experimental.

const (
	// Map columns by name.
	// Experimental.
	OrcColumnMappingType_NAME OrcColumnMappingType = "NAME"
	// Map columns by position.
	// Experimental.
	OrcColumnMappingType_POSITION OrcColumnMappingType = "POSITION"
)

type OutputFormat

type OutputFormat interface {
	// Experimental.
	ClassName() *string
}

Absolute class name of the Hadoop `OutputFormat` to use when writing table files.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

outputFormat := glue_alpha.NewOutputFormat(jsii.String("className"))

Experimental.

func NewOutputFormat

func NewOutputFormat(className *string) OutputFormat

Experimental.

func OutputFormat_HIVE_IGNORE_KEY_TEXT

func OutputFormat_HIVE_IGNORE_KEY_TEXT() OutputFormat

func OutputFormat_PARQUET

func OutputFormat_PARQUET() OutputFormat

type PartitionIndex

type PartitionIndex struct {
	// The partition key names that comprise the partition index.
	//
	// The names must correspond to a name in the
	// table's partition keys.
	// Experimental.
	KeyNames *[]*string `field:"required" json:"keyNames" yaml:"keyNames"`
	// The name of the partition index.
	// Default: - a name will be generated for you.
	//
	// Experimental.
	IndexName *string `field:"optional" json:"indexName" yaml:"indexName"`
}

Properties of a Partition Index.

Example:

var myTable table

myTable.AddPartitionIndex(&PartitionIndex{
	IndexName: jsii.String("my-index"),
	KeyNames: []*string{
		jsii.String("year"),
	},
})

Experimental.

type PythonRayExecutableProps

type PythonRayExecutableProps struct {
	// Glue version.
	// See: https://docs.aws.amazon.com/glue/latest/dg/release-notes.html
	//
	// Experimental.
	GlueVersion GlueVersion `field:"required" json:"glueVersion" yaml:"glueVersion"`
	// The Python version to use.
	// Experimental.
	PythonVersion PythonVersion `field:"required" json:"pythonVersion" yaml:"pythonVersion"`
	// The script that executes a job.
	// Experimental.
	Script Code `field:"required" json:"script" yaml:"script"`
	// Additional files, such as configuration files that AWS Glue copies to the working directory of your script before executing it.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra files are copied to the working directory.
	//
	// Experimental.
	ExtraFiles *[]Code `field:"optional" json:"extraFiles" yaml:"extraFiles"`
	// Runtime.
	//
	// It is required for Ray jobs.
	// Experimental.
	Runtime Runtime `field:"optional" json:"runtime" yaml:"runtime"`
	// Additional Python modules that AWS Glue adds to the Python path before executing your script.
	//
	// Equivalent to a job parameter `--s3-py-modules`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/author-job-ray-job-parameters.html
	//
	// Default: - no extra python files and argument is not set.
	//
	// Experimental.
	S3PythonModules *[]Code `field:"optional" json:"s3PythonModules" yaml:"s3PythonModules"`
}

Props for creating a Python Ray job executable.

Example:

glue.NewJob(this, jsii.String("RayJob"), &JobProps{
	Executable: glue.JobExecutable_PythonRay(&PythonRayExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		PythonVersion: glue.PythonVersion_THREE_NINE,
		Runtime: glue.Runtime_RAY_TWO_FOUR(),
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
	WorkerType: glue.WorkerType_Z_2X(),
	WorkerCount: jsii.Number(2),
	Description: jsii.String("an example Ray job"),
})

Experimental.

type PythonShellExecutableProps

type PythonShellExecutableProps struct {
	// Glue version.
	// See: https://docs.aws.amazon.com/glue/latest/dg/release-notes.html
	//
	// Experimental.
	GlueVersion GlueVersion `field:"required" json:"glueVersion" yaml:"glueVersion"`
	// The Python version to use.
	// Experimental.
	PythonVersion PythonVersion `field:"required" json:"pythonVersion" yaml:"pythonVersion"`
	// The script that executes a job.
	// Experimental.
	Script Code `field:"required" json:"script" yaml:"script"`
	// Additional files, such as configuration files that AWS Glue copies to the working directory of your script before executing it.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra files are copied to the working directory.
	//
	// Experimental.
	ExtraFiles *[]Code `field:"optional" json:"extraFiles" yaml:"extraFiles"`
	// Additional Python files that AWS Glue adds to the Python path before executing your script.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-py-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no extra python files and argument is not set.
	//
	// Experimental.
	ExtraPythonFiles *[]Code `field:"optional" json:"extraPythonFiles" yaml:"extraPythonFiles"`
	// Runtime.
	//
	// It is required for Ray jobs.
	// Experimental.
	Runtime Runtime `field:"optional" json:"runtime" yaml:"runtime"`
}

Props for creating a Python shell job executable.

Example:

var bucket bucket

glue.NewJob(this, jsii.String("PythonShellJob"), &JobProps{
	Executable: glue.JobExecutable_PythonShell(&PythonShellExecutableProps{
		GlueVersion: glue.GlueVersion_V1_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromBucket(bucket, jsii.String("script.py")),
	}),
	Description: jsii.String("an example Python Shell job"),
})

Experimental.

type PythonSparkJobExecutableProps

type PythonSparkJobExecutableProps struct {
	// Glue version.
	// See: https://docs.aws.amazon.com/glue/latest/dg/release-notes.html
	//
	// Experimental.
	GlueVersion GlueVersion `field:"required" json:"glueVersion" yaml:"glueVersion"`
	// The Python version to use.
	// Experimental.
	PythonVersion PythonVersion `field:"required" json:"pythonVersion" yaml:"pythonVersion"`
	// The script that executes a job.
	// Experimental.
	Script Code `field:"required" json:"script" yaml:"script"`
	// Additional files, such as configuration files that AWS Glue copies to the working directory of your script before executing it.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra files are copied to the working directory.
	//
	// Experimental.
	ExtraFiles *[]Code `field:"optional" json:"extraFiles" yaml:"extraFiles"`
	// Additional Java .jar files that AWS Glue adds to the Java classpath before executing your script. Only individual files are supported, directories are not supported. Equivalent to a job parameter `--extra-jars`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra jars are added to the classpath.
	//
	// Experimental.
	ExtraJars *[]Code `field:"optional" json:"extraJars" yaml:"extraJars"`
	// Setting this value to true prioritizes the customer's extra JAR files in the classpath.
	//
	// Equivalent to a job parameter `--user-jars-first`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: false - priority is not given to user-provided jars.
	//
	// Experimental.
	ExtraJarsFirst *bool `field:"optional" json:"extraJarsFirst" yaml:"extraJarsFirst"`
	// Additional Python files that AWS Glue adds to the Python path before executing your script.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-py-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: - no extra python files and argument is not set.
	//
	// Experimental.
	ExtraPythonFiles *[]Code `field:"optional" json:"extraPythonFiles" yaml:"extraPythonFiles"`
	// Runtime.
	//
	// It is required for Ray jobs.
	// Experimental.
	Runtime Runtime `field:"optional" json:"runtime" yaml:"runtime"`
}

Props for creating a Python Spark (ETL or Streaming) job executable.

Example:

glue.NewJob(this, jsii.String("PythonSparkStreamingJob"), &JobProps{
	Executable: glue.JobExecutable_PythonStreaming(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
	Description: jsii.String("an example Python Streaming job"),
})

Experimental.

type PythonVersion

type PythonVersion string

Python version.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

Experimental.

const (
	// Python 2 (the exact version depends on GlueVersion and JobCommand used).
	// Experimental.
	PythonVersion_TWO PythonVersion = "TWO"
	// Python 3 (the exact version depends on GlueVersion and JobCommand used).
	// Experimental.
	PythonVersion_THREE PythonVersion = "THREE"
	// Python 3.9 (the exact version depends on GlueVersion and JobCommand used).
	// Experimental.
	PythonVersion_THREE_NINE PythonVersion = "THREE_NINE"
)

type Runtime

type Runtime interface {
	// The name of this Runtime.
	// Experimental.
	Name() *string
}

AWS Glue runtime determines the runtime engine of the job.

Example:

glue.NewJob(this, jsii.String("RayJob"), &JobProps{
	Executable: glue.JobExecutable_PythonRay(&PythonRayExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		PythonVersion: glue.PythonVersion_THREE_NINE,
		Runtime: glue.Runtime_RAY_TWO_FOUR(),
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
	WorkerType: glue.WorkerType_Z_2X(),
	WorkerCount: jsii.Number(2),
	Description: jsii.String("an example Ray job"),
})

Experimental.

func Runtime_Of

func Runtime_Of(runtime *string) Runtime

Custom runtime. Experimental.

func Runtime_RAY_TWO_FOUR

func Runtime_RAY_TWO_FOUR() Runtime

type S3Code

type S3Code interface {
	Code
	// Called when the Job is initialized to allow this object to bind.
	// Experimental.
	Bind(_scope constructs.Construct, grantable awsiam.IGrantable) *CodeConfig
}

Glue job Code from an S3 bucket.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var bucket bucket

s3Code := glue_alpha.NewS3Code(bucket, jsii.String("key"))

Experimental.

func AssetCode_FromBucket

func AssetCode_FromBucket(bucket awss3.IBucket, key *string) S3Code

Job code as an S3 object. Experimental.

func Code_FromBucket

func Code_FromBucket(bucket awss3.IBucket, key *string) S3Code

Job code as an S3 object. Experimental.

func NewS3Code

func NewS3Code(bucket awss3.IBucket, key *string) S3Code

Experimental.

func S3Code_FromBucket

func S3Code_FromBucket(bucket awss3.IBucket, key *string) S3Code

Job code as an S3 object. Experimental.

type S3Encryption

type S3Encryption struct {
	// Encryption mode.
	// Experimental.
	Mode S3EncryptionMode `field:"required" json:"mode" yaml:"mode"`
	// The KMS key to be used to encrypt the data.
	// Default: no kms key if mode = S3_MANAGED. A key will be created if one is not provided and mode = KMS.
	//
	// Experimental.
	KmsKey awskms.IKey `field:"optional" json:"kmsKey" yaml:"kmsKey"`
}

S3 encryption configuration.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

Experimental.

type S3EncryptionMode

type S3EncryptionMode string

Encryption mode for S3.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

See: https://docs.aws.amazon.com/glue/latest/webapi/API_S3Encryption.html#Glue-Type-S3Encryption-S3EncryptionMode

Experimental.

const (
	// Server side encryption (SSE) with an Amazon S3-managed key.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html
	//
	// Experimental.
	S3EncryptionMode_S3_MANAGED S3EncryptionMode = "S3_MANAGED"
	// Server-side encryption (SSE) with an AWS KMS key managed by the account owner.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingKMSEncryption.html
	//
	// Experimental.
	S3EncryptionMode_KMS S3EncryptionMode = "KMS"
)

type S3Table

type S3Table interface {
	TableBase
	// S3 bucket in which the table's data resides.
	// Experimental.
	Bucket() awss3.IBucket
	// This table's columns.
	// Experimental.
	Columns() *[]*Column
	// Indicates whether the table's data is compressed or not.
	// Experimental.
	Compressed() *bool
	// Database this table belongs to.
	// Experimental.
	Database() IDatabase
	// Format of this table's data files.
	// Experimental.
	DataFormat() DataFormat
	// The type of encryption enabled for the table.
	// Experimental.
	Encryption() TableEncryption
	// The KMS key used to secure the data if `encryption` is set to `CSE-KMS` or `SSE-KMS`.
	//
	// Otherwise, `undefined`.
	// Experimental.
	EncryptionKey() awskms.IKey
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// The tables' properties associated with the table.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Experimental.
	Parameters() *map[string]*string
	// This table's partition indexes.
	// Experimental.
	PartitionIndexes() *[]*PartitionIndex
	// This table's partition keys if the table is partitioned.
	// Experimental.
	PartitionKeys() *[]*Column
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// S3 Key Prefix under which this table's files are stored in S3.
	// Experimental.
	S3Prefix() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// The tables' storage descriptor properties.
	// Experimental.
	StorageParameters() *[]StorageParameter
	// ARN of this table.
	// Experimental.
	TableArn() *string
	// Name of this table.
	// Experimental.
	TableName() *string
	// Experimental.
	TableResource() awsglue.CfnTable
	// Add a partition index to the table.
	//
	// You can have a maximum of 3 partition
	// indexes to a table. Partition index keys must be a subset of the table's
	// partition keys.
	// See: https://docs.aws.amazon.com/glue/latest/dg/partition-indexes.html
	//
	// Experimental.
	AddPartitionIndex(index *PartitionIndex)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Experimental.
	GenerateS3PrefixForGrant() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Grant the given identity custom permissions.
	// Experimental.
	Grant(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant read permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Experimental.
	GrantRead(grantee awsiam.IGrantable) awsiam.Grant
	// Grant read and write permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Experimental.
	GrantReadWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Grant the given identity custom permissions to ALL underlying resources of the table.
	//
	// Permissions will be granted to the catalog, the database, and the table.
	// Experimental.
	GrantToUnderlyingResources(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant write permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Experimental.
	GrantWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue table that targets a S3 dataset.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
	EnablePartitionFiltering: jsii.Boolean(true),
})

Experimental.

func NewS3Table

func NewS3Table(scope constructs.Construct, id *string, props *S3TableProps) S3Table

Experimental.

type S3TableProps

type S3TableProps struct {
	// Columns of the table.
	// Experimental.
	Columns *[]*Column `field:"required" json:"columns" yaml:"columns"`
	// Database in which to store the table.
	// Experimental.
	Database IDatabase `field:"required" json:"database" yaml:"database"`
	// Storage type of the table's data.
	// Experimental.
	DataFormat DataFormat `field:"required" json:"dataFormat" yaml:"dataFormat"`
	// Indicates whether the table's data is compressed or not.
	// Default: false.
	//
	// Experimental.
	Compressed *bool `field:"optional" json:"compressed" yaml:"compressed"`
	// Description of the table.
	// Default: generated.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// Enables partition filtering.
	// See: https://docs.aws.amazon.com/athena/latest/ug/glue-best-practices.html#glue-best-practices-partition-index
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	EnablePartitionFiltering *bool `field:"optional" json:"enablePartitionFiltering" yaml:"enablePartitionFiltering"`
	// The key/value pairs define properties associated with the table.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	Parameters *map[string]*string `field:"optional" json:"parameters" yaml:"parameters"`
	// Partition indexes on the table.
	//
	// A maximum of 3 indexes
	// are allowed on a table. Keys in the index must be part
	// of the table's partition keys.
	// Default: table has no partition indexes.
	//
	// Experimental.
	PartitionIndexes *[]*PartitionIndex `field:"optional" json:"partitionIndexes" yaml:"partitionIndexes"`
	// Partition columns of the table.
	// Default: table is not partitioned.
	//
	// Experimental.
	PartitionKeys *[]*Column `field:"optional" json:"partitionKeys" yaml:"partitionKeys"`
	// The user-supplied properties for the description of the physical storage of this table.
	//
	// These properties help describe the format of the data that is stored within the crawled data sources.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	//
	// Some keys will be auto-populated by glue crawlers, however, you can override them by specifying the key and value in this property.
	//
	// Example:
	//      declare const glueDatabase: glue.IDatabase;
	//      const table = new glue.Table(this, 'Table', {
	//        storageParameters: [
	//            glue.StorageParameter.skipHeaderLineCount(1),
	//            glue.StorageParameter.compressionType(glue.CompressionType.GZIP),
	//            glue.StorageParameter.custom('foo', 'bar'), // Will have no effect
	//            glue.StorageParameter.custom('separatorChar', ','), // Will describe the separator char used in the data
	//            glue.StorageParameter.custom(glue.StorageParameters.WRITE_PARALLEL, 'off'),
	//        ],
	//        // ...
	//        database: glueDatabase,
	//        columns: [{
	//            name: 'col1',
	//            type: glue.Schema.STRING,
	//        }],
	//        dataFormat: glue.DataFormat.CSV,
	//      });
	//
	// See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	StorageParameters *[]StorageParameter `field:"optional" json:"storageParameters" yaml:"storageParameters"`
	// Indicates whether the table data is stored in subdirectories.
	// Default: false.
	//
	// Experimental.
	StoredAsSubDirectories *bool `field:"optional" json:"storedAsSubDirectories" yaml:"storedAsSubDirectories"`
	// Name of the table.
	// Default: - generated by CDK.
	//
	// Experimental.
	TableName *string `field:"optional" json:"tableName" yaml:"tableName"`
	// S3 bucket in which to store data.
	// Default: one is created for you.
	//
	// Experimental.
	Bucket awss3.IBucket `field:"optional" json:"bucket" yaml:"bucket"`
	// The kind of encryption to secure the data with.
	//
	// You can only provide this option if you are not explicitly passing in a bucket.
	//
	// If you choose `SSE-KMS`, you *can* provide an un-managed KMS key with `encryptionKey`.
	// If you choose `CSE-KMS`, you *must* provide an un-managed KMS key with `encryptionKey`.
	// Default: BucketEncryption.S3_MANAGED
	//
	// Experimental.
	Encryption TableEncryption `field:"optional" json:"encryption" yaml:"encryption"`
	// External KMS key to use for bucket encryption.
	//
	// The `encryption` property must be `SSE-KMS` or `CSE-KMS`.
	// Default: key is managed by KMS.
	//
	// Experimental.
	EncryptionKey awskms.IKey `field:"optional" json:"encryptionKey" yaml:"encryptionKey"`
	// S3 prefix under which table objects are stored.
	// Default: - No prefix. The data will be stored under the root of the bucket.
	//
	// Experimental.
	S3Prefix *string `field:"optional" json:"s3Prefix" yaml:"s3Prefix"`
}

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
	EnablePartitionFiltering: jsii.Boolean(true),
})

Experimental.

type ScalaJobExecutableProps

type ScalaJobExecutableProps struct {
	// The fully qualified Scala class name that serves as the entry point for the job.
	//
	// Equivalent to a job parameter `--class`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Experimental.
	ClassName *string `field:"required" json:"className" yaml:"className"`
	// Glue version.
	// See: https://docs.aws.amazon.com/glue/latest/dg/release-notes.html
	//
	// Experimental.
	GlueVersion GlueVersion `field:"required" json:"glueVersion" yaml:"glueVersion"`
	// The script that executes a job.
	// Experimental.
	Script Code `field:"required" json:"script" yaml:"script"`
	// Additional files, such as configuration files that AWS Glue copies to the working directory of your script before executing it.
	//
	// Only individual files are supported, directories are not supported.
	// Equivalent to a job parameter `--extra-files`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra files are copied to the working directory.
	//
	// Experimental.
	ExtraFiles *[]Code `field:"optional" json:"extraFiles" yaml:"extraFiles"`
	// Additional Java .jar files that AWS Glue adds to the Java classpath before executing your script. Only individual files are supported, directories are not supported. Equivalent to a job parameter `--extra-jars`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: [] - no extra jars are added to the classpath.
	//
	// Experimental.
	ExtraJars *[]Code `field:"optional" json:"extraJars" yaml:"extraJars"`
	// Setting this value to true prioritizes the customer's extra JAR files in the classpath.
	//
	// Equivalent to a job parameter `--user-jars-first`.
	// See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html
	//
	// Default: false - priority is not given to user-provided jars.
	//
	// Experimental.
	ExtraJarsFirst *bool `field:"optional" json:"extraJarsFirst" yaml:"extraJarsFirst"`
	// Runtime.
	//
	// It is required for Ray jobs.
	// Experimental.
	Runtime Runtime `field:"optional" json:"runtime" yaml:"runtime"`
}

Props for creating a Scala Spark (ETL or Streaming) job executable.

Example:

var bucket bucket

glue.NewJob(this, jsii.String("ScalaSparkEtlJob"), &JobProps{
	Executable: glue.JobExecutable_ScalaEtl(&ScalaJobExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		Script: glue.Code_FromBucket(bucket, jsii.String("src/com/example/HelloWorld.scala")),
		ClassName: jsii.String("com.example.HelloWorld"),
		ExtraJars: []code{
			glue.*code_*FromBucket(bucket, jsii.String("jars/HelloWorld.jar")),
		},
	}),
	WorkerType: glue.WorkerType_G_8X(),
	Description: jsii.String("an example Scala ETL job"),
})

Experimental.

type Schema

type Schema interface {
}

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

See: https://docs.aws.amazon.com/athena/latest/ug/data-types.html

Experimental.

func NewSchema

func NewSchema() Schema

Experimental.

type SecurityConfiguration

type SecurityConfiguration interface {
	awscdk.Resource
	ISecurityConfiguration
	// The KMS key used in CloudWatch encryption if it requires a kms key.
	// Experimental.
	CloudWatchEncryptionKey() awskms.IKey
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The KMS key used in job bookmarks encryption if it requires a kms key.
	// Experimental.
	JobBookmarksEncryptionKey() awskms.IKey
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The KMS key used in S3 encryption if it requires a kms key.
	// Experimental.
	S3EncryptionKey() awskms.IKey
	// The name of the security configuration.
	// Experimental.
	SecurityConfigurationName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A security configuration is a set of security properties that can be used by AWS Glue to encrypt data at rest.

The following scenarios show some of the ways that you can use a security configuration. - Attach a security configuration to an AWS Glue crawler to write encrypted Amazon CloudWatch Logs. - Attach a security configuration to an extract, transform, and load (ETL) job to write encrypted Amazon Simple Storage Service (Amazon S3) targets and encrypted CloudWatch Logs. - Attach a security configuration to an ETL job to write its jobs bookmarks as encrypted Amazon S3 data. - Attach a security configuration to a development endpoint to write encrypted Amazon S3 targets.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

Experimental.

func NewSecurityConfiguration

func NewSecurityConfiguration(scope constructs.Construct, id *string, props *SecurityConfigurationProps) SecurityConfiguration

Experimental.

type SecurityConfigurationProps

type SecurityConfigurationProps struct {
	// The encryption configuration for Amazon CloudWatch Logs.
	// Default: no cloudwatch logs encryption.
	//
	// Experimental.
	CloudWatchEncryption *CloudWatchEncryption `field:"optional" json:"cloudWatchEncryption" yaml:"cloudWatchEncryption"`
	// The encryption configuration for Glue Job Bookmarks.
	// Default: no job bookmarks encryption.
	//
	// Experimental.
	JobBookmarksEncryption *JobBookmarksEncryption `field:"optional" json:"jobBookmarksEncryption" yaml:"jobBookmarksEncryption"`
	// The encryption configuration for Amazon Simple Storage Service (Amazon S3) data.
	// Default: no s3 encryption.
	//
	// Experimental.
	S3Encryption *S3Encryption `field:"optional" json:"s3Encryption" yaml:"s3Encryption"`
	// The name of the security configuration.
	// Default: - generated by CDK.
	//
	// Experimental.
	SecurityConfigurationName *string `field:"optional" json:"securityConfigurationName" yaml:"securityConfigurationName"`
}

Constructions properties of `SecurityConfiguration`.

Example:

glue.NewSecurityConfiguration(this, jsii.String("MySecurityConfiguration"), &SecurityConfigurationProps{
	CloudWatchEncryption: &CloudWatchEncryption{
		Mode: glue.CloudWatchEncryptionMode_KMS,
	},
	JobBookmarksEncryption: &JobBookmarksEncryption{
		Mode: glue.JobBookmarksEncryptionMode_CLIENT_SIDE_KMS,
	},
	S3Encryption: &S3Encryption{
		Mode: glue.S3EncryptionMode_KMS,
	},
})

Experimental.

type SerializationLibrary

type SerializationLibrary interface {
	// Experimental.
	ClassName() *string
}

Serialization library to use when serializing/deserializing (SerDe) table records.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

serializationLibrary := glue_alpha.SerializationLibrary_AVRO()

See: https://cwiki.apache.org/confluence/display/Hive/SerDe

Experimental.

func NewSerializationLibrary

func NewSerializationLibrary(className *string) SerializationLibrary

Experimental.

func SerializationLibrary_AVRO

func SerializationLibrary_AVRO() SerializationLibrary

func SerializationLibrary_CLOUDTRAIL

func SerializationLibrary_CLOUDTRAIL() SerializationLibrary

func SerializationLibrary_GROK

func SerializationLibrary_GROK() SerializationLibrary

func SerializationLibrary_HIVE_JSON

func SerializationLibrary_HIVE_JSON() SerializationLibrary

func SerializationLibrary_LAZY_SIMPLE

func SerializationLibrary_LAZY_SIMPLE() SerializationLibrary

func SerializationLibrary_OPENX_JSON

func SerializationLibrary_OPENX_JSON() SerializationLibrary

func SerializationLibrary_OPEN_CSV

func SerializationLibrary_OPEN_CSV() SerializationLibrary

func SerializationLibrary_ORC

func SerializationLibrary_ORC() SerializationLibrary

func SerializationLibrary_PARQUET

func SerializationLibrary_PARQUET() SerializationLibrary

func SerializationLibrary_REGEXP

func SerializationLibrary_REGEXP() SerializationLibrary

type SparkUILoggingLocation

type SparkUILoggingLocation struct {
	// The bucket where the Glue job stores the logs.
	// Default: - a new bucket will be created.
	//
	// Experimental.
	Bucket awss3.IBucket `field:"required" json:"bucket" yaml:"bucket"`
	// The path inside the bucket (objects prefix) where the Glue job stores the logs.
	// Default: - the logs will be written at the root of the bucket.
	//
	// Experimental.
	Prefix *string `field:"optional" json:"prefix" yaml:"prefix"`
}

The Spark UI logging location.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"

var bucket bucket

sparkUILoggingLocation := &SparkUILoggingLocation{
	Bucket: bucket,

	// the properties below are optional
	Prefix: jsii.String("prefix"),
}

See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html

Experimental.

type SparkUIProps

type SparkUIProps struct {
	// Enable Spark UI.
	// Experimental.
	Enabled *bool `field:"required" json:"enabled" yaml:"enabled"`
	// The bucket where the Glue job stores the logs.
	// Default: - a new bucket will be created.
	//
	// Experimental.
	Bucket awss3.IBucket `field:"optional" json:"bucket" yaml:"bucket"`
	// The path inside the bucket (objects prefix) where the Glue job stores the logs.
	//
	// Use format `'foo/bar/'`.
	// Default: - the logs will be written at the root of the bucket.
	//
	// Experimental.
	Prefix *string `field:"optional" json:"prefix" yaml:"prefix"`
}

Properties for enabling Spark UI monitoring feature for Spark-based Glue jobs.

Example:

glue.NewJob(this, jsii.String("EnableSparkUI"), &JobProps{
	JobName: jsii.String("EtlJobWithSparkUIPrefix"),
	SparkUI: &SparkUIProps{
		Enabled: jsii.Boolean(true),
	},
	Executable: glue.JobExecutable_PythonEtl(&PythonSparkJobExecutableProps{
		GlueVersion: glue.GlueVersion_V3_0(),
		PythonVersion: glue.PythonVersion_THREE,
		Script: glue.Code_FromAsset(path.join(__dirname, jsii.String("job-script"), jsii.String("hello_world.py"))),
	}),
})

See: https://docs.aws.amazon.com/glue/latest/dg/aws-glue-programming-etl-glue-arguments.html

Experimental.

type StorageParameter

type StorageParameter interface {
	// Experimental.
	Key() *string
	// Experimental.
	Value() *string
}

A storage parameter. The list of storage parameters available is not exhaustive and other keys may be used.

If you would like to specify a storage parameter that is not available as a static member of this class, use the `StorageParameter.custom` method.

The list of storage parameters currently known within the CDK is listed.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	StorageParameters: []storageParameter{
		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
		glue.*storageParameter_Custom(jsii.String("separatorChar"), jsii.String(",")),
	},
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_

Experimental.

func NewStorageParameter

func NewStorageParameter(key *string, value *string) StorageParameter

Experimental.

func StorageParameter_ColumnCountMismatchHandling

func StorageParameter_ColumnCountMismatchHandling(value ColumnCountMismatchHandlingAction) StorageParameter

Identifies if the file contains less or more values for a row than the number of columns specified in the external table definition.

This property is only available for an uncompressed text file format. Experimental.

func StorageParameter_CompressionType

func StorageParameter_CompressionType(value CompressionType) StorageParameter

The type of compression used on the table, when the file name does not contain an extension.

This value overrides the compression type specified through the extension. Experimental.

func StorageParameter_Custom

func StorageParameter_Custom(key *string, value interface{}) StorageParameter

A custom storage parameter. Experimental.

func StorageParameter_DataCleansingEnabled

func StorageParameter_DataCleansingEnabled(value *bool) StorageParameter

Determines whether data handling is on for the table. Experimental.

func StorageParameter_InvalidCharHandling

func StorageParameter_InvalidCharHandling(value InvalidCharHandlingAction) StorageParameter

Specifies the action to perform when query results contain invalid UTF-8 character values. Experimental.

func StorageParameter_NumRows

func StorageParameter_NumRows(value *float64) StorageParameter

A property that sets the numRows value for the table definition.

To explicitly update an external table's statistics, set the numRows property to indicate the size of the table. Amazon Redshift doesn't analyze external tables to generate the table statistics that the query optimizer uses to generate a query plan. If table statistics aren't set for an external table, Amazon Redshift generates a query execution plan based on an assumption that external tables are the larger tables and local tables are the smaller tables. Experimental.

func StorageParameter_NumericOverflowHandling

func StorageParameter_NumericOverflowHandling(value NumericOverflowHandlingAction) StorageParameter

Specifies the action to perform when ORC data contains an integer (for example, BIGINT or int64) that is larger than the column definition (for example, SMALLINT or int16). Experimental.

func StorageParameter_OrcSchemaResolution

func StorageParameter_OrcSchemaResolution(value OrcColumnMappingType) StorageParameter

A property that sets the column mapping type for tables that use ORC data format.

This property is ignored for other data formats. If this property is omitted, columns are mapped by `OrcColumnMappingType.NAME` by default. Default: OrcColumnMappingType.NAME

Experimental.

func StorageParameter_ReplacementChar

func StorageParameter_ReplacementChar(value *string) StorageParameter

Specifies the replacement character to use when you set `INVALID_CHAR_HANDLING` to `REPLACE`. Experimental.

func StorageParameter_SerializationNullFormat

func StorageParameter_SerializationNullFormat(value *string) StorageParameter

A property that sets number of rows to skip at the beginning of each source file. Experimental.

func StorageParameter_SkipHeaderLineCount

func StorageParameter_SkipHeaderLineCount(value *float64) StorageParameter

The number of rows to skip at the top of a CSV file when the table is being created. Experimental.

func StorageParameter_SurplusBytesHandling

func StorageParameter_SurplusBytesHandling(value SurplusBytesHandlingAction) StorageParameter

Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARBYTE data.

By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column. Experimental.

func StorageParameter_SurplusCharHandling

func StorageParameter_SurplusCharHandling(value SurplusCharHandlingAction) StorageParameter

Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARCHAR, CHAR, or string data.

By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column. Experimental.

func StorageParameter_WriteKmsKeyId

func StorageParameter_WriteKmsKeyId(value *string) StorageParameter

You can specify an AWS Key Management Service key to enable Server–Side Encryption (SSE) for Amazon S3 objects. Experimental.

func StorageParameter_WriteMaxFileSizeMb

func StorageParameter_WriteMaxFileSizeMb(value *float64) StorageParameter

A property that sets the maximum size (in MB) of each file written to Amazon S3 by CREATE EXTERNAL TABLE AS.

The size must be a valid integer between 5 and 6200. The default maximum file size is 6,200 MB. This table property also applies to any subsequent INSERT statement into the same external table. Experimental.

func StorageParameter_WriteParallel

func StorageParameter_WriteParallel(value WriteParallel) StorageParameter

A property that sets whether CREATE EXTERNAL TABLE AS should write data in parallel.

When 'write.parallel' is set to off, CREATE EXTERNAL TABLE AS writes to one or more data files serially onto Amazon S3. This table property also applies to any subsequent INSERT statement into the same external table. Default: WriteParallel.ON

Experimental.

type StorageParameters

type StorageParameters string

The storage parameter keys that are currently known, this list is not exhaustive and other keys may be used.

Example:

var glueDatabase iDatabase

table := glue.NewTable(this, jsii.String("Table"), &S3TableProps{
	StorageParameters: []storageParameter{
		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
		glue.*storageParameter_Custom(jsii.String("foo"), jsii.String("bar")),
		glue.*storageParameter_*Custom(jsii.String("separatorChar"), jsii.String(",")),
		glue.*storageParameter_*Custom(glue.StorageParameters_WRITE_PARALLEL, jsii.String("off")),
	},
	// ...
	Database: glueDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_CSV(),
})

Experimental.

const (
	// The number of rows to skip at the top of a CSV file when the table is being created.
	// Experimental.
	StorageParameters_SKIP_HEADER_LINE_COUNT StorageParameters = "SKIP_HEADER_LINE_COUNT"
	// Determines whether data handling is on for the table.
	// Experimental.
	StorageParameters_DATA_CLEANSING_ENABLED StorageParameters = "DATA_CLEANSING_ENABLED"
	// The type of compression used on the table, when the file name does not contain an extension.
	//
	// This value overrides the compression type specified through the extension.
	// Experimental.
	StorageParameters_COMPRESSION_TYPE StorageParameters = "COMPRESSION_TYPE"
	// Specifies the action to perform when query results contain invalid UTF-8 character values.
	// Experimental.
	StorageParameters_INVALID_CHAR_HANDLING StorageParameters = "INVALID_CHAR_HANDLING"
	// Specifies the replacement character to use when you set `INVALID_CHAR_HANDLING` to `REPLACE`.
	// Experimental.
	StorageParameters_REPLACEMENT_CHAR StorageParameters = "REPLACEMENT_CHAR"
	// Specifies the action to perform when ORC data contains an integer (for example, BIGINT or int64) that is larger than the column definition (for example, SMALLINT or int16).
	// Experimental.
	StorageParameters_NUMERIC_OVERFLOW_HANDLING StorageParameters = "NUMERIC_OVERFLOW_HANDLING"
	// Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARBYTE data.
	//
	// By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column.
	// Experimental.
	StorageParameters_SURPLUS_BYTES_HANDLING StorageParameters = "SURPLUS_BYTES_HANDLING"
	// Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARCHAR, CHAR, or string data.
	//
	// By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column.
	// Experimental.
	StorageParameters_SURPLUS_CHAR_HANDLING StorageParameters = "SURPLUS_CHAR_HANDLING"
	// Identifies if the file contains less or more values for a row than the number of columns specified in the external table definition.
	//
	// This property is only available for an uncompressed text file format.
	// Experimental.
	StorageParameters_COLUMN_COUNT_MISMATCH_HANDLING StorageParameters = "COLUMN_COUNT_MISMATCH_HANDLING"
	// A property that sets the numRows value for the table definition.
	//
	// To explicitly update an external table's statistics, set the numRows property to indicate the size of the table. Amazon Redshift doesn't analyze external tables to generate the table statistics that the query optimizer uses to generate a query plan. If table statistics aren't set for an external table, Amazon Redshift generates a query execution plan based on an assumption that external tables are the larger tables and local tables are the smaller tables.
	// Experimental.
	StorageParameters_NUM_ROWS StorageParameters = "NUM_ROWS"
	// A property that sets number of rows to skip at the beginning of each source file.
	// Experimental.
	StorageParameters_SERIALIZATION_NULL_FORMAT StorageParameters = "SERIALIZATION_NULL_FORMAT"
	// A property that sets the column mapping type for tables that use ORC data format.
	//
	// This property is ignored for other data formats.
	// Experimental.
	StorageParameters_ORC_SCHEMA_RESOLUTION StorageParameters = "ORC_SCHEMA_RESOLUTION"
	// A property that sets whether CREATE EXTERNAL TABLE AS should write data in parallel.
	//
	// When 'write.parallel' is set to off, CREATE EXTERNAL TABLE AS writes to one or more data files serially onto Amazon S3. This table property also applies to any subsequent INSERT statement into the same external table.
	// Experimental.
	StorageParameters_WRITE_PARALLEL StorageParameters = "WRITE_PARALLEL"
	// A property that sets the maximum size (in MB) of each file written to Amazon S3 by CREATE EXTERNAL TABLE AS.
	//
	// The size must be a valid integer between 5 and 6200. The default maximum file size is 6,200 MB. This table property also applies to any subsequent INSERT statement into the same external table.
	// Experimental.
	StorageParameters_WRITE_MAX_FILESIZE_MB StorageParameters = "WRITE_MAX_FILESIZE_MB"
	// You can specify an AWS Key Management Service key to enable Server–Side Encryption (SSE) for Amazon S3 objects.
	// Experimental.
	StorageParameters_WRITE_KMS_KEY_ID StorageParameters = "WRITE_KMS_KEY_ID"
)

type SurplusBytesHandlingAction

type SurplusBytesHandlingAction string

Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARBYTE data.

By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"surplus_bytes_handling"_

Experimental.

const (
	// Replaces data that exceeds the column width with null.
	// Experimental.
	SurplusBytesHandlingAction_SET_TO_NULL SurplusBytesHandlingAction = "SET_TO_NULL"
	// Doesn't perform surplus byte handling.
	// Experimental.
	SurplusBytesHandlingAction_DISABLED SurplusBytesHandlingAction = "DISABLED"
	// Cancels queries that return data exceeding the column width.
	// Experimental.
	SurplusBytesHandlingAction_FAIL SurplusBytesHandlingAction = "FAIL"
	// Drop all rows that contain data exceeding column width.
	// Experimental.
	SurplusBytesHandlingAction_DROP_ROW SurplusBytesHandlingAction = "DROP_ROW"
	// Removes the characters that exceed the maximum number of characters defined for the column.
	// Experimental.
	SurplusBytesHandlingAction_TRUNCATE SurplusBytesHandlingAction = "TRUNCATE"
)

type SurplusCharHandlingAction

type SurplusCharHandlingAction string

Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARCHAR, CHAR, or string data.

By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"surplus_char_handling"_

Experimental.

const (
	// Replaces data that exceeds the column width with null.
	// Experimental.
	SurplusCharHandlingAction_SET_TO_NULL SurplusCharHandlingAction = "SET_TO_NULL"
	// Doesn't perform surplus character handling.
	// Experimental.
	SurplusCharHandlingAction_DISABLED SurplusCharHandlingAction = "DISABLED"
	// Cancels queries that return data exceeding the column width.
	// Experimental.
	SurplusCharHandlingAction_FAIL SurplusCharHandlingAction = "FAIL"
	// Replaces each value in the row with null.
	// Experimental.
	SurplusCharHandlingAction_DROP_ROW SurplusCharHandlingAction = "DROP_ROW"
	// Removes the characters that exceed the maximum number of characters defined for the column.
	// Experimental.
	SurplusCharHandlingAction_TRUNCATE SurplusCharHandlingAction = "TRUNCATE"
)

type Table deprecated

type Table interface {
	S3Table
	// S3 bucket in which the table's data resides.
	// Deprecated: Use {@link S3Table } instead.
	Bucket() awss3.IBucket
	// This table's columns.
	// Deprecated: Use {@link S3Table } instead.
	Columns() *[]*Column
	// Indicates whether the table's data is compressed or not.
	// Deprecated: Use {@link S3Table } instead.
	Compressed() *bool
	// Database this table belongs to.
	// Deprecated: Use {@link S3Table } instead.
	Database() IDatabase
	// Format of this table's data files.
	// Deprecated: Use {@link S3Table } instead.
	DataFormat() DataFormat
	// The type of encryption enabled for the table.
	// Deprecated: Use {@link S3Table } instead.
	Encryption() TableEncryption
	// The KMS key used to secure the data if `encryption` is set to `CSE-KMS` or `SSE-KMS`.
	//
	// Otherwise, `undefined`.
	// Deprecated: Use {@link S3Table } instead.
	EncryptionKey() awskms.IKey
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Deprecated: Use {@link S3Table } instead.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Deprecated: Use {@link S3Table } instead.
	Node() constructs.Node
	// The tables' properties associated with the table.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Deprecated: Use {@link S3Table } instead.
	Parameters() *map[string]*string
	// This table's partition indexes.
	// Deprecated: Use {@link S3Table } instead.
	PartitionIndexes() *[]*PartitionIndex
	// This table's partition keys if the table is partitioned.
	// Deprecated: Use {@link S3Table } instead.
	PartitionKeys() *[]*Column
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Deprecated: Use {@link S3Table } instead.
	PhysicalName() *string
	// S3 Key Prefix under which this table's files are stored in S3.
	// Deprecated: Use {@link S3Table } instead.
	S3Prefix() *string
	// The stack in which this resource is defined.
	// Deprecated: Use {@link S3Table } instead.
	Stack() awscdk.Stack
	// The tables' storage descriptor properties.
	// Deprecated: Use {@link S3Table } instead.
	StorageParameters() *[]StorageParameter
	// ARN of this table.
	// Deprecated: Use {@link S3Table } instead.
	TableArn() *string
	// Name of this table.
	// Deprecated: Use {@link S3Table } instead.
	TableName() *string
	// Deprecated: Use {@link S3Table } instead.
	TableResource() awsglue.CfnTable
	// Add a partition index to the table.
	//
	// You can have a maximum of 3 partition
	// indexes to a table. Partition index keys must be a subset of the table's
	// partition keys.
	// See: https://docs.aws.amazon.com/glue/latest/dg/partition-indexes.html
	//
	// Deprecated: Use {@link S3Table } instead.
	AddPartitionIndex(index *PartitionIndex)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Deprecated: Use {@link S3Table } instead.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Deprecated: Use {@link S3Table } instead.
	GeneratePhysicalName() *string
	// Deprecated: Use {@link S3Table } instead.
	GenerateS3PrefixForGrant() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Deprecated: Use {@link S3Table } instead.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Deprecated: Use {@link S3Table } instead.
	GetResourceNameAttribute(nameAttr *string) *string
	// Grant the given identity custom permissions.
	// Deprecated: Use {@link S3Table } instead.
	Grant(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant read permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Deprecated: Use {@link S3Table } instead.
	GrantRead(grantee awsiam.IGrantable) awsiam.Grant
	// Grant read and write permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Deprecated: Use {@link S3Table } instead.
	GrantReadWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Grant the given identity custom permissions to ALL underlying resources of the table.
	//
	// Permissions will be granted to the catalog, the database, and the table.
	// Deprecated: Use {@link S3Table } instead.
	GrantToUnderlyingResources(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Grant write permissions to the table and the underlying data stored in S3 to an IAM principal.
	// Deprecated: Use {@link S3Table } instead.
	GrantWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Returns a string representation of this construct.
	// Deprecated: Use {@link S3Table } instead.
	ToString() *string
}

A Glue table.

Example:

var glueDatabase iDatabase

table := glue.NewTable(this, jsii.String("Table"), &S3TableProps{
	StorageParameters: []storageParameter{
		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
		glue.*storageParameter_Custom(jsii.String("foo"), jsii.String("bar")),
		glue.*storageParameter_*Custom(jsii.String("separatorChar"), jsii.String(",")),
		glue.*storageParameter_*Custom(glue.StorageParameters_WRITE_PARALLEL, jsii.String("off")),
	},
	// ...
	Database: glueDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_CSV(),
})

Deprecated: Use {@link S3Table } instead.

func NewTable deprecated

func NewTable(scope constructs.Construct, id *string, props *S3TableProps) Table

Deprecated: Use {@link S3Table } instead.

type TableAttributes

type TableAttributes struct {
	// Experimental.
	TableArn *string `field:"required" json:"tableArn" yaml:"tableArn"`
	// Experimental.
	TableName *string `field:"required" json:"tableName" yaml:"tableName"`
}

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

tableAttributes := &TableAttributes{
	TableArn: jsii.String("tableArn"),
	TableName: jsii.String("tableName"),
}

Experimental.

type TableBase

type TableBase interface {
	awscdk.Resource
	ITable
	// This table's columns.
	// Experimental.
	Columns() *[]*Column
	// Indicates whether the table's data is compressed or not.
	// Experimental.
	Compressed() *bool
	// Database this table belongs to.
	// Experimental.
	Database() IDatabase
	// Format of this table's data files.
	// Experimental.
	DataFormat() DataFormat
	// The environment this resource belongs to.
	//
	// For resources that are created and managed by the CDK
	// (generally, those created by creating new class instances like Role, Bucket, etc.),
	// this is always the same as the environment of the stack they belong to;
	// however, for imported resources
	// (those obtained from static methods like fromRoleArn, fromBucketName, etc.),
	// that might be different than the stack they were imported into.
	// Experimental.
	Env() *awscdk.ResourceEnvironment
	// The tree node.
	// Experimental.
	Node() constructs.Node
	// The tables' properties associated with the table.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Experimental.
	Parameters() *map[string]*string
	// Experimental.
	PartitionIndexes() *[]*PartitionIndex
	// This table's partition keys if the table is partitioned.
	// Experimental.
	PartitionKeys() *[]*Column
	// Returns a string-encoded token that resolves to the physical name that should be passed to the CloudFormation resource.
	//
	// This value will resolve to one of the following:
	// - a concrete value (e.g. `"my-awesome-bucket"`)
	// - `undefined`, when a name should be generated by CloudFormation
	// - a concrete name generated automatically during synthesis, in
	//   cross-environment scenarios.
	// Experimental.
	PhysicalName() *string
	// The stack in which this resource is defined.
	// Experimental.
	Stack() awscdk.Stack
	// The tables' storage descriptor properties.
	// Experimental.
	StorageParameters() *[]StorageParameter
	// Experimental.
	TableArn() *string
	// Experimental.
	TableName() *string
	// Experimental.
	TableResource() awsglue.CfnTable
	// Add a partition index to the table.
	//
	// You can have a maximum of 3 partition
	// indexes to a table. Partition index keys must be a subset of the table's
	// partition keys.
	// See: https://docs.aws.amazon.com/glue/latest/dg/partition-indexes.html
	//
	// Experimental.
	AddPartitionIndex(index *PartitionIndex)
	// Apply the given removal policy to this resource.
	//
	// The Removal Policy controls what happens to this resource when it stops
	// being managed by CloudFormation, either because you've removed it from the
	// CDK application or because you've made a change that requires the resource
	// to be replaced.
	//
	// The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS
	// account for data recovery and cleanup later (`RemovalPolicy.RETAIN`).
	// Experimental.
	ApplyRemovalPolicy(policy awscdk.RemovalPolicy)
	// Experimental.
	GeneratePhysicalName() *string
	// Returns an environment-sensitive token that should be used for the resource's "ARN" attribute (e.g. `bucket.bucketArn`).
	//
	// Normally, this token will resolve to `arnAttr`, but if the resource is
	// referenced across environments, `arnComponents` will be used to synthesize
	// a concrete ARN with the resource's physical name. Make sure to reference
	// `this.physicalName` in `arnComponents`.
	// Experimental.
	GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string
	// Returns an environment-sensitive token that should be used for the resource's "name" attribute (e.g. `bucket.bucketName`).
	//
	// Normally, this token will resolve to `nameAttr`, but if the resource is
	// referenced across environments, it will be resolved to `this.physicalName`,
	// which will be a concrete name.
	// Experimental.
	GetResourceNameAttribute(nameAttr *string) *string
	// Grant the given identity custom permissions.
	// Experimental.
	Grant(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Experimental.
	GrantRead(grantee awsiam.IGrantable) awsiam.Grant
	// Experimental.
	GrantReadWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Grant the given identity custom permissions to ALL underlying resources of the table.
	//
	// Permissions will be granted to the catalog, the database, and the table.
	// Experimental.
	GrantToUnderlyingResources(grantee awsiam.IGrantable, actions *[]*string) awsiam.Grant
	// Experimental.
	GrantWrite(grantee awsiam.IGrantable) awsiam.Grant
	// Returns a string representation of this construct.
	// Experimental.
	ToString() *string
}

A Glue table.

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

tableBase := glue_alpha.TableBase_FromTableArn(this, jsii.String("MyTableBase"), jsii.String("tableArn"))

Experimental.

type TableBaseProps

type TableBaseProps struct {
	// Columns of the table.
	// Experimental.
	Columns *[]*Column `field:"required" json:"columns" yaml:"columns"`
	// Database in which to store the table.
	// Experimental.
	Database IDatabase `field:"required" json:"database" yaml:"database"`
	// Storage type of the table's data.
	// Experimental.
	DataFormat DataFormat `field:"required" json:"dataFormat" yaml:"dataFormat"`
	// Indicates whether the table's data is compressed or not.
	// Default: false.
	//
	// Experimental.
	Compressed *bool `field:"optional" json:"compressed" yaml:"compressed"`
	// Description of the table.
	// Default: generated.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// Enables partition filtering.
	// See: https://docs.aws.amazon.com/athena/latest/ug/glue-best-practices.html#glue-best-practices-partition-index
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	EnablePartitionFiltering *bool `field:"optional" json:"enablePartitionFiltering" yaml:"enablePartitionFiltering"`
	// The key/value pairs define properties associated with the table.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	Parameters *map[string]*string `field:"optional" json:"parameters" yaml:"parameters"`
	// Partition indexes on the table.
	//
	// A maximum of 3 indexes
	// are allowed on a table. Keys in the index must be part
	// of the table's partition keys.
	// Default: table has no partition indexes.
	//
	// Experimental.
	PartitionIndexes *[]*PartitionIndex `field:"optional" json:"partitionIndexes" yaml:"partitionIndexes"`
	// Partition columns of the table.
	// Default: table is not partitioned.
	//
	// Experimental.
	PartitionKeys *[]*Column `field:"optional" json:"partitionKeys" yaml:"partitionKeys"`
	// The user-supplied properties for the description of the physical storage of this table.
	//
	// These properties help describe the format of the data that is stored within the crawled data sources.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	//
	// Some keys will be auto-populated by glue crawlers, however, you can override them by specifying the key and value in this property.
	//
	// Example:
	//   var glueDatabase iDatabase
	//
	//   table := glue.NewTable(this, jsii.String("Table"), &S3TableProps{
	//   	StorageParameters: []storageParameter{
	//   		glue.*storageParameter_SkipHeaderLineCount(jsii.Number(1)),
	//   		glue.*storageParameter_CompressionType(glue.CompressionType_GZIP),
	//   		glue.*storageParameter_Custom(jsii.String("foo"), jsii.String("bar")),
	//   		glue.*storageParameter_*Custom(jsii.String("separatorChar"), jsii.String(",")),
	//   		glue.*storageParameter_*Custom(glue.StorageParameters_WRITE_PARALLEL, jsii.String("off")),
	//   	},
	//   	// ...
	//   	Database: glueDatabase,
	//   	Columns: []column{
	//   		&column{
	//   			Name: jsii.String("col1"),
	//   			Type: glue.Schema_STRING(),
	//   		},
	//   	},
	//   	DataFormat: glue.DataFormat_CSV(),
	//   })
	//
	// See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	StorageParameters *[]StorageParameter `field:"optional" json:"storageParameters" yaml:"storageParameters"`
	// Indicates whether the table data is stored in subdirectories.
	// Default: false.
	//
	// Experimental.
	StoredAsSubDirectories *bool `field:"optional" json:"storedAsSubDirectories" yaml:"storedAsSubDirectories"`
	// Name of the table.
	// Default: - generated by CDK.
	//
	// Experimental.
	TableName *string `field:"optional" json:"tableName" yaml:"tableName"`
}

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"

var database database
var dataFormat dataFormat
var storageParameter storageParameter

tableBaseProps := &TableBaseProps{
	Columns: []column{
		&column{
			Name: jsii.String("name"),
			Type: &Type{
				InputString: jsii.String("inputString"),
				IsPrimitive: jsii.Boolean(false),
			},

			// the properties below are optional
			Comment: jsii.String("comment"),
		},
	},
	Database: database,
	DataFormat: dataFormat,

	// the properties below are optional
	Compressed: jsii.Boolean(false),
	Description: jsii.String("description"),
	EnablePartitionFiltering: jsii.Boolean(false),
	Parameters: map[string]*string{
		"parametersKey": jsii.String("parameters"),
	},
	PartitionIndexes: []partitionIndex{
		&partitionIndex{
			KeyNames: []*string{
				jsii.String("keyNames"),
			},

			// the properties below are optional
			IndexName: jsii.String("indexName"),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("name"),
			Type: &Type{
				InputString: jsii.String("inputString"),
				IsPrimitive: jsii.Boolean(false),
			},

			// the properties below are optional
			Comment: jsii.String("comment"),
		},
	},
	StorageParameters: []*storageParameter{
		storageParameter,
	},
	StoredAsSubDirectories: jsii.Boolean(false),
	TableName: jsii.String("tableName"),
}

Experimental.

type TableEncryption

type TableEncryption string

Encryption options for a Table.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Encryption: glue.TableEncryption_S3_MANAGED,
	// ...
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

See: https://docs.aws.amazon.com/athena/latest/ug/encryption.html

Experimental.

const (
	// Server side encryption (SSE) with an Amazon S3-managed key.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html
	//
	// Experimental.
	TableEncryption_S3_MANAGED TableEncryption = "S3_MANAGED"
	// Server-side encryption (SSE) with an AWS KMS key managed by the account owner.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingKMSEncryption.html
	//
	// Experimental.
	TableEncryption_KMS TableEncryption = "KMS"
	// Server-side encryption (SSE) with an AWS KMS key managed by the KMS service.
	// Experimental.
	TableEncryption_KMS_MANAGED TableEncryption = "KMS_MANAGED"
	// Client-side encryption (CSE) with an AWS KMS key managed by the account owner.
	// See: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html
	//
	// Experimental.
	TableEncryption_CLIENT_SIDE_KMS TableEncryption = "CLIENT_SIDE_KMS"
)

type TableProps

type TableProps struct {
	// Columns of the table.
	// Experimental.
	Columns *[]*Column `field:"required" json:"columns" yaml:"columns"`
	// Database in which to store the table.
	// Experimental.
	Database IDatabase `field:"required" json:"database" yaml:"database"`
	// Storage type of the table's data.
	// Experimental.
	DataFormat DataFormat `field:"required" json:"dataFormat" yaml:"dataFormat"`
	// Indicates whether the table's data is compressed or not.
	// Default: false.
	//
	// Experimental.
	Compressed *bool `field:"optional" json:"compressed" yaml:"compressed"`
	// Description of the table.
	// Default: generated.
	//
	// Experimental.
	Description *string `field:"optional" json:"description" yaml:"description"`
	// Enables partition filtering.
	// See: https://docs.aws.amazon.com/athena/latest/ug/glue-best-practices.html#glue-best-practices-partition-index
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	EnablePartitionFiltering *bool `field:"optional" json:"enablePartitionFiltering" yaml:"enablePartitionFiltering"`
	// The key/value pairs define properties associated with the table.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	// See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-table-tableinput.html#cfn-glue-table-tableinput-parameters
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	Parameters *map[string]*string `field:"optional" json:"parameters" yaml:"parameters"`
	// Partition indexes on the table.
	//
	// A maximum of 3 indexes
	// are allowed on a table. Keys in the index must be part
	// of the table's partition keys.
	// Default: table has no partition indexes.
	//
	// Experimental.
	PartitionIndexes *[]*PartitionIndex `field:"optional" json:"partitionIndexes" yaml:"partitionIndexes"`
	// Partition columns of the table.
	// Default: table is not partitioned.
	//
	// Experimental.
	PartitionKeys *[]*Column `field:"optional" json:"partitionKeys" yaml:"partitionKeys"`
	// The user-supplied properties for the description of the physical storage of this table.
	//
	// These properties help describe the format of the data that is stored within the crawled data sources.
	//
	// The key/value pairs that are allowed to be submitted are not limited, however their functionality is not guaranteed.
	//
	// Some keys will be auto-populated by glue crawlers, however, you can override them by specifying the key and value in this property.
	//
	// Example:
	//      declare const glueDatabase: glue.IDatabase;
	//      const table = new glue.Table(this, 'Table', {
	//        storageParameters: [
	//            glue.StorageParameter.skipHeaderLineCount(1),
	//            glue.StorageParameter.compressionType(glue.CompressionType.GZIP),
	//            glue.StorageParameter.custom('foo', 'bar'), // Will have no effect
	//            glue.StorageParameter.custom('separatorChar', ','), // Will describe the separator char used in the data
	//            glue.StorageParameter.custom(glue.StorageParameters.WRITE_PARALLEL, 'off'),
	//        ],
	//        // ...
	//        database: glueDatabase,
	//        columns: [{
	//            name: 'col1',
	//            type: glue.Schema.STRING,
	//        }],
	//        dataFormat: glue.DataFormat.CSV,
	//      });
	//
	// See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_
	//
	// Default: - The parameter is not defined.
	//
	// Experimental.
	StorageParameters *[]StorageParameter `field:"optional" json:"storageParameters" yaml:"storageParameters"`
	// Indicates whether the table data is stored in subdirectories.
	// Default: false.
	//
	// Experimental.
	StoredAsSubDirectories *bool `field:"optional" json:"storedAsSubDirectories" yaml:"storedAsSubDirectories"`
	// Name of the table.
	// Default: - generated by CDK.
	//
	// Experimental.
	TableName *string `field:"optional" json:"tableName" yaml:"tableName"`
	// S3 bucket in which to store data.
	// Default: one is created for you.
	//
	// Experimental.
	Bucket awss3.IBucket `field:"optional" json:"bucket" yaml:"bucket"`
	// The kind of encryption to secure the data with.
	//
	// You can only provide this option if you are not explicitly passing in a bucket.
	//
	// If you choose `SSE-KMS`, you *can* provide an un-managed KMS key with `encryptionKey`.
	// If you choose `CSE-KMS`, you *must* provide an un-managed KMS key with `encryptionKey`.
	// Default: BucketEncryption.S3_MANAGED
	//
	// Experimental.
	Encryption TableEncryption `field:"optional" json:"encryption" yaml:"encryption"`
	// External KMS key to use for bucket encryption.
	//
	// The `encryption` property must be `SSE-KMS` or `CSE-KMS`.
	// Default: key is managed by KMS.
	//
	// Experimental.
	EncryptionKey awskms.IKey `field:"optional" json:"encryptionKey" yaml:"encryptionKey"`
	// S3 prefix under which table objects are stored.
	// Default: - No prefix. The data will be stored under the root of the bucket.
	//
	// Experimental.
	S3Prefix *string `field:"optional" json:"s3Prefix" yaml:"s3Prefix"`
}

Example:

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import glue_alpha "github.com/aws/aws-cdk-go/awscdkgluealpha"
import "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

var bucket bucket
var database database
var dataFormat dataFormat
var key key
var storageParameter storageParameter

tableProps := &TableProps{
	Columns: []column{
		&column{
			Name: jsii.String("name"),
			Type: &Type{
				InputString: jsii.String("inputString"),
				IsPrimitive: jsii.Boolean(false),
			},

			// the properties below are optional
			Comment: jsii.String("comment"),
		},
	},
	Database: database,
	DataFormat: dataFormat,

	// the properties below are optional
	Bucket: bucket,
	Compressed: jsii.Boolean(false),
	Description: jsii.String("description"),
	EnablePartitionFiltering: jsii.Boolean(false),
	Encryption: glue_alpha.TableEncryption_S3_MANAGED,
	EncryptionKey: key,
	Parameters: map[string]*string{
		"parametersKey": jsii.String("parameters"),
	},
	PartitionIndexes: []partitionIndex{
		&partitionIndex{
			KeyNames: []*string{
				jsii.String("keyNames"),
			},

			// the properties below are optional
			IndexName: jsii.String("indexName"),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("name"),
			Type: &Type{
				InputString: jsii.String("inputString"),
				IsPrimitive: jsii.Boolean(false),
			},

			// the properties below are optional
			Comment: jsii.String("comment"),
		},
	},
	S3Prefix: jsii.String("s3Prefix"),
	StorageParameters: []*storageParameter{
		storageParameter,
	},
	StoredAsSubDirectories: jsii.Boolean(false),
	TableName: jsii.String("tableName"),
}

Experimental.

type Type

type Type struct {
	// Glue InputString for this type.
	// Experimental.
	InputString *string `field:"required" json:"inputString" yaml:"inputString"`
	// Indicates whether this type is a primitive data type.
	// Experimental.
	IsPrimitive *bool `field:"required" json:"isPrimitive" yaml:"isPrimitive"`
}

Represents a type of a column in a table schema.

Example:

var myDatabase database

glue.NewS3Table(this, jsii.String("MyTable"), &S3TableProps{
	Database: myDatabase,
	Columns: []column{
		&column{
			Name: jsii.String("col1"),
			Type: glue.Schema_STRING(),
		},
	},
	PartitionKeys: []*column{
		&column{
			Name: jsii.String("year"),
			Type: glue.Schema_SMALL_INT(),
		},
		&column{
			Name: jsii.String("month"),
			Type: glue.Schema_SMALL_INT(),
		},
	},
	DataFormat: glue.DataFormat_JSON(),
})

Experimental.

func Schema_Array

func Schema_Array(itemType *Type) *Type

Creates an array of some other type. Experimental.

func Schema_BIG_INT

func Schema_BIG_INT() *Type

func Schema_BINARY

func Schema_BINARY() *Type

func Schema_BOOLEAN

func Schema_BOOLEAN() *Type

func Schema_Char

func Schema_Char(length *float64) *Type

Fixed length character data, with a specified length between 1 and 255. Experimental.

func Schema_DATE

func Schema_DATE() *Type

func Schema_DOUBLE

func Schema_DOUBLE() *Type

func Schema_Decimal

func Schema_Decimal(precision *float64, scale *float64) *Type

Creates a decimal type.

TODO: Bounds. Experimental.

func Schema_FLOAT

func Schema_FLOAT() *Type

func Schema_INTEGER

func Schema_INTEGER() *Type

func Schema_Map

func Schema_Map(keyType *Type, valueType *Type) *Type

Creates a map of some primitive key type to some value type. Experimental.

func Schema_SMALL_INT

func Schema_SMALL_INT() *Type

func Schema_STRING

func Schema_STRING() *Type

func Schema_Struct

func Schema_Struct(columns *[]*Column) *Type

Creates a nested structure containing individually named and typed columns. Experimental.

func Schema_TIMESTAMP

func Schema_TIMESTAMP() *Type

func Schema_TINY_INT

func Schema_TINY_INT() *Type

func Schema_Varchar

func Schema_Varchar(length *float64) *Type

Variable length character data, with a specified length between 1 and 65535. Experimental.

type WorkerType

type WorkerType interface {
	// The name of this WorkerType, as expected by Job resource.
	// Experimental.
	Name() *string
}

The type of predefined worker that is allocated when a job runs.

If you need to use a WorkerType that doesn't exist as a static member, you can instantiate a `WorkerType` object, e.g: `WorkerType.of('other type')`.

Example:

var bucket bucket

glue.NewJob(this, jsii.String("ScalaSparkEtlJob"), &JobProps{
	Executable: glue.JobExecutable_ScalaEtl(&ScalaJobExecutableProps{
		GlueVersion: glue.GlueVersion_V4_0(),
		Script: glue.Code_FromBucket(bucket, jsii.String("src/com/example/HelloWorld.scala")),
		ClassName: jsii.String("com.example.HelloWorld"),
		ExtraJars: []code{
			glue.*code_*FromBucket(bucket, jsii.String("jars/HelloWorld.jar")),
		},
	}),
	WorkerType: glue.WorkerType_G_8X(),
	Description: jsii.String("an example Scala ETL job"),
})

Experimental.

func WorkerType_G_025X

func WorkerType_G_025X() WorkerType

func WorkerType_G_1X

func WorkerType_G_1X() WorkerType

func WorkerType_G_2X

func WorkerType_G_2X() WorkerType

func WorkerType_G_4X

func WorkerType_G_4X() WorkerType

func WorkerType_G_8X

func WorkerType_G_8X() WorkerType

func WorkerType_Of

func WorkerType_Of(workerType *string) WorkerType

Custom worker type. Experimental.

func WorkerType_STANDARD

func WorkerType_STANDARD() WorkerType

func WorkerType_Z_2X

func WorkerType_Z_2X() WorkerType

type WriteParallel

type WriteParallel string

Specifies how to handle data being loaded that exceeds the length of the data type defined for columns containing VARCHAR, CHAR, or string data.

By default, Redshift Spectrum sets the value to null for data that exceeds the width of the column. See: https://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_EXTERNAL_TABLE.html#r_CREATE_EXTERNAL_TABLE-parameters - under _"TABLE PROPERTIES"_ > _"surplus_char_handling"_

Experimental.

const (
	// Write data in parallel.
	// Experimental.
	WriteParallel_ON WriteParallel = "ON"
	// Write data serially.
	// Experimental.
	WriteParallel_OFF WriteParallel = "OFF"
)

Source Files

Directories

Path Synopsis
Package jsii contains the functionaility needed for jsii packages to initialize their dependencies and themselves.
Package jsii contains the functionaility needed for jsii packages to initialize their dependencies and themselves.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL