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

ReplaceText infinite loops when attribute contains $ sign

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 0.6.1
    • Fix Version/s: 1.0.0, 0.7.0, 1.0.0-Beta
    • Component/s: Core Framework
    • Labels:
      None

      Description

      I think the biggest issue is that the text inside of an attribute isn't properly escaped when written to a String, which brings conflict when the text contains dollar signs ($)

      That's a big roadblock for me as I can't predict if and when some $ signs may be present in the data

      An easy way to reproduce is to take the csv to json template here:
      https://cwiki.apache.org/confluence/download/attachments/57904847/CsvToJSON.xml?version=1&modificationDate=1442927496000&api=v2

      In the first ReplaceText, replace a,b,c,d by a$a,b,c,d (it simulates data that may or may not contain a $ sign)
      Launch the flow, you'll see the errors / warning / infinite loop

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                ozhurakousky Oleg Zhurakousky
                Reporter:
                stephane.maarek@gmail.com Stephane Maarek
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: