{
 "$comment": "Resource Schema for AWS::Athena::WorkGroup. Any changes made to SDK model for WorkGroup should be reflected here.",
 "additionalProperties": false,
 "createOnlyProperties": [
  "/properties/Name"
 ],
 "definitions": {
  "AclConfiguration": {
   "additionalProperties": false,
   "properties": {
    "S3AclOption": {
     "$ref": "#/definitions/S3AclOption"
    }
   },
   "required": [
    "S3AclOption"
   ],
   "type": "object"
  },
  "AdditionalConfiguration": {
   "type": "string"
  },
  "BytesScannedCutoffPerQuery": {
   "format": "int64",
   "minimum": 10000000,
   "type": "integer"
  },
  "Classification": {
   "additionalProperties": false,
   "properties": {
    "Name": {
     "type": "string"
    },
    "Properties": {
     "additionalProperties": false,
     "patternProperties": {
      "^.+$": {
       "type": "string"
      }
     },
     "type": "object"
    }
   },
   "type": "object"
  },
  "CloudWatchLoggingConfiguration": {
   "additionalProperties": false,
   "properties": {
    "Enabled": {
     "type": "boolean"
    },
    "LogGroup": {
     "type": "string"
    },
    "LogStreamNamePrefix": {
     "type": "string"
    },
    "LogTypes": {
     "additionalProperties": false,
     "patternProperties": {
      "^.+$": {
       "items": {
        "type": "string"
       },
       "type": "array"
      }
     },
     "type": "object"
    }
   },
   "type": "object"
  },
  "CustomerContentEncryptionConfiguration": {
   "additionalProperties": false,
   "properties": {
    "KmsKey": {
     "$ref": "#/definitions/KmsKey"
    }
   },
   "required": [
    "KmsKey"
   ],
   "type": "object"
  },
  "EffectiveEngineVersion": {
   "type": "string"
  },
  "EncryptionConfiguration": {
   "additionalProperties": false,
   "properties": {
    "EncryptionOption": {
     "$ref": "#/definitions/EncryptionOption"
    },
    "KmsKey": {
     "$ref": "#/definitions/KmsKey"
    }
   },
   "required": [
    "EncryptionOption"
   ],
   "type": "object"
  },
  "EncryptionOption": {
   "enum": [
    "SSE_S3",
    "SSE_KMS",
    "CSE_KMS"
   ],
   "type": "string"
  },
  "EnforceWorkGroupConfiguration": {
   "type": "boolean"
  },
  "EngineConfiguration": {
   "additionalProperties": false,
   "properties": {
    "AdditionalConfigs": {
     "additionalProperties": false,
     "patternProperties": {
      "^.+$": {
       "type": "string"
      }
     },
     "type": "object"
    },
    "Classifications": {
     "items": {
      "$ref": "#/definitions/Classification"
     },
     "type": "array"
    },
    "CoordinatorDpuSize": {
     "type": "integer"
    },
    "DefaultExecutorDpuSize": {
     "type": "integer"
    },
    "MaxConcurrentDpus": {
     "type": "integer"
    },
    "SparkProperties": {
     "additionalProperties": false,
     "patternProperties": {
      "^.+$": {
       "type": "string"
      }
     },
     "type": "object"
    }
   },
   "type": "object"
  },
  "EngineVersion": {
   "additionalProperties": false,
   "properties": {
    "EffectiveEngineVersion": {
     "$ref": "#/definitions/EffectiveEngineVersion"
    },
    "SelectedEngineVersion": {
     "$ref": "#/definitions/SelectedEngineVersion"
    }
   },
   "type": "object"
  },
  "ExecutionRole": {
   "type": "string"
  },
  "ExpectedBucketOwner": {
   "type": "string"
  },
  "KmsKey": {
   "type": "string"
  },
  "ManagedLoggingConfiguration": {
   "additionalProperties": false,
   "properties": {
    "Enabled": {
     "type": "boolean"
    },
    "KmsKey": {
     "type": "string"
    }
   },
   "type": "object"
  },
  "ManagedQueryResultsConfiguration": {
   "additionalProperties": false,
   "properties": {
    "Enabled": {
     "type": "boolean"
    },
    "EncryptionConfiguration": {
     "$ref": "#/definitions/ManagedStorageEncryptionConfiguration"
    }
   },
   "type": "object"
  },
  "ManagedStorageEncryptionConfiguration": {
   "additionalProperties": false,
   "properties": {
    "KmsKey": {
     "$ref": "#/definitions/KmsKey"
    }
   },
   "type": "object"
  },
  "MonitoringConfiguration": {
   "additionalProperties": false,
   "properties": {
    "CloudWatchLoggingConfiguration": {
     "$ref": "#/definitions/CloudWatchLoggingConfiguration"
    },
    "ManagedLoggingConfiguration": {
     "$ref": "#/definitions/ManagedLoggingConfiguration"
    },
    "S3LoggingConfiguration": {
     "$ref": "#/definitions/S3LoggingConfiguration"
    }
   },
   "type": "object"
  },
  "OutputLocation": {
   "type": "string"
  },
  "PublishCloudWatchMetricsEnabled": {
   "type": "boolean"
  },
  "RemoveAclConfiguration": {
   "type": "boolean"
  },
  "RemoveBytesScannedCutoffPerQuery": {
   "type": "boolean"
  },
  "RemoveCustomerContentEncryptionConfiguration": {
   "type": "boolean"
  },
  "RemoveEncryptionConfiguration": {
   "type": "boolean"
  },
  "RemoveExpectedBucketOwner": {
   "type": "boolean"
  },
  "RemoveOutputLocation": {
   "type": "boolean"
  },
  "RequesterPaysEnabled": {
   "type": "boolean"
  },
  "ResultConfiguration": {
   "additionalProperties": false,
   "properties": {
    "AclConfiguration": {
     "$ref": "#/definitions/AclConfiguration"
    },
    "EncryptionConfiguration": {
     "$ref": "#/definitions/EncryptionConfiguration"
    },
    "ExpectedBucketOwner": {
     "$ref": "#/definitions/ExpectedBucketOwner"
    },
    "OutputLocation": {
     "$ref": "#/definitions/OutputLocation"
    }
   },
   "type": "object"
  },
  "ResultConfigurationUpdates": {
   "additionalProperties": false,
   "properties": {
    "AclConfiguration": {
     "$ref": "#/definitions/AclConfiguration"
    },
    "EncryptionConfiguration": {
     "$ref": "#/definitions/EncryptionConfiguration"
    },
    "ExpectedBucketOwner": {
     "$ref": "#/definitions/ExpectedBucketOwner"
    },
    "OutputLocation": {
     "$ref": "#/definitions/OutputLocation"
    },
    "RemoveAclConfiguration": {
     "$ref": "#/definitions/RemoveAclConfiguration"
    },
    "RemoveEncryptionConfiguration": {
     "$ref": "#/definitions/RemoveEncryptionConfiguration"
    },
    "RemoveExpectedBucketOwner": {
     "$ref": "#/definitions/RemoveExpectedBucketOwner"
    },
    "RemoveOutputLocation": {
     "$ref": "#/definitions/RemoveOutputLocation"
    }
   },
   "type": "object"
  },
  "S3AclOption": {
   "enum": [
    "BUCKET_OWNER_FULL_CONTROL"
   ],
   "type": "string"
  },
  "S3LoggingConfiguration": {
   "additionalProperties": false,
   "properties": {
    "Enabled": {
     "type": "boolean"
    },
    "KmsKey": {
     "type": "string"
    },
    "LogLocation": {
     "type": "string"
    }
   },
   "type": "object"
  },
  "SelectedEngineVersion": {
   "type": "string"
  },
  "Tag": {
   "additionalProperties": false,
   "properties": {
    "Key": {
     "maxLength": 128,
     "minLength": 1,
     "type": "string"
    },
    "Value": {
     "maxLength": 256,
     "minLength": 0,
     "type": "string"
    }
   },
   "required": [
    "Key",
    "Value"
   ],
   "type": "object"
  },
  "Tags": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/Tag"
   },
   "type": "array"
  },
  "WorkGroupConfiguration": {
   "additionalProperties": false,
   "properties": {
    "AdditionalConfiguration": {
     "$ref": "#/definitions/AdditionalConfiguration"
    },
    "BytesScannedCutoffPerQuery": {
     "$ref": "#/definitions/BytesScannedCutoffPerQuery"
    },
    "CustomerContentEncryptionConfiguration": {
     "$ref": "#/definitions/CustomerContentEncryptionConfiguration"
    },
    "EnforceWorkGroupConfiguration": {
     "$ref": "#/definitions/EnforceWorkGroupConfiguration"
    },
    "EngineConfiguration": {
     "$ref": "#/definitions/EngineConfiguration"
    },
    "EngineVersion": {
     "$ref": "#/definitions/EngineVersion"
    },
    "ExecutionRole": {
     "$ref": "#/definitions/ExecutionRole"
    },
    "ManagedQueryResultsConfiguration": {
     "$ref": "#/definitions/ManagedQueryResultsConfiguration"
    },
    "MonitoringConfiguration": {
     "$ref": "#/definitions/MonitoringConfiguration"
    },
    "PublishCloudWatchMetricsEnabled": {
     "$ref": "#/definitions/PublishCloudWatchMetricsEnabled"
    },
    "RequesterPaysEnabled": {
     "$ref": "#/definitions/RequesterPaysEnabled"
    },
    "ResultConfiguration": {
     "$ref": "#/definitions/ResultConfiguration"
    }
   },
   "type": "object"
  },
  "WorkGroupConfigurationUpdates": {
   "additionalProperties": false,
   "properties": {
    "AdditionalConfiguration": {
     "$ref": "#/definitions/AdditionalConfiguration"
    },
    "BytesScannedCutoffPerQuery": {
     "$ref": "#/definitions/BytesScannedCutoffPerQuery"
    },
    "CustomerContentEncryptionConfiguration": {
     "$ref": "#/definitions/CustomerContentEncryptionConfiguration"
    },
    "EnforceWorkGroupConfiguration": {
     "$ref": "#/definitions/EnforceWorkGroupConfiguration"
    },
    "EngineConfiguration": {
     "$ref": "#/definitions/EngineConfiguration"
    },
    "EngineVersion": {
     "$ref": "#/definitions/EngineVersion"
    },
    "ExecutionRole": {
     "$ref": "#/definitions/ExecutionRole"
    },
    "ManagedQueryResultsConfiguration": {
     "$ref": "#/definitions/ManagedQueryResultsConfiguration"
    },
    "MonitoringConfiguration": {
     "$ref": "#/definitions/MonitoringConfiguration"
    },
    "PublishCloudWatchMetricsEnabled": {
     "$ref": "#/definitions/PublishCloudWatchMetricsEnabled"
    },
    "RemoveBytesScannedCutoffPerQuery": {
     "$ref": "#/definitions/RemoveBytesScannedCutoffPerQuery"
    },
    "RemoveCustomerContentEncryptionConfiguration": {
     "$ref": "#/definitions/RemoveCustomerContentEncryptionConfiguration"
    },
    "RequesterPaysEnabled": {
     "$ref": "#/definitions/RequesterPaysEnabled"
    },
    "ResultConfigurationUpdates": {
     "$ref": "#/definitions/ResultConfigurationUpdates"
    }
   },
   "type": "object"
  }
 },
 "deprecatedProperties": [
  "/properties/WorkGroupConfigurationUpdates"
 ],
 "primaryIdentifier": [
  "/properties/Name"
 ],
 "properties": {
  "CreationTime": {
   "type": "string"
  },
  "Description": {
   "maxLength": 1024,
   "minLength": 0,
   "type": "string"
  },
  "Name": {
   "pattern": "[a-zA-Z0-9._-]{1,128}",
   "type": "string"
  },
  "RecursiveDeleteOption": {
   "type": "boolean"
  },
  "State": {
   "enum": [
    "ENABLED",
    "DISABLED"
   ],
   "type": "string"
  },
  "Tags": {
   "$ref": "#/definitions/Tags"
  },
  "WorkGroupConfiguration": {
   "$ref": "#/definitions/WorkGroupConfiguration"
  },
  "WorkGroupConfigurationUpdates": {
   "$ref": "#/definitions/WorkGroupConfigurationUpdates"
  }
 },
 "readOnlyProperties": [
  "/properties/CreationTime",
  "/properties/WorkGroupConfiguration/EngineVersion/EffectiveEngineVersion",
  "/properties/WorkGroupConfigurationUpdates/EngineVersion/EffectiveEngineVersion"
 ],
 "required": [
  "Name"
 ],
 "sourceUrl": "https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-athena.git",
 "tagging": {
  "cloudFormationSystemTags": true,
  "tagOnCreate": true,
  "tagProperty": "/properties/Tags",
  "tagUpdatable": true,
  "taggable": true
 },
 "typeName": "AWS::Athena::WorkGroup",
 "writeOnlyProperties": [
  "/properties/WorkGroupConfigurationUpdates",
  "/properties/RecursiveDeleteOption",
  "/properties/WorkGroupConfiguration/AdditionalConfiguration"
 ]
}
