Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-7544

ReplaceText processor seems not thread-safe?

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • 1.11.4
    • 1.12.0
    • Core Framework
    • None
    • Red Hat Enterprise Linux 7.8
      openjdk version "11.0.7" 2020-04-14 LTS
      OpenJDK Runtime Environment 18.9 (build 11.0.7+10-LTS)
      OpenJDK 64-Bit Server VM 18.9 (build 11.0.7+10-LTS, mixed mode, sharing)

    Description

      We have a flow where there are separate flow files containing a single string. We use the ReplaceText processor to prepend this string by a parameter name (for use in an actual URI, as query parameter) and postfix the string by an ampersand: 

      When using this processor with number of concurrrent tasks > 1 (4 in our case), we have seen it happening that content of file-A is inserted as the result of file-B, it seems as if the process is not thread safe where the actual search value is captured.

      We can see from the logfile (created by inserting LogAttribute processors logging uuid and the actual content after all steps in the process) that the input of one file is overwritten with the search/replace pattern of another file (just before it), see uploaded log file

       

      Attachments

        1. apache-nifi.txt
          5 kB
          Milco Numan
        2. ReplaceText-Configuration.png
          27 kB
          Milco Numan

        Issue Links

          Activity

            People

              Unassigned Unassigned
              milco.numan@gmail.com Milco Numan
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: