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

MongoDB multiple tasks monitor misalignment

    XMLWordPrintable

Details

    • False
    • None
    • False

    Description

      I'm using the debezium on MongoDB to read my target DB – a sharded cluster with 2 replica sets.
      To do that, my connector-properties looks like this:

      connectors-properties:
      {{   my-event-mongo-cdc-connector:}}
      {{     name: my-event-mongo-cdc-connector}}
      {{     connector.class: io.debezium.connector.mongodb.MongoDbConnector}}
      {{     mongodb.name: ${mongodb.name}}}
      {{     mongodb.hosts: ${mongodb-config-replica-set.primary_host}        tasks.max: 2}}
      The rest works well but when it comes to monitoring, it keeps reporting "Unable to register metrics as an old set with the same name exists". And I believe the reason why here is that since I have 2 tasks per replica set, i.e. I have MongoDB connector task 0 & task 1. But they both share the same mongodb.name since 2 replica sets are coming from reading the single config set. So the problem here is 1 mongodb.name corresponds to 1 config set, but has 2 connector/tasks since the sharded cluster has 2 replica sets to read.

      Bug report

      For bug reports, provide this information, please:

      What Debezium connector do you use and what version?

      1.9.5.final

      What is the connector configuration?

      connectors-properties:
      {{   my-event-mongo-cdc-connector:}}
      {{     name: my-event-mongo-cdc-connector}}
      {{     connector.class: io.debezium.connector.mongodb.MongoDbConnector}}
      {{     mongodb.name: ${mongodb.name}}}
      {{     mongodb.hosts: ${mongodb-config-replica-set.primary_host}        tasks.max: 2}}

      What is the captured database version and mode of depoyment?

      (E.g. on-premises, with a specific cloud provider, etc.)

      <Your answer>

      What behaviour do you expect?

      2 monitors automatically created per task

      What behaviour do you see?

      Monitor keeps reporting "Unable to register metrics as an old set with the same name exists"

      Do you see the same behaviour using the latest relesead Debezium version?

      (Ideally, also verify with latest Alpha/Beta/CR version)

      <Your answer>

      Do you have the connector logs, ideally from start till finish?

      (You might be asked later to provide DEBUG/TRACE level log)

      <Your answer>

      How to reproduce the issue using our tutorial deployment?

      <Your answer>

      Feature request or enhancement

      For feature requests or enhancements, provide this information, please:

      Which use case/requirement will be addressed by the proposed feature?

      <Your answer>

      Implementation ideas (optional)

      <Your answer>

      Attachments

        Activity

          People

            jcechace@redhat.com Jakub Čecháček
            bufei Buyan Fei (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: