nssalian commented on pull request #3275: URL: https://github.com/apache/iceberg/pull/3275#issuecomment-946079146
> I didn't follow this. Can you explain it a bit more for me? The `JdbcTableOperations` doesn't seem to have the properties that are used to initialize the `JdbcCatalog`. I noticed this in tests. For `namespaceExists` to work in `JdbcTableOperations` there has to be an instance of `JdbcCatalog` in `JdbcTableOperations`. More explanation: 1. I added this field https://github.com/apache/iceberg/blob/a72de755ac3985af1db61f8cc4080834fd59feb8/core/src/main/java/org/apache/iceberg/jdbc/JdbcCatalog.java#L74 to be passed https://github.com/apache/iceberg/blob/a72de755ac3985af1db61f8cc4080834fd59feb8/core/src/main/java/org/apache/iceberg/jdbc/JdbcCatalog.java#L144 2. This helps to initialize the catalog with the same connection properties as the JdbcCatalog: https://github.com/apache/iceberg/blob/a72de755ac3985af1db61f8cc4080834fd59feb8/core/src/main/java/org/apache/iceberg/jdbc/JdbcTableOperations.java#L65 Maybe there's a cleaner way to do this that I am missing. -- 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]
