CfnClassifierPropsMixin

class aws_cdk.mixins_preview.aws_glue.mixins.CfnClassifierPropsMixin(props, *, strategy=None)

Bases: Mixin

The AWS::Glue::Classifier resource creates an AWS Glue classifier that categorizes data sources and specifies schemas.

For more information, see Adding Classifiers to a Crawler and Classifier Structure in the AWS Glue Developer Guide .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-glue-classifier.html

CloudformationResource:

AWS::Glue::Classifier

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins

cfn_classifier_props_mixin = glue_mixins.CfnClassifierPropsMixin(glue_mixins.CfnClassifierMixinProps(
    csv_classifier=glue_mixins.CfnClassifierPropsMixin.CsvClassifierProperty(
        allow_single_column=False,
        contains_custom_datatype=["containsCustomDatatype"],
        contains_header="containsHeader",
        custom_datatype_configured=False,
        delimiter="delimiter",
        disable_value_trimming=False,
        header=["header"],
        name="name",
        quote_symbol="quoteSymbol"
    ),
    grok_classifier=glue_mixins.CfnClassifierPropsMixin.GrokClassifierProperty(
        classification="classification",
        custom_patterns="customPatterns",
        grok_pattern="grokPattern",
        name="name"
    ),
    json_classifier=glue_mixins.CfnClassifierPropsMixin.JsonClassifierProperty(
        json_path="jsonPath",
        name="name"
    ),
    xml_classifier=glue_mixins.CfnClassifierPropsMixin.XMLClassifierProperty(
        classification="classification",
        name="name",
        row_tag="rowTag"
    )
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::Glue::Classifier.

Parameters:
  • props (Union[CfnClassifierMixinProps, Dict[str, Any]]) – L1 properties to apply.

  • strategy (Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['csvClassifier', 'grokClassifier', 'jsonClassifier', 'xmlClassifier']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

CsvClassifierProperty

class CfnClassifierPropsMixin.CsvClassifierProperty(*, allow_single_column=None, contains_custom_datatype=None, contains_header=None, custom_datatype_configured=None, delimiter=None, disable_value_trimming=None, header=None, name=None, quote_symbol=None)

Bases: object

A classifier for custom CSV content.

Parameters:
  • allow_single_column (Union[bool, IResolvable, None]) – Enables the processing of files that contain only one column.

  • contains_custom_datatype (Optional[Sequence[str]]) – Indicates whether the CSV file contains custom data types.

  • contains_header (Optional[str]) – Indicates whether the CSV file contains a header. A value of UNKNOWN specifies that the classifier will detect whether the CSV file contains headings. A value of PRESENT specifies that the CSV file contains headings. A value of ABSENT specifies that the CSV file does not contain headings.

  • custom_datatype_configured (Union[bool, IResolvable, None]) – Enables the configuration of custom data types.

  • delimiter (Optional[str]) – A custom symbol to denote what separates each column entry in the row.

  • disable_value_trimming (Union[bool, IResolvable, None]) – Specifies not to trim values before identifying the type of column values. The default value is true .

  • header (Optional[Sequence[str]]) – A list of strings representing column names.

  • name (Optional[str]) – The name of the classifier.

  • quote_symbol (Optional[str]) – A custom symbol to denote what combines content into a single column value. It must be different from the column delimiter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins

csv_classifier_property = glue_mixins.CfnClassifierPropsMixin.CsvClassifierProperty(
    allow_single_column=False,
    contains_custom_datatype=["containsCustomDatatype"],
    contains_header="containsHeader",
    custom_datatype_configured=False,
    delimiter="delimiter",
    disable_value_trimming=False,
    header=["header"],
    name="name",
    quote_symbol="quoteSymbol"
)

Attributes

allow_single_column

Enables the processing of files that contain only one column.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-allowsinglecolumn

contains_custom_datatype

Indicates whether the CSV file contains custom data types.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-containscustomdatatype

contains_header

Indicates whether the CSV file contains a header.

A value of UNKNOWN specifies that the classifier will detect whether the CSV file contains headings.

A value of PRESENT specifies that the CSV file contains headings.

A value of ABSENT specifies that the CSV file does not contain headings.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-containsheader

custom_datatype_configured

Enables the configuration of custom data types.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-customdatatypeconfigured

delimiter

A custom symbol to denote what separates each column entry in the row.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-delimiter

disable_value_trimming

Specifies not to trim values before identifying the type of column values.

The default value is true .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-disablevaluetrimming

header

A list of strings representing column names.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-header

name

The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-name

quote_symbol

A custom symbol to denote what combines content into a single column value.

It must be different from the column delimiter.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-csvclassifier.html#cfn-glue-classifier-csvclassifier-quotesymbol

GrokClassifierProperty

class CfnClassifierPropsMixin.GrokClassifierProperty(*, classification=None, custom_patterns=None, grok_pattern=None, name=None)

Bases: object

A classifier that uses grok patterns.

Parameters:
  • classification (Optional[str]) – An identifier of the data format that the classifier matches, such as Twitter, JSON, Omniture logs, and so on.

  • custom_patterns (Optional[str]) – Optional custom grok patterns defined by this classifier. For more information, see custom patterns in Writing Custom Classifiers .

  • grok_pattern (Optional[str]) –

    The grok pattern applied to a data store by this classifier. For more information, see built-in patterns in Writing Custom Classifiers .

  • name (Optional[str]) – The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-grokclassifier.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins

grok_classifier_property = glue_mixins.CfnClassifierPropsMixin.GrokClassifierProperty(
    classification="classification",
    custom_patterns="customPatterns",
    grok_pattern="grokPattern",
    name="name"
)

Attributes

classification

An identifier of the data format that the classifier matches, such as Twitter, JSON, Omniture logs, and so on.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-grokclassifier.html#cfn-glue-classifier-grokclassifier-classification

custom_patterns

Optional custom grok patterns defined by this classifier.

For more information, see custom patterns in Writing Custom Classifiers .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-grokclassifier.html#cfn-glue-classifier-grokclassifier-custompatterns

grok_pattern

The grok pattern applied to a data store by this classifier.

For more information, see built-in patterns in Writing Custom Classifiers .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-grokclassifier.html#cfn-glue-classifier-grokclassifier-grokpattern

name

The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-grokclassifier.html#cfn-glue-classifier-grokclassifier-name

JsonClassifierProperty

class CfnClassifierPropsMixin.JsonClassifierProperty(*, json_path=None, name=None)

Bases: object

A classifier for JSON content.

Parameters:
  • json_path (Optional[str]) – A JsonPath string defining the JSON data for the classifier to classify. AWS Glue supports a subset of JsonPath , as described in Writing JsonPath Custom Classifiers .

  • name (Optional[str]) – The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-jsonclassifier.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins

json_classifier_property = glue_mixins.CfnClassifierPropsMixin.JsonClassifierProperty(
    json_path="jsonPath",
    name="name"
)

Attributes

json_path

A JsonPath string defining the JSON data for the classifier to classify.

AWS Glue supports a subset of JsonPath , as described in Writing JsonPath Custom Classifiers .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-jsonclassifier.html#cfn-glue-classifier-jsonclassifier-jsonpath

name

The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-jsonclassifier.html#cfn-glue-classifier-jsonclassifier-name

XMLClassifierProperty

class CfnClassifierPropsMixin.XMLClassifierProperty(*, classification=None, name=None, row_tag=None)

Bases: object

A classifier for XML content.

Parameters:
  • classification (Optional[str]) – An identifier of the data format that the classifier matches.

  • name (Optional[str]) – The name of the classifier.

  • row_tag (Optional[str]) – The XML tag designating the element that contains each record in an XML document being parsed. This can’t identify a self-closing element (closed by /> ). An empty row element that contains only attributes can be parsed as long as it ends with a closing tag (for example, <row item_a="A" item_b="B"></row> is okay, but <row item_a="A" item_b="B" /> is not).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-xmlclassifier.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins

x_mLClassifier_property = glue_mixins.CfnClassifierPropsMixin.XMLClassifierProperty(
    classification="classification",
    name="name",
    row_tag="rowTag"
)

Attributes

classification

An identifier of the data format that the classifier matches.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-xmlclassifier.html#cfn-glue-classifier-xmlclassifier-classification

name

The name of the classifier.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-xmlclassifier.html#cfn-glue-classifier-xmlclassifier-name

row_tag

The XML tag designating the element that contains each record in an XML document being parsed.

This can’t identify a self-closing element (closed by /> ). An empty row element that contains only attributes can be parsed as long as it ends with a closing tag (for example, <row item_a="A" item_b="B"></row> is okay, but <row item_a="A" item_b="B" /> is not).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-glue-classifier-xmlclassifier.html#cfn-glue-classifier-xmlclassifier-rowtag