Uploaded image for project: 'Camel-K'
  1. Camel-K
  2. CMLK-268

Jira source - duplicate messages when more than one issue is created within the poll delay

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • camel-k-1.10.1
    • camel-k-1.8.2
    • None
    • None
    • 0

      When more than one JIRA is created within poll delay which fulfills the JQL, it will be handled more times in the next poll. It depends on how many issues were created within the poll delay. The last one will be in the Kafka topic N times (N is the number of issues that were created at the same time).

      So for example, when I create 4 JIRAs at the same time.
      1. poll returns 4 new unique JIRAs, which I have created,
      2. poll returns 3 JIRAs that were be already handled (so these are two times in the Kafka topic)
      3. poll returns 2 JIRAs that were already handled (so these are three times in the Kafka topic)
      4. poll returns 1 JIRA that was already handled (so this one is four in the Kafka topic)

      Let's say I have jira-source connector with JQL

      project=FUSEQE AND text ~ "mkralik test"
      

      When I create 1. JIRA (JPROJECT-1) and wait 6 seconds, the Kafka topic contains one message.

      Offset 0 , "key": "JPROJECT-1",
      

      When I create 2. JIRA (JPROJECT-2) and wait 6 seconds, the Kafka topic contains one message for that JIRA.

      Offset 1 , "key": "JPROJECT-2",
      Offset 0 , "key": "JPROJECT-1",
      

      When I create 3. jira (JPROJECT-3) and wait 6 seconds, the Kafka topic contains one message for that JIRA.

      Offset 2 , "key": "JPROJECT-3",
      Offset 1 , "key": "JPROJECT-2",
      Offset 0 , "key": "JPROJECT-1",
      

      However, when I create e.g. 3 JIRAs (JPROJECT-4, JPROJECT-5, JPROJECT-6) in the same time within 6 second, the Kafka topic looks like:
      After first 6 seconds:

      Offset 5 , "key": "JPROJECT-6",
      Offset 4 , "key": "JPROJECT-5",
      Offset 3 , "key": "JPROJECT-4",
      Offset 2 , "key": "JPROJECT-3",
      Offset 1 , "key": "JPROJECT-2",
      Offset 0 , "key": "JPROJECT-1",
      

      After next 6 seconds:

      Offset 7 , "key": "JPROJECT-6",
      Offset 6 , "key": "JPROJECT-5",
      Offset 5 , "key": "JPROJECT-6",
      Offset 4 , "key": "JPROJECT-5",
      Offset 3 , "key": "JPROJECT-4",
      Offset 2 , "key": "JPROJECT-3",
      Offset 1 , "key": "JPROJECT-2",
      Offset 0 , "key": "JPROJECT-1",
      

      After next 6 seconds:

      Offset 8 , "key": "JPROJECT-6",
      Offset 7 , "key": "JPROJECT-6",
      Offset 6 , "key": "JPROJECT-5",
      Offset 5 , "key": "JPROJECT-6",
      Offset 4 , "key": "JPROJECT-5",
      Offset 3 , "key": "JPROJECT-4",
      Offset 2 , "key": "JPROJECT-3",
      Offset 1 , "key": "JPROJECT-2",
      Offset 0 , "key": "JPROJECT-1",
      

      JPROJECT-5 = 1 duplicity
      JPROJECT-6 = 2 duplicities

            christoph.deppisch Christoph Deppisch
            mkralik@redhat.com Matej Kralik
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: