You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2022/04/12 15:42:00 UTC
[jira] [Commented] (NIFI-9832) XMLReader: XML element's content disappears if the element has attribute
[ https://issues.apache.org/jira/browse/NIFI-9832?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17521217#comment-17521217 ]
ASF subversion and git services commented on NIFI-9832:
-------------------------------------------------------
Commit 68c6722f76aedd24805ff4999331af5e97ccf9b2 in nifi's branch refs/heads/main from Peter Gyori
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=68c6722f76 ]
NIFI-9832: Fix disappearing XML element content when the element has attribute (#5896)
- NIFI-9832: Additional test cases for XMLReader
> 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
> Priority: Major
> Labels: reader, xml
> Time Spent: 3.5h
> Remaining Estimate: 0h
>
> 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)