ftelnov commented on PR #2299:
URL: https://github.com/apache/avro/pull/2299#issuecomment-1604178351

   > The other day I started reviewing this PR but then I stopped for the 
following reasons:
   > 
   >     * @RyanSkraba said that he is going to release 1.11.2 in the coming 
days and I didn't want to make such changes in the last moment
   > 
   >     * then @clesaec suggested [AVRO-3779: using rust bigdecimal 
#2302](https://github.com/apache/avro/pull/2302) - using a proper BigDecimal 
type as a backing type is something that I wanted to explore some day. With it 
it is much easier to parse from and format to different types (String, floating 
number, byte array). The drawback here is that this is something new (to be 
added in the spec) and it may not work for someone who wants to use Avro SDKs 
which does not support it yet
   
   I think we must switch to BigDecimal anyway. It wraps BigInt and that is 
what we need to use and not to write ourselves. Therefore, you can freely close 
this PR, and I'll get with another issue of rewriting decimal to bigdecimal 
usage, if that is what you would prefer.
   
   I thought @clesaec suggested adding new schema type for some purpose - which 
is not good in my opinion. His idea to include serialization to the resulted 
decimal is, indeed, pretty good. It's a complete pain holding schema every time 
we want to operate with decimal - as without schema you can't understand what 
is the scale and precision. Maybe there was some idea behind such a decision. 
However, as you mentioned, it would require spec update.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to