[
https://issues.apache.org/jira/browse/AVRO-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thiruvalluvan M. G. updated AVRO-706:
-------------------------------------
Resolution: Fixed
Status: Resolved (was: Patch Available)
Committed revision 1041903.
Thanks Doug for reviewing the fix.
> Java: Type promotion not succeeding for long -> float
> -----------------------------------------------------
>
> Key: AVRO-706
> URL: https://issues.apache.org/jira/browse/AVRO-706
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.4.1
> Reporter: Scott Carey
> Assignee: Thiruvalluvan M. G.
> Fix For: 1.5.0
>
> Attachments: AVRO-706.patch
>
>
> A bug reported on the dev email list. I have not confirmed it:
> {quote}
> Hi,
> Avro spec says that writer schema's long can be promoted to reader
> schema's float or double. In my test, I'm getting ErrorAction from
> ResolvingGrammarGenerator.generate() when writer schema is long and
> reader schema expects float. Looking at the source code, when reader
> and writer type are not the same, the switch(readerType) only handles
> Long, Double and Union, not Float. This is the reason I'm getting "Found
> Long, expecting Float" error.
> Best regards,
> Xiaolu
> {quote}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.