Skip to content

Commit

Permalink
(DOCSP-20664) Topic Separator (#229)
Browse files Browse the repository at this point in the history
  • Loading branch information
biniona-mongodb authored and schmalliso committed Apr 26, 2022
1 parent ea0c569 commit 45af927
Showing 1 changed file with 44 additions and 1 deletion.
45 changes: 44 additions & 1 deletion source/source-connector/configuration-properties/kafka-topic.txt
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ Settings
- | **Type:** string
|
| **Description:**
| Specifies a JSON mapping between change stream document namespaces
| Specifies a JSON mapping between change stream document
:manual:`namespaces </reference/glossary/#std-term-namespace>`
and topic names.

.. example::
Expand Down Expand Up @@ -103,6 +104,48 @@ Settings
| **Default**: ""
| **Accepted Values**: A valid JSON object

* - | **topic.separator**
- | **Type:** string
|
| **Description:**
| Specifies the string the connector uses to concatenate the values used
to create the name of your topic. The connector publishes records to a
topic with a name formed by concatenating the values of the following fields
in the following order:

#. ``topic.prefix``
#. ``database``
#. ``collection``
#. ``topic.suffix``

.. example::

The following configuration instructs the connector to publish
change stream documents from the ``coll`` collection of the
``db`` database to the ``prefix-db-coll``
topic:

.. code-block:: properties
:copyable: false

topic.prefix=prefix
database=db
collection=coll
topic.separator=-

.. important:: Topic Separator and Topic Namespace Map

When you use the ``topic.separator`` property, keep in mind that it
does not affect how you define the ``topic.namespace.map`` property.
The ``topic.namespace.map`` property uses MongoDB
:manual:`namespaces </reference/glossary/#std-term-namespace>`
which you must always specify with a ``"."`` character to separate
the database and collection name.

|
| **Default**: ``"."``
| **Accepted Values**: A string

* - | **topic.mapper**
- | **Type:** string
|
Expand Down

0 comments on commit 45af927

Please sign in to comment.