You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Peter Gyori (Jira)" <ji...@apache.org> on 2022/03/24 15:25:00 UTC
[jira] [Created] (NIFI-9832) XMLReader: XML element's content disappears if the element has attribute
Peter Gyori created NIFI-9832:
---------------------------------
Summary: XMLReader: XML element's content disappears if the element has attribute
Key: NIFI-9832
URL: https://issues.apache.org/jira/browse/NIFI-9832
Project: Apache NiFi
Issue Type: Bug
Components: Extensions
Reporter: Peter Gyori
Assignee: Peter Gyori
Let's use a ConvertRecord processor with an XMLReader and an XMLRecordSetWriter to process XML documents.
XMLReader controller service settings:
* Schema Access Strategy: Infer Schema
* Expect Records as Array: false
XMLRecordSetWriter controller service settings:
* Schema Access Strategy: Inherit Record Schema
ConvertRecord processor settings:
* Record Reader: XMLReader
* Record Writer: XMLRecordSetWriter
Input data:
{code:java}
<record>
<num>123</num>
<software favorite="true">Apache NiFi</software>
</record> {code}
Output:
{code:java}
<record>
<num>123</num>
<software>
<favorite>true</favorite>
<value></value>
</software>
<favorite></favorite>
</record> {code}
The value "Apache NiFi" is lost.
(The issue of the additional "favorite" xml element is covered in https://issues.apache.org/jira/browse/NIFI-9831)
--
This message was sent by Atlassian Jira
(v8.20.1#820001)