kbendick opened a new issue #2628:
URL: https://github.com/apache/iceberg/issues/2628


   `BaseMetastoreTableOperations#checkCommitStatus` will either throw an NPE 
when called on a table backed by the Nessie Catalog, or will log the table name 
as `null` even though it is known.
   
   `checkCommitStatus` uses `BaseMetastoreTableOperations#tableName` for 
logging, which is not declared as abstract and by default returns `null`.
   
   `GlueTableOperations` and `HiveTableOperations` both override this method, 
and so won't throw an NPE or use `null` as the table name when logging if 
`checkCommitStatus` is called 
   
   However, `NessiteTableOperations` does not override `tableName`, and thus 
will either throw or log `null` for the table name.
   
   If we make `BaseMetastoreTableOperations#tableName` into an abstract method, 
then this error would be caught at compile time.
   
   Currently, because the logger uses `tableName()` as a string format 
argument, I believe that currently the table name will simply be logged as 
`null` (which will still be confusing to users and should be fixed).
   
   In the event of a refactor, an NPE is very likely as there are no compile 
time checks that this method is properly overridden, unless we mark it as 
`abstract`.


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



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

Reply via email to