A map schema might be appropriate. Another idea might be to define a record for every field, then use an array whose values are a union of all these records. This is a bit more complicated but would probably use the least space.
Doug On Thu, Jun 25, 2020 at 4:14 PM Sohail Khan <[email protected]> wrote: > Hello Team, > > I am trying to serialize data in AVRO format and store it in Database. > This would bring down the disk requirement of the table. Currently we are > storing it in JSON format. > I Have a very huge POJO with string type fields (Approximately 100), but > for a given POJO hardly 20 or 30 have values, rest are null. I call it a > sparse object. I am currently achieving approximately 20 percent > improvement. Any suggestions, How to take it further, what are the best > practices w.r.t to handling null values > > Thanks and Regards > Sohail Khan >
