class Catalog (construct)
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.Glue.Alpha.Catalog |
Go | github.com/aws/aws-cdk-go/awscdkgluealpha/v2#Catalog |
Java | software.amazon.awscdk.services.glue.alpha.Catalog |
Python | aws_cdk.aws_glue_alpha.Catalog |
TypeScript (source) | @aws-cdk/aws-glue-alpha » Catalog |
⚠️ Deprecated: undefined
Implements
IConstruct, IDependable, IResource, IEnvironment, ICatalog, ICatalog
A Glue Data Catalog.
Use Catalog.forAccount(scope) to obtain the implicit account-wide catalog,
Catalog.encryptAccount(scope, options) to configure its Data Catalog
encryption, or new Catalog(...) to create an AWS::Glue::Catalog resource.
Example
declare const key: kms.Key;
glue.Catalog.encryptAccount(this, {
encryptionAtRest: glue.DataCatalogEncryptionAtRest.kms(key),
});
Initializer
new Catalog(scope: Construct, id: string, props: CatalogProps)
⚠️ Deprecated: undefined
Parameters
- scope
Construct - id
string - props
CatalogProps
Construct Props
| Name | Type | Description |
|---|---|---|
| catalog | string | The name of the catalog. |
| connection | Connection | Connection-password encryption configuration for the catalog. |
| description? | string | A description of the catalog. |
| encryption | Data | Encryption-at-rest configuration for the catalog. |
catalogName
⚠️ Deprecated: undefined
Type:
string
The name of the catalog.
connectionPasswordEncryption?
⚠️ Deprecated: undefined
Type:
Connection
(optional, default: connection-password encryption is not managed by CDK)
Connection-password encryption configuration for the catalog.
description?
⚠️ Deprecated: undefined
Type:
string
(optional, default: no description)
A description of the catalog.
encryptionAtRest?
⚠️ Deprecated: undefined
Type:
Data
(optional, default: encryption at rest is not managed by CDK (the catalog default applies))
Encryption-at-rest configuration for the catalog.
Properties
| Name | Type | Description |
|---|---|---|
| catalog | string | The ARN of the catalog. |
| catalog | string | The id of the catalog (for the account-wide catalog, the AWS account id). |
| catalog | Catalog | A reference to a Catalog resource. |
| env | Resource | The environment this resource belongs to. |
| node | Node | The tree node. |
| stack | Stack | The stack in which this resource is defined. |
| connection | IKey | The customer-managed KMS key used to encrypt connection passwords, if one was configured. |
| encryption | IKey | The customer-managed KMS key used for the catalog's encryption at rest, if one was configured. |
| static PROPERTY_INJECTION_ID | string | Uniquely identifies this class. |
catalogArn
⚠️ Deprecated: undefined
Type:
string
The ARN of the catalog.
catalogId
⚠️ Deprecated: undefined
Type:
string
The id of the catalog (for the account-wide catalog, the AWS account id).
catalogRef
⚠️ Deprecated: undefined
Type:
Catalog
A reference to a Catalog resource.
env
⚠️ Deprecated: undefined
Type:
Resource
The environment this resource belongs to.
For resources that are created and managed in a Stack (those created by
creating new class instances like new Role(), new Bucket(), etc.), this
is always the same as the environment of the stack they belong to.
For referenced resources (those obtained from referencing methods like
Role.fromRoleArn(), Bucket.fromBucketName(), etc.), they might be
different than the stack they were imported into.
node
⚠️ Deprecated: undefined
Type:
Node
The tree node.
stack
⚠️ Deprecated: undefined
Type:
Stack
The stack in which this resource is defined.
connectionPasswordKey?
⚠️ Deprecated: undefined
Type:
IKey
(optional)
The customer-managed KMS key used to encrypt connection passwords, if one was configured.
Undefined when password encryption uses an AWS-managed key or is not
configured. Grant access to it via KeyGrants, e.g.
if (catalog.connectionPasswordKey) { KeyGrants.fromKey(catalog.connectionPasswordKey).encrypt(grantee); }.
encryptionKey?
⚠️ Deprecated: undefined
Type:
IKey
(optional)
The customer-managed KMS key used for the catalog's encryption at rest, if one was configured.
Undefined when encryption is disabled or an AWS-managed key is used. Grant
access to it via KeyGrants, e.g.
if (catalog.encryptionKey) { KeyGrants.fromKey(catalog.encryptionKey).encrypt(grantee); }.
static PROPERTY_INJECTION_ID
⚠️ Deprecated: undefined
Type:
string
Uniquely identifies this class.
Methods
| Name | Description |
|---|---|
| apply | Override the cross-stack reference strength for this resource. |
| apply | Apply the given removal policy to this resource. |
| to | Returns a string representation of this construct. |
| with(...mixins) | Applies one or more mixins to this construct. |
| static encrypt | Configure Data Catalog encryption for the implicit, account-wide catalog and return it. |
| static for | Obtain the implicit, account-wide Data Catalog. |
| static from | Import an existing catalog by its ARN. |
| static from | Import an existing catalog by its id. |
applyCrossStackReferenceStrength(strength)
public applyCrossStackReferenceStrength(strength: ReferenceStrength): void
⚠️ Deprecated: undefined
Parameters
- strength
Reference— - The reference strength to use for this resource.Strength
Override the cross-stack reference strength for this resource.
When set, any cross-stack reference to this resource will use the specified
mechanism instead of the global default determined by the
@aws-cdk/core:defaultCrossStackReferences context key. This is useful for
selectively weakening specific references to avoid the "deadly embrace" problem
without changing the app-wide default.
applyRemovalPolicy(policy)
public applyRemovalPolicy(policy: RemovalPolicy): void
⚠️ Deprecated: undefined
Parameters
- policy
RemovalPolicy
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).
toString()
public toString(): string
⚠️ Deprecated: undefined
Returns
string
Returns a string representation of this construct.
with(...mixins)
public with(...mixins: IMixin[]): IConstruct
⚠️ Deprecated: undefined
Parameters
- mixins
IMixin
Returns
Applies one or more mixins to this construct.
Mixins are applied in order. The list of constructs is captured at the
start of the call, so constructs added by a mixin will not be visited.
Use multiple with() calls if subsequent mixins should apply to added
constructs.
static encryptAccount(scope, options)
public static encryptAccount(scope: Construct, options: CatalogEncryptionOptions): ICatalog
⚠️ Deprecated: undefined
Parameters
- scope
Construct - options
CatalogEncryption Options
Returns
Configure Data Catalog encryption for the implicit, account-wide catalog and return it.
The account catalog's encryption is an account/region-wide setting, managed
through the singleton PutDataCatalogEncryptionSettings API. Because
encryption is fixed at construction, it must be configured before the
account catalog is first used in the stack: calling this after the account
catalog has already been materialized (for example by Catalog.forAccount,
or by a Database that uses the account catalog) throws.
Configure it in exactly one stack. Configuring it from multiple stacks in the same account and region makes those stacks overwrite one another at deploy time, and the result is order-dependent. Unlike duplicate settings within a single stack (which CloudFormation rejects), this cross-stack conflict is not caught at synthesis time, because each stack synthesizes to its own template.
static forAccount(scope)
public static forAccount(scope: Construct): ICatalog
⚠️ Deprecated: undefined
Parameters
- scope
Construct
Returns
Obtain the implicit, account-wide Data Catalog.
The account catalog is not a CloudFormation resource; it always exists. This returns a stack-scoped singleton, so repeated calls within the same stack return the same instance.
This returns the account catalog without managing its encryption. To
configure Data Catalog encryption for the account, use
Catalog.encryptAccount(scope, options) instead - it must be called before
the account catalog is first used in the stack.
static fromCatalogArn(scope, id, catalogArn)
public static fromCatalogArn(scope: Construct, id: string, catalogArn: string): ICatalog
⚠️ Deprecated: undefined
Parameters
- scope
Construct - id
string - catalogArn
string
Returns
Import an existing catalog by its ARN.
The ARN must be a Glue catalog ARN, either the account-wide catalog
(arn:aws:glue:<region>:<account>:catalog, whose id is the account) or a
named catalog (arn:aws:glue:<region>:<account>:catalog/<name>, whose id is
the name).
The imported catalog is a pure identity handle and does not manage the
catalog's encryption. To manage an existing catalog's Data Catalog
encryption, add a CfnDataCatalogEncryptionSettings resource targeting its
id.
static fromCatalogId(scope, id, catalogId)
public static fromCatalogId(scope: Construct, id: string, catalogId: string): ICatalog
⚠️ Deprecated: undefined
Parameters
- scope
Construct - id
string - catalogId
string
Returns
Import an existing catalog by its id.
The imported catalog is a pure identity handle and does not manage the
catalog's encryption. To manage an existing catalog's Data Catalog
encryption, add a CfnDataCatalogEncryptionSettings resource targeting its
id.

.NET
Go
Java
Python
TypeScript (