Skip to content

Commit c3ab30a

Browse files
author
Chris Cho
authored
Merge pull request #6 from ccho-mongodb/DOCSP-19689-error-tolerance-fix
DOCSP-19689: fix sink connector error tolerance description
2 parents c1b9752 + 214e216 commit c3ab30a

File tree

2 files changed

+26
-24
lines changed

2 files changed

+26
-24
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ meta.yaml
77
fabfile
88
giza.log
99
backups
10-
10+
*.swp

source/sink-connector/configuration-properties/error-handling.txt

Lines changed: 25 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -41,28 +41,30 @@ Settings
4141
|
4242
| **Description:**
4343
| Whether to continue processing messages if the connector encounters
44-
an error.
44+
an error. Allows the connector to override the ``errors.tolerance``
45+
Kafka cluster setting.
4546
| When set to ``none``, the connector reports any error and
4647
blocks further processing of the rest of the messages.
4748
| When set to ``all``, the connector ignores any problematic messages.
48-
| To learn more about error handling strategies, see the
49+
| To learn more about error handling strategies, see the
4950
:ref:`<kafka-sink-handle-errors>` page.
5051

5152
.. note::
5253

5354
This property overrides the `errors.tolerance <https://docs.confluent.io/platform/current/installation/configuration/connect/sink-connect-configs.html#errors-tolerance>`__
5455
property of the Connect Framework.
5556

56-
| **Default:** ``"none"``
57+
| **Default:** Inherits the value from the ``errors.tolerance``
58+
setting.
5759
| **Accepted Values**: ``"none"`` or ``"all"``
5860

5961
* - | **mongo.errors.log.enable**
6062
- | **Type:** boolean
6163
|
6264
| **Description:**
63-
| Whether the connector should write details of errors including
65+
| Whether the connector should write details of errors including
6466
failed operations to the log file. The connector classifies
65-
errors as "tolerated" or "not tolerated" using the
67+
errors as "tolerated" or "not tolerated" using the
6668
``errors.tolerance`` or ``mongo.errors.tolerance`` settings.
6769

6870
| When set to ``true``, the connector logs both "tolerated" and
@@ -95,7 +97,7 @@ Settings
9597
| Name of topic to use as the dead letter queue. If blank, the
9698
connector does not send any invalid messages to the dead letter
9799
queue.
98-
| For more information about the dead letter queue, see the
100+
| For more information about the dead letter queue, see the
99101
:ref:`Dead Letter Queue Configuration Example <sink-dead-letter-queue-configuration-example>`.
100102
|
101103
| **Default:** ``""``
@@ -107,7 +109,7 @@ Settings
107109
| **Description:**
108110
| Whether the connector should include context headers when it
109111
writes messages to the dead letter queue.
110-
| To learn more about the dead letter queue, see the
112+
| To learn more about the dead letter queue, see the
111113
:ref:`Dead Letter Queue Configuration Example <sink-dead-letter-queue-configuration-example>`.
112114
| To learn about the exceptions the connector defines and
113115
reports through context headers, see the
@@ -145,7 +147,7 @@ as context headers when performing bulk writes:
145147

146148
* - Name
147149
- Description
148-
150+
149151
* - | ``WriteException``
150152
- | **Description:**
151153
| Contains details of a
@@ -155,26 +157,26 @@ as context headers when performing bulk writes:
155157
| **Message Format:**
156158

157159
This class outputs the error in the following format:
158-
160+
159161
.. code-block:: none
160162

161163
v=%d, code=%d, message=%s, details=%s
162164

163165
The fields in the preceding message contain the following information:
164166

165167
- ``v``: The version of the ``WriteException`` message format.
166-
This field helps parse the messages produced by this exception.
168+
This field helps parse the messages produced by this exception.
167169
For version {+connector_version+} of the connector, the version of the
168170
message format is {+write-exception-version+}.
169-
- ``code``: The code associated with the error. To learn more see the
171+
- ``code``: The code associated with the error. To learn more see the
170172
`getCode() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/WriteError.html#getCode()>`__
171-
method documentation.
173+
method documentation.
172174
- ``message``: The message associated with the error. To learn more, see the
173175
`getMessage() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/WriteError.html#getMessage()>`__
174-
method documentation.
176+
method documentation.
175177
- ``details``: The details associated with the error in JSON format. To
176178
learn more, see the following method documentation:
177-
179+
178180
- `getDetails() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/WriteError.html#getDetails()>`__
179181
- `toJson() <{+connector_driver_api_doc_url_base+}apidocs/bson/org/bson/BsonDocument.html#toJson()>`__
180182

@@ -187,27 +189,27 @@ as context headers when performing bulk writes:
187189
| **Message Format:**
188190

189191
This class outputs the error in the following format:
190-
192+
191193
.. code-block:: none
192194

193195
v=%d, code=%d, codeName=%d, message=%s, details=%s
194196

195197
The fields in the preceding message contain the following information:
196198

197199
- ``v``: The version of the ``WriteConcernException`` message format.
198-
This field helps parse the messages produced by this exception.
200+
This field helps parse the messages produced by this exception.
199201
For version {+connector_version+} of the
200202
connector, the version of the message format is
201203
{+write-concern-exception-version+}.
202204
- ``code``: The code associated with the error. To learn more see the
203205
`getCode() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/bulk/WriteConcernError.html#getCode()>`__
204-
method documentation.
205-
- ``codeName``: The code name associated with the error. To learn more, see the
206+
method documentation.
207+
- ``codeName``: The code name associated with the error. To learn more, see the
206208
`getCodeName() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/bulk/WriteConcernError.html#getCode()>`__
207-
method documentation.
209+
method documentation.
208210
- ``message``: The message associated with the error. To learn more, see the
209211
`getMessage() <{+connector_driver_api_doc_url_base+}apidocs/mongodb-driver-core/com/mongodb/bulk/WriteConcernError.html#getMessage()>`__
210-
method documentation.
212+
method documentation.
211213
- ``details``: The details associated with the error in JSON format. To
212214
learn more, see the following method documentation:
213215

@@ -227,7 +229,7 @@ as context headers when performing bulk writes:
227229
write operations, see the :ref:`<sink-configuration-message-processing>` page.
228230
| **Message Format:**
229231

230-
This exception produces no message.
232+
This exception produces no message.
231233

232234
To enable bulk write exception reporting to the dead letter queue, use the
233235
following connector configuration:
@@ -244,8 +246,8 @@ following connector configuration:
244246
Dead Letter Queue Configuration Example
245247
---------------------------------------
246248

247-
Apache Kafka version 2.6 added support for handling errant records. The
248-
Kafka connector automatically sends messages that it cannot process to the
249+
Apache Kafka version 2.6 added support for handling errant records. The
250+
Kafka connector automatically sends messages that it cannot process to the
249251
**dead letter queue**. Once on the dead letter queue, you can inspect the
250252
errant records, update them, and resubmit them for processing.
251253

0 commit comments

Comments
 (0)