This is an automated email from the ASF dual-hosted git repository.
liurenjie1024 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/iceberg-rust.git
The following commit(s) were added to refs/heads/main by this push:
new 5677d446 [easy] Add comment on non-existent namespace/table at drop
(#1245)
5677d446 is described below
commit 5677d446dec1361459d42a6c3672d8ec605a289a
Author: dentiny <[email protected]>
AuthorDate: Sat Apr 26 19:33:08 2025 -0700
[easy] Add comment on non-existent namespace/table at drop (#1245)
## What changes are included in this PR?
I added documentation on the behavior when table/namespace to drop
doesn't exist, which I think it's important to consolidate for traits.
I reference `MemoryCatalog` for behavior:
https://github.com/apache/iceberg-rust/blob/main/crates/catalog/memory/src/catalog.rs
## Are these changes tested?
N/A
---
crates/iceberg/src/catalog/mod.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/crates/iceberg/src/catalog/mod.rs
b/crates/iceberg/src/catalog/mod.rs
index 6a1572a4..c59e6e4f 100644
--- a/crates/iceberg/src/catalog/mod.rs
+++ b/crates/iceberg/src/catalog/mod.rs
@@ -67,7 +67,7 @@ pub trait Catalog: Debug + Sync + Send {
properties: HashMap<String, String>,
) -> Result<()>;
- /// Drop a namespace from the catalog.
+ /// Drop a namespace from the catalog, or returns error if it doesn't
exist.
async fn drop_namespace(&self, namespace: &NamespaceIdent) -> Result<()>;
/// List tables from namespace.
@@ -83,7 +83,7 @@ pub trait Catalog: Debug + Sync + Send {
/// Load table from the catalog.
async fn load_table(&self, table: &TableIdent) -> Result<Table>;
- /// Drop a table from the catalog.
+ /// Drop a table from the catalog, or returns error if it doesn't exist.
async fn drop_table(&self, table: &TableIdent) -> Result<()>;
/// Check if a table exists in the catalog.