[ 
https://issues.apache.org/jira/browse/NIFI-10957?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Pierre Villard resolved NIFI-10957.
-----------------------------------
    Resolution: Feedback Received

Apache NiFi 1.x is no longer maintained and no new release is planned on the 
1.x release line. Marking as resolved as part of a cleanup operation. Please 
open a new one with an updated description if this is still relevant for NiFi 
2.x.

> JsonTreeReader: schema inference gives wrong result
> ---------------------------------------------------
>
>                 Key: NIFI-10957
>                 URL: https://issues.apache.org/jira/browse/NIFI-10957
>             Project: Apache NiFi
>          Issue Type: Bug
>    Affects Versions: 1.16.3, 1.19.0
>            Reporter: Jean-Pierre Milhau
>            Priority: Major
>
> I am using the JsonTreeReader with the schema access strategy set to Infer 
> schema.
>  
> For the following data in input:
> {code:java}
> {"alt": 12}
> {"alt": null}{code}
> the inferred schema gives field "alt" as a nullable INT, what is good.
>  
> But for the following data in input:
> {code:java}
> {"location": {"alt": 12}}
> {"location": {"alt": null}}{code}
> the inferred schema gives field "alt" (inside record "location") as a 
> nullable CHOICE(STRING, INT), what seems to me incorrect because there is no 
> string value for field "alt". I am expecting field "alt" as a nullable INT as 
> when it is on the root of the json document.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to