{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--aws-databrew-job.json",
  "title": "AWSDataBrewJobProperties",
  "description": "Resource schema for AWS::DataBrew::Job.. Source:- <https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-databrew.git>",
  "x-lintel": {
    "source": "https://raw.githubusercontent.com/lalcebo/json-schema/master/serverless/resources/cloudformation-modified/aws-databrew-job.json",
    "sourceSha256": "23a888d8ea9df1af781d2426271286fde5d487b12f1228b782d3651e0703e51e"
  },
  "type": "object",
  "properties": {
    "DatasetName": {
      "oneOf": [
        {
          "type": "string",
          "minLength": 1,
          "maxLength": 255
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Dataset name"
    },
    "EncryptionKeyArn": {
      "oneOf": [
        {
          "type": "string",
          "minLength": 20,
          "maxLength": 2048
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Encryption Key Arn"
    },
    "EncryptionMode": {
      "oneOf": [
        {
          "enum": [
            "SSE-KMS",
            "SSE-S3"
          ],
          "type": "string"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Encryption mode"
    },
    "Name": {
      "oneOf": [
        {
          "type": "string",
          "minLength": 1,
          "maxLength": 255
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Job name"
    },
    "Type": {
      "oneOf": [
        {
          "enum": [
            "PROFILE",
            "RECIPE"
          ],
          "type": "string"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Job type"
    },
    "LogSubscription": {
      "oneOf": [
        {
          "enum": [
            "ENABLE",
            "DISABLE"
          ],
          "type": "string"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Log subscription"
    },
    "MaxCapacity": {
      "description": "Max capacity",
      "type": "integer"
    },
    "MaxRetries": {
      "description": "Max retries",
      "type": "integer"
    },
    "Outputs": {
      "type": "array",
      "insertionOrder": true,
      "items": {
        "$ref": "#/$defs/Output"
      }
    },
    "DataCatalogOutputs": {
      "type": "array",
      "insertionOrder": true,
      "items": {
        "$ref": "#/$defs/DataCatalogOutput"
      }
    },
    "DatabaseOutputs": {
      "type": "array",
      "insertionOrder": true,
      "items": {
        "$ref": "#/$defs/DatabaseOutput"
      }
    },
    "OutputLocation": {
      "description": "Output location",
      "$ref": "#/$defs/OutputLocation"
    },
    "ProjectName": {
      "oneOf": [
        {
          "type": "string",
          "minLength": 1,
          "maxLength": 255
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Project name"
    },
    "Recipe": {
      "$ref": "#/$defs/Recipe"
    },
    "RoleArn": {
      "oneOf": [
        {
          "type": "string"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Role arn"
    },
    "Tags": {
      "type": "array",
      "insertionOrder": false,
      "uniqueItems": false,
      "items": {
        "$ref": "#/$defs/Tag"
      }
    },
    "Timeout": {
      "description": "Timeout",
      "type": "integer"
    },
    "JobSample": {
      "description": "Job Sample",
      "$ref": "#/$defs/JobSample"
    },
    "ProfileConfiguration": {
      "description": "Profile Job configuration",
      "$ref": "#/$defs/ProfileConfiguration"
    },
    "ValidationConfigurations": {
      "description": "Data quality rules configuration",
      "type": "array",
      "insertionOrder": true,
      "items": {
        "$ref": "#/$defs/ValidationConfiguration"
      }
    }
  },
  "typeName": "AWS::DataBrew::Job",
  "createOnlyProperties": [
    "/properties/Name",
    "/properties/Type",
    "/properties/Tags"
  ],
  "sourceUrl": "https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-databrew.git",
  "taggable": true,
  "primaryIdentifier": [
    "/properties/Name"
  ],
  "additionalProperties": false,
  "$defs": {
    "S3Location": {
      "description": "S3 Output location",
      "type": "object",
      "properties": {
        "Bucket": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "Key": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "BucketOwner": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 12,
              "maxLength": 12
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobS3LocationDefinition",
      "required": [
        "Bucket"
      ],
      "additionalProperties": false
    },
    "CsvOutputOptions": {
      "description": "Output Csv options",
      "type": "object",
      "properties": {
        "Delimiter": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 1
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobCsvOutputOptionsDefinition",
      "additionalProperties": false
    },
    "OutputFormatOptions": {
      "description": "Format options for job Output",
      "type": "object",
      "properties": {
        "Csv": {
          "$ref": "#/$defs/CsvOutputOptions"
        }
      },
      "title": "AWSDataBrewJobOutputFormatOptionsDefinition",
      "additionalProperties": false
    },
    "OutputLocation": {
      "description": "Output location",
      "type": "object",
      "properties": {
        "Bucket": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "Key": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "BucketOwner": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 12,
              "maxLength": 12
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobOutputLocationDefinition",
      "required": [
        "Bucket"
      ],
      "additionalProperties": false
    },
    "Output": {
      "type": "object",
      "properties": {
        "CompressionFormat": {
          "oneOf": [
            {
              "enum": [
                "GZIP",
                "LZ4",
                "SNAPPY",
                "BZIP2",
                "DEFLATE",
                "LZO",
                "BROTLI",
                "ZSTD",
                "ZLIB"
              ],
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "Format": {
          "oneOf": [
            {
              "enum": [
                "CSV",
                "JSON",
                "PARQUET",
                "GLUEPARQUET",
                "AVRO",
                "ORC",
                "XML",
                "TABLEAUHYPER"
              ],
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "FormatOptions": {
          "$ref": "#/$defs/OutputFormatOptions"
        },
        "PartitionColumns": {
          "type": "array",
          "insertionOrder": true,
          "uniqueItems": true,
          "items": {
            "type": "string"
          }
        },
        "Location": {
          "$ref": "#/$defs/S3Location"
        },
        "Overwrite": {
          "type": "boolean"
        },
        "MaxOutputFiles": {
          "type": "integer",
          "minimum": 1,
          "maximum": 999
        }
      },
      "title": "AWSDataBrewJobOutputDefinition",
      "required": [
        "Location"
      ],
      "additionalProperties": false
    },
    "DataCatalogOutput": {
      "type": "object",
      "properties": {
        "CatalogId": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "DatabaseName": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "TableName": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "S3Options": {
          "$ref": "#/$defs/S3TableOutputOptions"
        },
        "DatabaseOptions": {
          "$ref": "#/$defs/DatabaseTableOutputOptions"
        },
        "Overwrite": {
          "type": "boolean"
        }
      },
      "title": "AWSDataBrewJobDataCatalogOutputDefinition",
      "required": [
        "DatabaseName",
        "TableName"
      ],
      "additionalProperties": false
    },
    "S3TableOutputOptions": {
      "type": "object",
      "properties": {
        "Location": {
          "$ref": "#/$defs/S3Location"
        }
      },
      "title": "AWSDataBrewJobS3TableOutputOptionsDefinition",
      "required": [
        "Location"
      ],
      "additionalProperties": false
    },
    "DatabaseTableOutputOptions": {
      "type": "object",
      "properties": {
        "TempDirectory": {
          "$ref": "#/$defs/S3Location"
        },
        "TableName": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobDatabaseTableOutputOptionsDefinition",
      "required": [
        "TableName"
      ],
      "additionalProperties": false
    },
    "DatabaseOutput": {
      "type": "object",
      "properties": {
        "GlueConnectionName": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "Glue connection name"
        },
        "DatabaseOutputMode": {
          "oneOf": [
            {
              "enum": [
                "NEW_TABLE"
              ],
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "Database table name"
        },
        "DatabaseOptions": {
          "$ref": "#/$defs/DatabaseTableOutputOptions"
        }
      },
      "title": "AWSDataBrewJobDatabaseOutputDefinition",
      "required": [
        "GlueConnectionName",
        "DatabaseOptions"
      ],
      "additionalProperties": false
    },
    "Recipe": {
      "type": "object",
      "properties": {
        "Name": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "Recipe name"
        },
        "Version": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "Recipe version"
        }
      },
      "title": "AWSDataBrewJobRecipeDefinition",
      "required": [
        "Name"
      ],
      "additionalProperties": false
    },
    "Tag": {
      "description": "A key-value pair to associate with a resource.",
      "type": "object",
      "properties": {
        "Key": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 128
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "Value": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 0,
              "maxLength": 256
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobTagDefinition",
      "required": [
        "Value",
        "Key"
      ],
      "additionalProperties": false
    },
    "SampleMode": {
      "oneOf": [
        {
          "enum": [
            "FULL_DATASET",
            "CUSTOM_ROWS"
          ],
          "type": "string"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "description": "Sample configuration mode for profile jobs.",
      "title": "AWSDataBrewJobSampleModeDefinition"
    },
    "JobSize": {
      "description": "Sample configuration size for profile jobs.",
      "format": "int64",
      "type": "integer",
      "title": "AWSDataBrewJobJobSizeDefinition"
    },
    "JobSample": {
      "description": "Job Sample",
      "type": "object",
      "properties": {
        "Mode": {
          "$ref": "#/$defs/SampleMode"
        },
        "Size": {
          "$ref": "#/$defs/JobSize"
        }
      },
      "title": "AWSDataBrewJobJobSampleDefinition",
      "additionalProperties": false
    },
    "ProfileConfiguration": {
      "type": "object",
      "properties": {
        "DatasetStatisticsConfiguration": {
          "$ref": "#/$defs/StatisticsConfiguration"
        },
        "ProfileColumns": {
          "type": "array",
          "insertionOrder": true,
          "items": {
            "$ref": "#/$defs/ColumnSelector"
          },
          "minItems": 1
        },
        "ColumnStatisticsConfigurations": {
          "type": "array",
          "insertionOrder": true,
          "items": {
            "$ref": "#/$defs/ColumnStatisticsConfiguration"
          },
          "minItems": 1
        },
        "EntityDetectorConfiguration": {
          "$ref": "#/$defs/EntityDetectorConfiguration"
        }
      },
      "title": "AWSDataBrewJobProfileConfigurationDefinition",
      "additionalProperties": false
    },
    "EntityDetectorConfiguration": {
      "type": "object",
      "title": "AWSDataBrewJobEntityDetectorConfigurationDefinition",
      "required": [
        "EntityTypes"
      ],
      "properties": {
        "EntityTypes": {
          "type": "array",
          "insertionOrder": true,
          "minItems": 1,
          "items": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "pattern": "^[A-Z_][A-Z\\\\d_]*$"
          }
        },
        "AllowedStatistics": {
          "$ref": "#/$defs/AllowedStatistics"
        }
      },
      "additionalProperties": false
    },
    "AllowedStatistics": {
      "type": "object",
      "title": "AWSDataBrewJobAllowedStatisticsDefinition",
      "required": [
        "Statistics"
      ],
      "properties": {
        "Statistics": {
          "type": "array",
          "insertionOrder": true,
          "minItems": 1,
          "items": {
            "$ref": "#/$defs/Statistic"
          }
        }
      },
      "additionalProperties": false
    },
    "ColumnStatisticsConfiguration": {
      "type": "object",
      "properties": {
        "Selectors": {
          "type": "array",
          "insertionOrder": true,
          "items": {
            "$ref": "#/$defs/ColumnSelector"
          },
          "minItems": 1
        },
        "Statistics": {
          "$ref": "#/$defs/StatisticsConfiguration"
        }
      },
      "required": [
        "Statistics"
      ],
      "title": "AWSDataBrewJobColumnStatisticsConfigurationDefinition",
      "additionalProperties": false
    },
    "StatisticsConfiguration": {
      "type": "object",
      "properties": {
        "IncludedStatistics": {
          "type": "array",
          "insertionOrder": true,
          "items": {
            "$ref": "#/$defs/Statistic"
          },
          "minItems": 1
        },
        "Overrides": {
          "type": "array",
          "insertionOrder": true,
          "items": {
            "$ref": "#/$defs/StatisticOverride"
          },
          "minItems": 1
        }
      },
      "title": "AWSDataBrewJobStatisticsConfigurationDefinition",
      "additionalProperties": false
    },
    "ColumnSelector": {
      "type": "object",
      "properties": {
        "Regex": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        },
        "Name": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ]
        }
      },
      "title": "AWSDataBrewJobColumnSelectorDefinition",
      "additionalProperties": false
    },
    "Statistic": {
      "oneOf": [
        {
          "type": "string",
          "minLength": 1,
          "maxLength": 128,
          "pattern": "^[A-Z\\_]+$"
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "title": "AWSDataBrewJobStatisticDefinition"
    },
    "StatisticOverride": {
      "type": "object",
      "properties": {
        "Statistic": {
          "$ref": "#/$defs/Statistic"
        },
        "Parameters": {
          "$ref": "#/$defs/ParameterMap"
        }
      },
      "required": [
        "Statistic",
        "Parameters"
      ],
      "title": "AWSDataBrewJobStatisticOverrideDefinition",
      "additionalProperties": false
    },
    "ParameterMap": {
      "type": "object",
      "title": "AWSDataBrewJobParameterMapDefinition",
      "additionalProperties": false,
      "patternProperties": {
        "^[A-Za-z0-9]{1,128}$": {
          "type": "string"
        }
      }
    },
    "ValidationMode": {
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "CHECK_ALL"
          ]
        },
        {
          "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
        }
      ],
      "title": "AWSDataBrewJobValidationModeDefinition"
    },
    "ValidationConfiguration": {
      "description": "Configuration to attach Rulesets to the job",
      "type": "object",
      "title": "AWSDataBrewJobValidationConfigurationDefinition",
      "properties": {
        "RulesetArn": {
          "oneOf": [
            {
              "type": "string",
              "minLength": 20,
              "maxLength": 2048
            },
            {
              "$ref": "https://catalog.lintel.tools/schemas/schemastore/serverless-framework-configuration/_shared/latest--cf.functions.json#/Aws_CF_FunctionString"
            }
          ],
          "description": "Arn of the Ruleset"
        },
        "ValidationMode": {
          "$ref": "#/$defs/ValidationMode"
        }
      },
      "required": [
        "RulesetArn"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "Name",
    "RoleArn",
    "Type"
  ]
}
