krvikash opened a new pull request, #6511: URL: https://github.com/apache/iceberg/pull/6511
**Issue:** As per documentation of [`SessionCataog.dropTable`](https://github.com/apache/iceberg/blob/2a3a297d134aeaaf2bc19bc75135bea89811228b/api/src/main/java/org/apache/iceberg/catalog/SessionCatalog.java#L180-L189) says > Drop a table, without requesting that files are immediately deleted. But the [`RESTSessionCatalog#dropTable`](https://github.com/apache/iceberg/blob/67b5ca239ead5549122a5b10e8a372cd1c8dca81/core/src/main/java/org/apache/iceberg/rest/RESTSessionCatalog.java#L221-L232) API purges the table even if we are not setting `purgeRequested` to `true`. The issue is happening because, While handling `DROP_TABLE` request in [`RESTCatalogAdapter`](https://github.com/apache/iceberg/blob/79bf0f69a2ccc723174c40a1678bc0dcdf32ae7f/core/src/test/java/org/apache/iceberg/rest/RESTCatalogAdapter.java#L323-L331), the call goes to `CatalogHandlers.dropTable(Catalog catalog, TableIdentifier ident)` when `purgeRequested` is not set and internally calls `catalog.dropTable(ident)` that always drops the table with purge. https://github.com/apache/iceberg/blob/cd21f68e7bb62d3be76e98ac519849944e4dbedf/core/src/main/java/org/apache/iceberg/rest/CatalogHandlers.java#L225-L230 **Fix:** Fix `CatalogHandlers.dropTable(Catalog catalog, TableIdentifier ident)` API that drops the table without purge. This PR is to fix the `dropTable` API for REST Session Catalog for dropping table without purging. -- 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]
