{
  "description": "AtlasDataFederation is the Schema for the Atlas Data Federation API.",
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
      "type": "string"
    },
    "kind": {
      "description": "Kind is a string value representing the REST resource this object represents.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": "string"
    },
    "metadata": {
      "type": "object"
    },
    "spec": {
      "description": "DataFederationSpec defines the target state of AtlasDataFederation.",
      "properties": {
        "cloudProviderConfig": {
          "description": "Configuration for the cloud provider where this Federated Database Instance is hosted.",
          "properties": {
            "aws": {
              "description": "Configuration for running Data Federation in AWS.",
              "properties": {
                "roleId": {
                  "description": "Unique identifier of the role that the data lake can use to access the data stores.Required if specifying cloudProviderConfig.",
                  "type": "string"
                },
                "testS3Bucket": {
                  "description": "Name of the S3 data bucket that the provided role ID is authorized to access.Required if specifying cloudProviderConfig.",
                  "type": "string"
                }
              },
              "type": "object",
              "additionalProperties": false
            }
          },
          "type": "object",
          "additionalProperties": false
        },
        "dataProcessRegion": {
          "description": "Information about the cloud provider region to which the Federated Database Instance routes client connections.",
          "properties": {
            "cloudProvider": {
              "description": "Name of the cloud service that hosts the Federated Database Instance's infrastructure.",
              "enum": [
                "AWS"
              ],
              "type": "string"
            },
            "region": {
              "description": "Name of the region to which the data lake routes client connections.",
              "enum": [
                "SYDNEY_AUS",
                "MUMBAI_IND",
                "FRANKFURT_DEU",
                "DUBLIN_IRL",
                "LONDON_GBR",
                "VIRGINIA_USA",
                "OREGON_USA",
                "SAOPAULO_BRA",
                "SINGAPORE_SGP"
              ],
              "type": "string"
            }
          },
          "type": "object",
          "additionalProperties": false
        },
        "name": {
          "description": "Human-readable label that identifies the Federated Database Instance.",
          "type": "string"
        },
        "privateEndpoints": {
          "description": "Private endpoint for Federated Database Instances and Online Archives to add to the specified project.",
          "items": {
            "properties": {
              "endpointId": {
                "description": "Unique 22-character alphanumeric string that identifies the private endpoint.",
                "type": "string"
              },
              "provider": {
                "description": "Human-readable label that identifies the cloud service provider. Atlas Data Lake supports Amazon Web Services only.",
                "type": "string"
              },
              "type": {
                "description": "Human-readable label that identifies the resource type associated with this private endpoint.",
                "type": "string"
              }
            },
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "projectRef": {
          "description": "Project is a reference to AtlasProject resource the deployment belongs to.",
          "properties": {
            "name": {
              "description": "Name of the Kubernetes Resource",
              "type": "string"
            },
            "namespace": {
              "description": "Namespace of the Kubernetes Resource",
              "type": "string"
            }
          },
          "required": [
            "name"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "storage": {
          "description": "Configuration information for each data store and its mapping to MongoDB Atlas databases.",
          "properties": {
            "databases": {
              "description": "Array that contains the queryable databases and collections for this data lake.",
              "items": {
                "description": "Database associated with this data lake. Databases contain collections and views.",
                "properties": {
                  "collections": {
                    "description": "Array of collections and data sources that map to a stores data store.",
                    "items": {
                      "description": "Collection maps to a stores data store.",
                      "properties": {
                        "dataSources": {
                          "description": "Array that contains the data stores that map to a collection for this data lake.",
                          "items": {
                            "properties": {
                              "allowInsecure": {
                                "description": "Flag that validates the scheme in the specified URLs.\nIf true, allows insecure HTTP scheme, doesn't verify the server's certificate chain and hostname, and accepts any certificate with any hostname presented by the server.\nIf false, allows secure HTTPS scheme only.",
                                "type": "boolean"
                              },
                              "collection": {
                                "description": "Human-readable label that identifies the collection in the database. For creating a wildcard (*) collection, you must omit this parameter.",
                                "type": "string"
                              },
                              "collectionRegex": {
                                "description": "Regex pattern to use for creating the wildcard (*) collection.",
                                "type": "string"
                              },
                              "database": {
                                "description": "Human-readable label that identifies the database, which contains the collection in the cluster. You must omit this parameter to generate wildcard (*) collections for dynamically generated databases.",
                                "type": "string"
                              },
                              "databaseRegex": {
                                "description": "Regex pattern to use for creating the wildcard (*) database.",
                                "type": "string"
                              },
                              "defaultFormat": {
                                "description": "File format that MongoDB Cloud uses if it encounters a file without a file extension while searching storeName.",
                                "enum": [
                                  ".avro",
                                  ".avro.bz2",
                                  ".avro.gz",
                                  ".bson",
                                  ".bson.bz2",
                                  ".bson.gz",
                                  ".bsonx",
                                  ".csv",
                                  ".csv.bz2",
                                  ".csv.gz",
                                  ".json",
                                  ".json.bz2",
                                  ".json.gz",
                                  ".orc",
                                  ".parquet",
                                  ".tsv",
                                  ".tsv.bz2",
                                  ".tsv.gz"
                                ],
                                "type": "string"
                              },
                              "path": {
                                "description": "File path that controls how MongoDB Cloud searches for and parses files in the storeName before mapping them to a collection.\nSpecify / to capture all files and folders from the prefix path.",
                                "type": "string"
                              },
                              "provenanceFieldName": {
                                "description": "Name for the field that includes the provenance of the documents in the results. MongoDB Atlas returns different fields in the results for each supported provider.",
                                "type": "string"
                              },
                              "storeName": {
                                "description": "Human-readable label that identifies the data store that MongoDB Cloud maps to the collection.",
                                "type": "string"
                              },
                              "urls": {
                                "description": "URLs of the publicly accessible data files. You can't specify URLs that require authentication.\nAtlas Data Lake creates a partition for each URL. If empty or omitted, Data Lake uses the URLs from the store specified in the storeName parameter.",
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "type": "array"
                        },
                        "name": {
                          "description": "Human-readable label that identifies the collection to which MongoDB Atlas maps the data in the data stores.",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    },
                    "type": "array"
                  },
                  "maxWildcardCollections": {
                    "description": "Maximum number of wildcard collections in the database. This only applies to S3 data sources.\nMinimum value is 1, maximum value is 1000. Default value is 100.",
                    "type": "integer"
                  },
                  "name": {
                    "description": "Human-readable label that identifies the database to which the data lake maps data.",
                    "type": "string"
                  },
                  "views": {
                    "description": "Array of aggregation pipelines that apply to the collection. This only applies to S3 data sources.",
                    "items": {
                      "properties": {
                        "name": {
                          "description": "Human-readable label that identifies the view, which corresponds to an aggregation pipeline on a collection.",
                          "type": "string"
                        },
                        "pipeline": {
                          "description": "Aggregation pipeline stages to apply to the source collection.",
                          "type": "string"
                        },
                        "source": {
                          "description": "Human-readable label that identifies the source collection for the view.",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    },
                    "type": "array"
                  }
                },
                "type": "object",
                "additionalProperties": false
              },
              "type": "array"
            },
            "stores": {
              "description": "Array that contains the data stores for the data lake.",
              "items": {
                "description": "Store is a group of settings that define where the data is stored.",
                "properties": {
                  "additionalStorageClasses": {
                    "description": "Collection of AWS S3 storage classes. Atlas Data Lake includes the files in these storage classes in the query results.",
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "bucket": {
                    "description": "Human-readable label that identifies the AWS S3 bucket.\nThis label must exactly match the name of an S3 bucket that the data lake can access with the configured AWS Identity and Access Management (IAM) credentials.",
                    "type": "string"
                  },
                  "delimiter": {
                    "description": "The delimiter that separates path segments in the data store.\nMongoDB Atlas uses the delimiter to efficiently traverse S3 buckets with a hierarchical directory structure. You can specify any character supported by the S3 object keys as the delimiter.",
                    "type": "string"
                  },
                  "includeTags": {
                    "description": "Flag that indicates whether to use S3 tags on the files in the given path as additional partition attributes.\nIf set to true, data lake adds the S3 tags as additional partition attributes and adds new top-level BSON elements associating each tag to each document.",
                    "type": "boolean"
                  },
                  "name": {
                    "description": "Human-readable label that identifies the data store. The storeName field references this values as part of the mapping configuration.\nTo use MongoDB Atlas as a data store, the data lake requires a serverless instance or an M10 or higher cluster.",
                    "type": "string"
                  },
                  "prefix": {
                    "description": "Prefix that MongoDB Cloud applies when searching for files in the S3 bucket.\nThe data store prepends the value of prefix to the path to create the full path for files to ingest.\nIf omitted, MongoDB Cloud searches all files from the root of the S3 bucket.",
                    "type": "string"
                  },
                  "provider": {
                    "description": "The provider used for data stores.",
                    "type": "string"
                  },
                  "public": {
                    "description": "Flag that indicates whether the bucket is public.\nIf set to true, MongoDB Cloud doesn't use the configured AWS Identity and Access Management (IAM) role to access the S3 bucket.\nIf set to false, the configured AWS IAM role must include permissions to access the S3 bucket.",
                    "type": "boolean"
                  },
                  "region": {
                    "description": "Physical location where MongoDB Cloud deploys your AWS-hosted MongoDB cluster nodes. The region you choose can affect network latency for clients accessing your databases.\nWhen MongoDB Atlas deploys a dedicated cluster, it checks if a VPC or VPC connection exists for that provider and region. If not, MongoDB Atlas creates them as part of the deployment.\nTo limit a new VPC peering connection to one CIDR block and region, create the connection first. Deploy the cluster after the connection starts.",
                    "type": "string"
                  }
                },
                "type": "object",
                "additionalProperties": false
              },
              "type": "array"
            }
          },
          "type": "object",
          "additionalProperties": false
        }
      },
      "required": [
        "name",
        "projectRef"
      ],
      "type": "object",
      "additionalProperties": false
    },
    "status": {
      "description": "DataFederationStatus defines the observed state of AtlasDataFederation.",
      "properties": {
        "conditions": {
          "description": "Conditions is the list of statuses showing the current state of the Atlas Custom Resource",
          "items": {
            "description": "Condition describes the state of an Atlas Custom Resource at a certain point.",
            "properties": {
              "lastTransitionTime": {
                "description": "Last time the condition transitioned from one status to another.\nRepresented in ISO 8601 format.",
                "format": "date-time",
                "type": "string"
              },
              "message": {
                "description": "A message providing details about the transition.",
                "type": "string"
              },
              "reason": {
                "description": "The reason for the condition's last transition.",
                "type": "string"
              },
              "status": {
                "description": "Status of the condition; one of True, False, Unknown.",
                "type": "string"
              },
              "type": {
                "description": "Type of Atlas Custom Resource condition.",
                "type": "string"
              }
            },
            "required": [
              "status",
              "type"
            ],
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "mongoDBVersion": {
          "description": "MongoDBVersion is the version of MongoDB the cluster runs, in <major version>.<minor version> format.",
          "type": "string"
        },
        "observedGeneration": {
          "description": "ObservedGeneration indicates the generation of the resource specification of which the Atlas Operator is aware.\nThe Atlas Operator updates this field to the value of 'metadata.generation' as soon as it starts reconciliation of the resource.",
          "format": "int64",
          "type": "integer"
        }
      },
      "required": [
        "conditions"
      ],
      "type": "object",
      "additionalProperties": false
    }
  },
  "type": "object"
}
