rdblue commented on issue #207: Add external schema mappings for files written 
with name-based schemas #40
URL: https://github.com/apache/incubator-iceberg/pull/207#issuecomment-533836622
 
 
   @rdsr, thanks for your work on this!
   
   I think there are some subtle problems with this because it changes 
assumptions about null values. For example, if an array-based map is not 
projected, the element struct will be an empty struct, not null. This assumes 
it will be null.
   
   The main problem is that I'm having trouble reasoning about the changes in 
this PR to decide whether they are correct. That makes me think that combining 
projection with the read schema building is risky because it makes the whole 
thing hard to maintain.
   
   What about instead of adding the name mapping and projection into the 
visitor building a read schema you instead added the mapping to PruneColumns? I 
think that would make sense: if a field doesn't have an ID, it is pruned; if it 
is mapped, then it may be pruned depending on the projected ID set. Then we 
wouldn't need to change the code for building a projection at all and both 
classes would be simpler. What do you think?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to