AI エージェント向け: ドキュメントインデックスは https://www.mongodb.com/ja-jp/docs/llms.txt で利用できます。すべてのページの markdown バージョンは、いずれかの URL パスに .md を追加することで利用できます。
Docs Menu

出力形式のプロパティ

次の構成設定を使用して、MongoDB Kafka ソース コネクタが Kafka トピックに公開するデータの形式を指定します。

カテゴリ別に整理されたソース コネクタ構成設定のリストについては、「ソースConnector構成プロパティ 」に関するガイドを参照してください。

名前
説明

output.format.key

Type: string

Description:
Specifies which data format the source connector outputs the key document.

Default: json
Accepted Values: bson, json, schema

output.format.value

Type: string

Description:
Specifies which data format the source connector outputs the value document.

The connector supports Protobuf as an output data format. You can enable this format by specifying the schema value and installing and configuring the Kafka Connect Protobuf Converter.

Default: json
Accepted Values: bson, json, schema

output.json.formatter

タイプ: string


説明:コネクタがデータを出力するために使用するJSON形式のクラス名。デフォルト:

com.mongodb.kafka.connect.source.json.formatter.DefaultJson

受け入れ値:
カスタムJSON形式の完全なクラス名、または次の組み込みフォーマッタクラス名のいずれか。

com.mongodb.kafka.connect.source.json.formatter.DefaultJson
com.mongodb.kafka.connect.source.json.formatter.ExtendedJson
com.mongodb.kafka.connect.source.json.formatter.SimplifiedJson

これらの出力形式の詳細については、「 JSON フォーマッタ」を参照してください。

output.schema.key

Type: string

Description:
Specifies an Avro schema definition for the key document of the SourceRecord.

To learn more about Avro schema, see Avro in the Data Formats guide.

Default:

{
"type": "record",
"name": "keySchema",
"fields" : [ { "name": "_id", "type": "string" } ]"
}

許容値: 有効な Avro スキーマ

output.schema.value

Type: string

Description:
Specifies an Avro schema definition for the value document of the SourceRecord.

To learn more about Avro schema, see Avro in the Data Formats guide.

Default:

{
"name": "ChangeStream",
"type": "record",
"fields": [
{ "name": "_id", "type": "string" },
{ "name": "operationType", "type": ["string", "null"] },
{ "name": "fullDocument", "type": ["string", "null"] },
{ "name": "ns",
"type": [{"name": "ns", "type": "record", "fields": [
{"name": "db", "type": "string"},
{"name": "coll", "type": ["string", "null"] } ]
}, "null" ] },
{ "name": "to",
"type": [{"name": "to", "type": "record", "fields": [
{"name": "db", "type": "string"},
{"name": "coll", "type": ["string", "null"] } ]
}, "null" ] },
{ "name": "documentKey", "type": ["string", "null"] },
{ "name": "updateDescription",
"type": [{"name": "updateDescription", "type": "record", "fields": [
{"name": "updatedFields", "type": ["string", "null"]},
{"name": "removedFields",
"type": [{"type": "array", "items": "string"}, "null"]
}] }, "null"] },
{ "name": "clusterTime", "type": ["string", "null"] },
{ "name": "txnNumber", "type": ["long", "null"]},
{ "name": "lsid", "type": [{"name": "lsid", "type": "record",
"fields": [ {"name": "id", "type": "string"},
{"name": "uid", "type": "string"}] }, "null"] }
]
}

許容値: 有効な JSON schema

output.schema.infer.value

Type: boolean

Description:
Whether the connector should infer the schema for the value document of the SourceRecord. Since the connector processes each document in isolation, the connector may generate many schemas.

IMPORTANT: The connector only reads this setting when you set your output.format.value setting to schema.

Default: false
Accepted Values: true or false

このページを評価

項目一覧