@@ -76,32 +76,50 @@ Settings
76
76
77
77
.. example::
78
78
79
- The following mappings instruct the connector to do the following:
79
+ The following mapping instructs the connector to perform the following
80
+ actions:
80
81
81
82
- Publish change stream documents originating from the
82
- ``myDb.myColl`` MongoDB collection to the ``topicTwo`` Kafka topic.
83
- - Publish all other change stream documents originating from the
84
- ``myDb`` MongoDB database to the ``topicOne`` Kafka topic.
83
+ ``myDb.myColl`` MongoDB collection to the ``topicOne`` Kafka topic.
84
+ - Publish change stream documents originating from the
85
+ ``myDb`` MongoDB database and a collection other than ``myColl``
86
+ to the Kafka topic ``topicTwo.<collectionName>``.
87
+ - Publish change stream documents originating from the ``myDb``
88
+ MongoDB database that do not bear a collection name to
89
+ the ``topicTwo`` Kafka topic.
85
90
86
91
.. code-block:: properties
87
92
:copyable: false
88
93
89
- topic.namespace.map={"myDb": "topicOne", "myDb.myColl\": "topicTwo"}
94
+ topic.namespace.map={"myDb.myColl": "topicOne", "myDb": "topicTwo"}
95
+
96
+ The following examples show which topic the connector sends
97
+ different change stream documents to using the preceding mapping:
90
98
91
- | You can use the "*" wildcard character to match change stream
99
+ - A change stream document originating from the ``myDb`` database
100
+ and the ``myColl`` collection publishes to the
101
+ ``topicOne`` topic.
102
+ - A change stream document originating from the ``myDb`` database
103
+ and the ``newColl`` collection publishes to the
104
+ ``topicTwo.newColl`` topic.
105
+ - A change stream document originating from dropping the
106
+ ``myDb`` database, which does not bear a collection name,
107
+ publishes to the ``topicTwo`` topic.
108
+
109
+ | You can use the ``"*"`` wildcard character to match change stream
92
110
document namespaces.
93
111
94
112
.. example::
95
113
96
114
The following mapping instructs the connector to publish all change
97
- stream document namespaces to the ``topicThree`` topic:
115
+ stream documents to the ``topicThree`` topic:
98
116
99
117
.. code-block:: properties
100
118
:copyable: false
101
119
102
120
topic.namespace.map={"*": "topicThree"}
103
121
104
- | **Default**: ""
122
+ | **Default**: ``""``
105
123
| **Accepted Values**: A valid JSON object
106
124
107
125
* - | **topic.separator**
0 commit comments