AWS Glue Schema
This page shows how to write Terraform and CloudFormation for AWS Glue Schema and write them securely.
aws_glue_schema (Terraform)
The Schema in AWS Glue can be configured in Terraform with the resource name aws_glue_schema
. The following sections describe 1 example of how to use the resource and its parameters.
Example Usage from GitHub
resource "aws_glue_schema" "example_avro" {
schema_name = format("%s-avro-example", var.cluster_name)
registry_arn = aws_glue_registry.msk.arn
data_format = "AVRO"
compatibility = "NONE"
schema_definition = <<PROPERTIES
Parameters
-
arn
optional computed - string -
compatibility
required - string -
data_format
required - string -
description
optional - string -
id
optional computed - string -
latest_schema_version
optional computed - number -
next_schema_version
optional computed - number -
registry_arn
optional computed - string -
registry_name
optional computed - string -
schema_checkpoint
optional computed - number -
schema_definition
required - string -
schema_name
required - string -
tags
optional - map from string to string
Explanation in Terraform Registry
Provides a Glue Schema resource.
AWS::Glue::Schema (CloudFormation)
The Schema in Glue can be configured in CloudFormation with the resource name AWS::Glue::Schema
. The following sections describe 6 examples of how to use the resource and its parameters.
Example Usage from GitHub
Type: 'AWS::Glue::Schema'
Properties:
CheckpointVersion:
VersionNumber: 1
Compatibility: BACKWARD
DataFormat: AVRO
Type: AWS::Glue::Schema
Properties:
Compatibility: NONE
DataFormat: AVRO
Description: !Ref SchemaDescription
Name: !Ref SchemaName
Type: AWS::Glue::Schema
Properties:
CheckpointVersion: {
IsLatest: Yes,
VersionNumber: 1
}
Type: AWS::Glue::SchemaVersion
Properties:
Schema: {
RegistryName: !Ref RegistryNameforYourNewSchema,
SchemaName: !Ref SchemaNameforNewVersion
}
"AWS::Glue::SchemaVersion": {
"Type": "AWS::Glue::SchemaVersion",
"Properties": {}
},
"AWS::EC2::Volume": {
"Type": "AWS::EC2::Volume",
"resourceType": "AWS::Glue::SchemaVersion",
"filePath": null
},
{
"resourceType": "AWS::Glue::DataCatalogEncryptionSettings",
"filePath": null
Parameters
-
Registry
optional - Registry -
Name
required - String -
Description
optional - String -
DataFormat
required - String -
Compatibility
required - String -
SchemaDefinition
required - String -
CheckpointVersion
optional - SchemaVersion -
Tags
optional - List of Tag
Explanation in CloudFormation Registry
The
AWS::Glue::Schema
is an AWS Glue resource type that manages schemas in the AWS Glue Schema Registry.
Frequently asked questions
What is AWS Glue Schema?
AWS Glue Schema is a resource for Glue of Amazon Web Service. Settings can be wrote in Terraform and CloudFormation.
Where can I find the example code for the AWS Glue Schema?
For Terraform, the msfidelis/aws-msk-glue-kafka-setup source code example is useful. See the Terraform Example section for further details.
For CloudFormation, the gpavankumar9/GlueSchemaRegistry, deepaksadde/cloudformation and deepaksadde/cloudformation source code examples are useful. See the CloudFormation Example section for further details.