Skip to content

Commit 945e807

Browse files
[DOCS] Add mongodb connector UUID known issue (#129492)
* Update es-connectors-mongodb.md * Apply suggestions from code review Co-authored-by: Charlotte Hoblik <[email protected]> * Update docs/reference/search-connectors/es-connectors-mongodb.md Co-authored-by: Charlotte Hoblik <[email protected]> --------- Co-authored-by: Charlotte Hoblik <[email protected]>
1 parent 10c0799 commit 945e807

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

docs/reference/search-connectors/es-connectors-mongodb.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,21 @@ A bug introduced in **8.12.0** causes the Connectors docker image to error out i
251251

252252
See [Known issues](/release-notes/known-issues.md) for any issues affecting all connectors.
253253

254+
#### UUIDs are not correctly deserialized, causing problems with ingesting documents into Elasticsearch
255+
256+
MongoDB has special handling of UUID type: there is a legacy and a modern approach. You can read [official docs](https://pymongo.readthedocs.io/en/stable/examples/uuid.html) about the details.
257+
258+
With connector framework version 9.0.3, we improved how standard UUIDs are handled. Now, the MongoDB connector can correctly deserialize UUIDs into valid Elasticsearch values. However, for legacy UUIDs or older connector versions, you might need to adjust the connection string to specify the UUID representation.
259+
260+
For example, if you are using the modern UUID representation, adding the `uuidRepresentation=standard` query parameter to the MongoDB connection URI in the `host` Rich Configurable Field will allow the connector to properly handle UUIDs. With this change, the full `host` Rich Configurable Field value could look like this:`mongodb+srv://my_username:[email protected]/mydb?w=majority&uuidRepresentation=standard`
261+
262+
If you’re using a legacy UUID representation, you should adjust the connection URI accordingly. For example:
263+
264+
- C#: `uuidRepresentation=csharpLegacy`
265+
- Java: `uuidRepresentation=javaLegacy`
266+
- Python: `uuidRepresentation=pythonLegacy`
267+
268+
You can find a full explanation in the [official docs](https://pymongo.readthedocs.io/en/stable/examples/uuid.html#configuring-a-uuid-representation).
254269

255270
### Troubleshooting [es-connectors-mongodb-client-troubleshooting]
256271

0 commit comments

Comments
 (0)