rzhang10 commented on PR #4525:
URL: https://github.com/apache/iceberg/pull/4525#issuecomment-1095460067

   @rdblue 
   
   I see your major concern in the reviews are regarding using Jackson in 
Iceberg-api module.
   
   Let me put my thoughts here in one place to answer all the questions above, 
the core problem is whether we should represent the default value in memory in 
`JsonNode` or Java primitives.
   
   The reason I chose Jackson is that:
   - Jackson has more robust json validation utils, which come in handy here.
   - Jackson `JsonNoe` is also `java.io.Serializable`.
   - Jackson is also used in the Iceberg-core module as a dependency. I believe 
whenever iceberg is used as a library, iceberg-api and iceberg-core will both 
be dependent upon. So I wouldn't believe introducing Jackson in the API module 
will (additionally) pollute downstream dependencies.
   
   If we take the java primitive approach, I think my current code could be 
adapted this way:
   
   Maintain the current json validation logic, then add a `ValueParser` with 
`toJson` and `fromJson` to convert between json and their respective java 
primitive representations. The structure of the current code will pretty much 
stay the same.
   
   Let me know your thoughts and I'm open to further discussions too.


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to