Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-4201

wrong field on change event message example in MongoDB Connector documentation

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Done
    • Icon: Trivial Trivial
    • 1.8.0.Alpha1
    • None
    • mongodb-connector
    • None
    • False
    • False

      According to MongoDB Connector documentation,
      the example of data message Envelope when transaction metadata is enabled looks like this.

      {
        "patch": null,
        "after": {
          "pk": "2",
          "aa": "1"
        },
        "source": {
      ...
        },
        "op": "c",
        "ts_ms": "1580390884335",
        "transaction": {
          "id": "1462833718356672513",
          "total_order": "1",
          "data_collection_order": "1"
        }
      }
      

      But, before, after, and patch field should be JSON string format in MongoDB Connector as follows, not a structured format.

      {
        "patch": null,
        "after": "{\"_id\" : {\"$numberLong\" : \"1004\"},\"first_name\" : \"Anne\",\"last_name\" : \"Kretchmar\",\"email\" : \"annek@noanswer.org\"}",
        "source": {
      ...
        },
        "op": "c",
        "ts_ms": "1580390884335",
        "transaction": {
          "id": "1462833718356672513",
          "total_order": "1",
          "data_collection_order": "1"
        }
      }
      

              Unassigned Unassigned
              sunghohwang Sungho Hwang (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: