注意
Atlas Kubernetes Operator は、Atlas for Government のAtlasDataFederationカスタム リソースをサポートしていません。
AtlasDataFederation カスタムリソースは、Atlas のフェデレーティッドデータベースインスタンスを構成します。AtlasDataFederation カスタムリソースを作成すると、Atlas Kubernetes Operator は Atlas 内のフェデレーティッドデータベースインスタンスを作成または更新しようとします。フェデレーティッドデータベースインスタンスを使用してフェデレーティッドクエリを実行できます。
重要
カスタム リソースはデフォルトでオブジェクトを削除しなくなりました
Atlas Kubernetes Operator はカスタムリソース構成ファイルを使用して Atlas 構成を管理しますが、Atlas Kubernetes Operator2.0 以降、 Kubernetesで削除したカスタム リソースは Atlas で削除されなくなりました(デフォルトでは )。代わりに、Atlas Kubernetes Operator は Atlas 内のそれらのリソースの管理を停止します。 例、 Kubernetesで カスタム リソースを削除すると、デフォルトでは、Atlas Kubernetes Operator は Atlas
AtlasProjectから対応するプロジェクトを自動的に削除しなくなります。この動作の変更は、誤ってまたは予期せずに削除されるのを防ぐことを目的としています。 この動作を Atlas Kubernetes Operator. 以前に使用されていたデフォルトに戻す方法などの詳細については、「2 0新しいデフォルト: Atlas Kubernetes Operator. の削除保護2 0」を参照してください。同様に、Atlas Kubernetes Operator を使用してKubernetesの Atlasプロジェクトからチームを削除しても、Atlas Kubernetes Operator は Atlas からチームを削除しません。
デフォルトのAtlas 構成値が暗黙的に使用されるのを避けるために、必要な構成の詳細を明示的に定義します。 場合によっては、Atlas のデフォルトを継承すると調整ループが発生し、カスタムリソースが
READY状態に達しなくなります。 例、含まれている例に示すように、AtlasDeploymentカスタムリソースで必要なオートスケーリング動作を明示的に定義すると、カスタムリソース内の静的インスタンスサイズが、オートスケーリングが有効になっている Atlas 配置に繰り返し適用されないことが保証されます。autoScaling: diskGB: enabled: true compute: enabled: true scaleDownEnabled: true minInstanceSize: M30 maxInstanceSize: M40
Atlas Kubernetes Operator uses the Atlas Clusters API Resource and Advanced Clusters API Resource to create a new federated database instance or update an existing federated database instance. If you specify values for fields under spec.serverlessSpec, Atlas Kubernetes Operator uses the Atlas Serverless Instance API Resource to create or configure private endpoints for your federated database instance.
Kubernetes クラスターからAtlasDataFederationリソースを削除すると、Atlas Kubernetes Operator は Atlas からフェデレーティッドデータベースインスタンスを削除します。
例
次の例では、プライベートエンドポイントが構成されたAtlasDataFederationカスタム リソース仕様を示しています。
apiVersion: atlas.mongodb.com/v1 kind: AtlasDataFederation metadata: name: my-federated-deployment spec: projectRef: name: my-project namespace: default cloudProviderConfig: aws: roleId: 12345678 testS3Bucket: my-bucket dataProcessRegion: cloudProvider: AWS region: OREGON_USA name: my-fdi storage: databases: - collections: - dataSources: - allowInsecure: false collection: my-collection collectionRegex: database: my-database databaseRegex: defaultFormat: ".avro" path: / provenanceFieldName: string storeName: my-data-store urls: - string: name: my-collection-mdb maxWildcardCollections: 100 name: my-database-mdb views: - name: my-view pipeline: source: my-source-collection stores: - name: my-store provider: S3 additionalStorageClasses: - STANDARD bucket: my-bucket delimiter: / includeTags: false prefix: data- public: false region: US_WEST_1 privateEndpoints: - endpointId: vpce-3bf78b0ddee411ba1 provider: AWS type: DATA_LAKE - endpointId: vpce-3bf78b0ddee411ba2 provider: AWS type: DATA_LAKE
パラメーター
This section describes some of the key AtlasDataFederation custom resource parameters available. For a full list of available parameters, see the Atlas Data Federation API.
これらの説明、利用可能な例、 APIドキュメントを参照して、仕様をカスタマイズします。
metadata.name型: string
必須
Label that identifies the
AtlasDataFederationCustom Resource that Atlas Kubernetes Operator uses to add this federated database instance to a project.
spec.cloudProviderConfig型: オブジェクト
必須
フェデレーティッドデータベースインスタンスのクラウドプロバイダー構成が格納されたリスト。
spec.cloudProviderConfig.aws型: オブジェクト
必須
フェデレーティッドデータベースインスタンスをホストするクラウド サービス プロバイダーの名前。
spec.cloudProviderConfig.aws.roleId型: string
必須
フェデレーティッドデータベースインスタンスがデータ ストアにアクセスするために使用できるロールの一意の識別子です。
spec.cloudProviderConfig.aws.testS3Bucket型: string
必須
指定されたロール ID がアクセスを許可されている S3 データ バケットの名前。
spec.dataProcessRegion型: オブジェクト
必須
フェデレーティッドデータベースインスタンスがクライアント接続をルーティングするクラウドプロバイダーのリージョンに関する情報。 Atlas Kubernetes OperatorはAmazon Web Servicesのみをサポートしています。
spec.dataProcessRegion.cloudProvider型: string
必須
フェデレーティッドデータベースインスタンスのデータ ストアをホストするクラウド サービス プロバイダーの名前。 Atlas Kubernetes Operator は、次の値を受け入れます。
AWSTENANTSERVERLESS
spec.dataProcessRegion.region型: string
必須
フェデレーティッドデータベースインスタンスのデータ ストアの地理的ロケーションを示すラベル。 Atlas Kubernetes Operator は、次の値を受け入れます。
SYDNEY_AUSMUMBAI_INDFRANKFURT_DEUDUBLIN_IRLLONDON_GBRVIRGINIA_USAOREGON_USASAOPAULO_BRASINGAPORE_SGP
spec.name型: string
任意
Atlas 内のフェデレーティッドデータベースインスタンスを識別するラベル。
spec.storage型: オブジェクト
任意
各データ ストアの構成情報と Atlas データベースへのマッピング。
spec.storage.databasesタイプ: 配列
任意
このフェデレーティッドデータベースインスタンスのクエリ可能なデータベースとコレクションが格納されたリスト。
spec.storage.databases.collectionsタイプ: 配列
任意
storesデータストアにマッピングするコレクションとデータソースのリスト。
spec.storage.databases.collections.dataSourcesタイプ: 配列
任意
このフェデレーティッドデータベースインスタンスのコレクションにマップされるデータ ストアが格納されたリスト。
spec.storage.databases.collections.dataSources.allowInsecureタイプ: ブール値
任意
指定された URL のスキームを検証するフラグ。
trueの場合、Atlas Kubernetes Operator は安全でないHTTPスキームを許可し、サーバーの証明書チェーンとホスト名を検証せず、サーバーによって提示されたホスト名を持つ任意の証明書を受け入れます。falseの場合、Atlas Kubernetes Operator は安全なHTTPSスキームのみを許可します。
spec.storage.databases.collections.dataSources.collection型: string
任意
データベース内のコレクションを識別する、人間が判読可能なラベル。 ワイルドカード(
*)コレクションを作成するには、このパラメータを省略する必要があります。
spec.storage.databases.collections.dataSources.collectionRegex型: string
任意
ワイルドカード(
*)コレクションの作成に使用する正規表現パターン。
spec.storage.databases.collections.dataSources.database型: string
任意
クラスター内のコレクションを含むデータベースを識別する、人間が判読可能なラベル。 動的に生成されたデータベースのワイルドカード(
*)コレクションを生成するには、このパラメーターを省略する必要があります。
spec.storage.databases.collections.dataSources.databaseRegex型: string
任意
ワイルドカード(
*)データベースの作成に使用する正規表現パターン。
spec.storage.databases.collections.dataSources.defaultFormat型: string
任意
Atlas Kubernetes Operator が
storeNameを検索中にファイル拡張子のないファイルを検出した場合に使用するファイル形式。 Atlas Kubernetes Operator は、次の値を受け入れます。.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
spec.storage.databases.collections.dataSources.path型: string
任意
Atlas Kubernetes Operator が
storeName内のファイルをコレクションにマッピングする前に、それらのファイルを検索して解析する方法を制御するファイルパス。 プレフィックス パスからすべてのファイルとフォルダーを取得するには、/を指定します。
spec.storage.databases.collections.dataSources.provenanceFieldName型: string
任意
結果にドキュメントの出所が含まれるフィールドを識別する、人間が判読可能なラベル。 Atlas Kubernetes Operator では、サポートされているプロバイダーごとに結果に異なるフィールドが返されます。
spec.storage.databases.collections.dataSources.storeName型: string
任意
Atlas Kubernetes Operator がコレクションにマッピングするデータ ストアを識別する、人間が判読できるラベル。
spec.storage.databases.collections.dataSources.urlsタイプ: 配列
任意
URLs of the publicly-accessible data files. You can't specify URLs that require authentication. Atlas Data Federation creates a partition for each URL. If empty or omitted, Atlas Data Federation uses the URLs from the store specified in the dataSources.storeName parameter.
spec.storage.databases.collections.name型: string
任意
Atlas Kubernetes Operator がデータ ストア内のデータをマッピングするコレクションを識別する、人間が判読可能なラベル。
spec.storage.databases.maxWildcardCollectionsタイプ: int32
任意
データベース内のワイルドカード コレクションの最大数。 これは S3 データソースにのみ適用されます。 デフォルト値は
100です。
spec.storage.databases.name型: string
任意
フェデレーティッドデータベースインスタンスがデータをマッピングするデータベースを識別する、人間が判読可能なラベル。
spec.storage.databases.viewsタイプ: 配列
任意
コレクションに適用される 集計パイプライン のリスト。 これは S3 データソースにのみ適用されます。
spec.storage.databases.views.name型: string
任意
コレクションの 集計パイプライン に対応するビューを識別する、人間が判読可能なラベル。
spec.storage.databases.views.pipeline型: string
任意
ソース コレクションに適用する 集計パイプライン ステージ 。
spec.storage.databases.views.source型: string
任意
ビューのソース コレクションを識別する、人間が判読可能なラベル。
spec.storage.storesタイプ: 配列
任意
フェデレーティッドデータベースインスタンスのデータストアが格納されたリスト。
spec.storage.stores.name型: string
任意
Human-readable label that identifies the data store. The spec.storage.databases.collections.dataSources.storeName field references this values as part of the mapping configuration.
spec.storage.stores.provider型: string
条件付き
ストアのプロバイダー。 Atlas Kubernetes Operator は
S3のみをサポートしています。 データ ストアを使用するには、このフィールドを指定する必要があります。
spec.storage.stores.additionalStorageClassesタイプ: 配列
任意
AWS S3 ストレージ クラスのコレクション。Atlas Data Federation は、これらのストレージ クラスのファイルをクエリ結果に含めます。Atlas Kubernetes Operator は以下の値を受け入れます。
STANDARDINTELLIGENT_TIERINGSTANDARD_IA
spec.storage.stores.bucket型: string
任意
AWS S3 バケットを識別する、人間が判読できるラベル。このラベルは、フェデレーティッドデータベースインスタンスが構成された AWS IAM 認証情報を使用してアクセスできる S3 バケットの名前と完全に一致する必要があります。
spec.storage.stores.delimiter型: string
任意
The delimiter that separates spec.storage.databases.collections.dataSources.path segments in the data store. Atlas Kubernetes Operator 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. For example, you can specify an underscore (
_) or a plus sign (+) or multiple characters, such as double underscores (__) as the delimiter. If omitted, defaults to/.
spec.storage.stores.includeTagsタイプ: ブール値
任意
指定されたパス内のファイルの S3 タグを追加のパーティション属性として使用するかどうかを示すフラグ。 true に設定すると、Atlas Kubernetes Operator は S3 タグを追加のパーティション属性として追加し、各タグを各ドキュメントに関連付けるための新しい最上位の BSON 要素を追加します。 省略した場合、デフォルトは
falseになります。
spec.storage.stores.prefix型: string
任意
Prefix that Atlas Kubernetes Operator applies when searching for files in the S3 bucket. The data store prepends the value of prefix to the spec.storage.databases.collections.dataSources.path to create the full path for files to ingest. If omitted, Atlas Kubernetes Operator searches all files from the root of the S3 bucket.
spec.storage.stores.publicタイプ: ブール値
任意
バケットがパブリックかどうかを示すフラグ。
trueに設定すると、Atlas Kubernetes Operator は、S3 バケットにアクセスするために構成された AWS IAM ロールを使用しません。falseに設定した場合、構成された AWS IAM ロールには S3 バケットへのアクセス権限が含まれている必要があります。
spec.storage.stores.region型: string
任意
S3 バケットの物理的ロケーションを示すAWSリージョン。
spec.privateEndpointsタイプ: 配列
任意
フェデレーティッドデータベースインスタンスのプライベートエンドポイント構成が格納されたリスト。
spec.privateEndpoints.endpointId型: string
必須
Amazon Web Services 内のプライベートエンドポイントを識別する、
vpce-で始まるユニークな 22 文字の英数字列。
spec.privateEndpoints.provider型: string
任意
クラウド サービス プロバイダーを識別する、人間が判読可能なラベル。 Atlas Data Federation は
AWSのみをサポートしています。
spec.privateEndpoints.type型: string
任意
このプライベートエンドポイントに関連付けられているリソースの種類を識別する、人間が判読可能なラベル。 Atlas Data Federation は
DATA_LAKEのみをサポートしています。
spec.projectRef.name型: string
必須
フェデレーティッドデータベースインスタンスが属するプロジェクトの名前。 既存の
AtlasProjectカスタム リソースを指定する必要があります。
spec.projectRef.namespace型: string
必須
Namespace in which the
AtlasProjectCustom Resource specified in spec.projectRef.name exists.