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

ValidateXML does not provide a meaningful message in the 'validatexml.invalid.error' attribute when invalid XML is validated and no schema is provided

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 1.28.0, 2.0.0
    • None
    • None

    Description

      Currently if invalid XML is validated in the ValidateXML processor without a schema being provided the 'validatexml.invalid.error' attribute only contains "Reading stream failed". This is not helpful as to why this failed.
      A case in point is the unit test testInvalidXMLContentStructure in TestValidateXml.
      Instead of "Reading stream failed" it could have

      ParseError at [row,col]:[1,22]
      Message: The element type "this" must be terminated by the matching end-tag "</this>".
      

      which would be more useful in diagnosing what went wrong.

      Attachments

        Issue Links

          Activity

            People

              dstiegli1 Daniel Stieglitz
              dstiegli1 Daniel Stieglitz
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m