Skip to content

feat: Warehouse Cache - #1462

Merged
c-thiel merged 6 commits into
mainfrom
ct/warehouse-cache-impl
Oct 27, 2025
Merged

c-thiel merged 6 commits into
mainfrom
ct/warehouse-cache-impl

Conversation

@c-thiel

@c-thiel c-thiel commented Oct 26, 2025 •

Copy link
Copy Markdown
Member

BEGIN_COMMIT_OVERRIDE
feat: Add Warehouse Cache to reduce DB requests

feat: Management endpoints now return full warehouse details after updates
feat!: Deprecate id in favor of warehouse_id in GetWarehouseResponse
chore: Rename SecretIdent to SecretId for consistency
END_COMMIT_OVERRIDE

Summary by CodeRabbit

  • New Features

    • Management endpoints now return full, up-to-date warehouse details after successful operations.
    • Warehouse caching added to improve performance and reduce repeated lookups.
    • Table and view responses expose an optional warehouse "last updated" timestamp.
  • Breaking Changes

    • Public warehouse identifier renamed to warehouse_id (old id deprecated).
    • Create responses now embed full warehouse details instead of inline IDs.
    • Secret identifier type renamed to SecretId — integrations may need updates.
  • Documentation

    • Configuration docs add Warehouse Cache settings and metrics.

@coderabbitai

coderabbitai Bot commented Oct 26, 2025 •

Copy link
Copy Markdown
Contributor

Walkthrough

The PR changes warehouse and secret types across the codebase: service APIs, Postgres implementations, server call sites, and OpenAPI now return richer warehouse payloads (ResolvedWarehouse / GetWarehouseResponse, often Arc-wrapped), adds a warehouse cache subsystem, wires warehouse.updated_at into tabular/view flows, and renames SecretIdent → SecretId.

Changes

Cohort / File(s) Summary
Management API
crates/lakekeeper/src/api/management/mod.rs, crates/lakekeeper/src/api/management/v1/warehouse/mod.rs, docs/docs/api/management-open-api.yaml
Management endpoints now return GetWarehouseResponse (create wraps it). OpenAPI updated: adds warehouse-id, updated-at, and deprecates id. Handler return types updated accordingly.
Service API & Types
crates/lakekeeper/src/service/catalog_store.rs, crates/lakekeeper/src/service/catalog_store/warehouse.rs, crates/lakekeeper/src/service/catalog_store/view.rs, crates/lakekeeper/src/service/catalog_store/table.rs
Public APIs now return ResolvedWarehouse / Arc<ResolvedWarehouse> (Option/Vec variants). CatalogView and table view responses gain warehouse_updated_at. SecretIdent → SecretId. Added warehouse cache helpers and CachePolicy.
Postgres implementations
crates/lakekeeper/src/implementations/postgres/warehouse.rs, crates/lakekeeper/src/implementations/postgres/catalog.rs
SQL flows RETURN full rows; introduced WarehouseRecord -> ResolvedWarehouse conversion. Many impl signatures changed to return ResolvedWarehouse/Arc variants; updated updated_at handling.
Warehouse cache
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs, crates/lakekeeper/src/service/catalog_store/warehouse.rs
New moka-backed caches (id -> CachedWarehouse, name -> id), insert/get-by-id/get-by-name helpers, eviction handling, metrics, cache-aware get/require wrappers and insertion logic.
Tabular / view plumbing
crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs, crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs, crates/lakekeeper/src/server/tables/load_table.rs, crates/lakekeeper/src/server/views/load.rs, crates/lakekeeper/src/server/views/commit.rs
SQL projections and row mappings include warehouse_updated_at; load/commit flows propagate that timestamp and fetch warehouse cache-aware; storage_profile / secret sourced from resolved warehouse.
Server call sites & config
crates/lakekeeper/src/server/config.rs, crates/lakekeeper/src/server/namespace.rs, crates/lakekeeper/src/server/tables.rs, crates/lakekeeper/src/server/tables/create_table.rs, crates/lakekeeper/src/server/s3_signer/sign.rs, crates/lakekeeper/src/server/views/create.rs
Call sites switched to warehouse.warehouse_id (or accessor), pass warehouse_id accordingly, clone storage_profile where reused, add location checks in table commit paths.
Secrets surface & implementations
crates/lakekeeper/src/service/secrets.rs, crates/lakekeeper/src/implementations/kv2.rs, crates/lakekeeper/src/implementations/postgres/secrets.rs, crates/lakekeeper/src/implementations/mod.rs, crates/lakekeeper/src/lib.rs
Renamed public type SecretIdent → SecretId; updated trait signatures, conversions, impls, and re-exports to use SecretId.
Config, tests & serve hooks
crates/lakekeeper/src/config.rs, crates/lakekeeper/src/tests/*, crates/lakekeeper/src/serve.rs, docs/docs/configuration.md
Added WarehouseCache config (enabled, capacity default 1000) and tests; server registers WarehouseCacheEndpointHook when enabled; docs updated with cache config and metrics.
Endpoint hooks & request metadata
crates/lakekeeper/src/service/endpoint_hooks.rs, crates/lakekeeper/src/request_metadata.rs
Added warehouse lifecycle hook methods and related request types; introduced ProjectIdMissing error and changed require_project_id to return it.
Other refactors
crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs, crates/lakekeeper/src/server/mod.rs, crates/lakekeeper/src/server/views/commit.rs
Adjusted table/load/view structs to carry warehouse_updated_at; maybe_get_secret now accepts Option<SecretId>. Minor cloning/borrow changes for storage_profile usage.

Sequence Diagram(s)

sequenceDiagram
    autonumber
    participant Client
    participant API as Management API
    participant Service
    participant Cache
    participant DB

    Client->>API: rename_warehouse(req)
    API->>Service: rename_warehouse(...)
    Service->>Cache: warehouse_cache_get_by_id(id)
    alt cache hit
        Cache-->>Service: Arc<ResolvedWarehouse> (cached)
    else cache miss
        Service->>DB: UPDATE ... RETURNING full row (incl. updated_at)
        DB-->>Service: WarehouseRecord
        Service->>Service: WarehouseRecord -> ResolvedWarehouse
        Service->>Cache: warehouse_cache_insert(Arc<ResolvedWarehouse>)
    end
    Service-->>API: GetWarehouseResponse (from ResolvedWarehouse)
    API-->>Client: 200 OK + GetWarehouseResponse
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

  • Areas needing careful review:
    • crates/lakekeeper/src/service/catalog_store/warehouse.rs — Arc usage, cache semantics, cache-aware API correctness.
    • crates/lakekeeper/src/implementations/postgres/warehouse.rs & catalog.rs — SQL RETURNING changes, WarehouseRecord -> ResolvedWarehouse mapping, updated_at and DB integrity error paths.
    • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs — concurrent insert/eviction logic, secondary-index consistency, metrics updates.
    • Widespread type rename SecretIdent → SecretId — ensure all trait boundaries, impls, and re-exports updated.
    • OpenAPI docs (docs/.../management-open-api.yaml) — schema changes and deprecation flags align with code.

Possibly related PRs

Poem

🐰 I hopped through code with nimble paws,
Warehouses now carry clocks and laws,
Cached and Arc-wrapped, tidy and bright,
warehouse_id and updated_at in sight,
A rabbit's cheer for clearer bytes!

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 55.64% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title "feat: Warehouse Cache" directly and clearly identifies the primary feature being introduced in this pull request. The raw summary confirms that a comprehensive warehouse caching subsystem has been added, including a new module crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs with a moka-backed caching infrastructure, cache-aware retrieval methods, metrics, and configuration support. While the changeset includes supporting refactorings (such as renaming GetWarehouseResponse to ResolvedWarehouse and SecretIdent to SecretId, and updating numerous API signatures), these changes serve as infrastructure to enable the warehouse cache feature. The title is specific, concise, and accurately captures the main objective without being vague or overly broad.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch ct/warehouse-cache-impl

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
crates/lakekeeper/src/server/config.rs (1)

85-111: Ambiguous 'warehouse' query parsing; enforce valid formats.

If the argument contains a slash and the first segment is not a UUID, parse_warehouse_arg currently treats the whole string as a warehouse “name” (despite the “names cannot include /” constraint). This can cause lookups by name with embedded '/', or accidental acceptance of invalid input. Recommend validating and returning 400 for malformed inputs.

Apply this refactor to validate strictly and surface a proper BadRequest:

@@
-fn parse_warehouse_arg(arg: &str) -> (Option<ProjectId>, String) {
+fn parse_warehouse_arg(arg: &str) -> Result<(Option<ProjectId>, String), ErrorModel> {
@@
-    let parts: Vec<&str> = arg.splitn(2, '/').collect();
+    let parts: Vec<&str> = arg.splitn(2, '/').collect();
     match parts.len() {
         1 => {
             // No project_id provided
             let warehouse_name = parts[0].to_string();
-            (None, warehouse_name)
+            Ok((None, warehouse_name))
         }
         2 => {
-            // Maybe project_id and warehouse_id provided
-            // If parts[0] is a valid UUID, it is a project_id, otherwise the whole thing is a warehouse_id
+            // Expect '<project_id>/<warehouse_name>'
             match ProjectId::from_str(parts[0]) {
                 Ok(project_id) => {
                     let warehouse_name = parts[1].to_string();
-                    (Some(project_id), warehouse_name)
+                    Ok((Some(project_id), warehouse_name))
                 }
-                Err(_) => (None, arg.to_string()),
+                Err(_) => Err(ErrorModel::bad_request(
+                    "Invalid warehouse parameter. Expected '<project_id>/<warehouse_name>' or '<warehouse_name>'.",
+                    "InvalidWarehouseParameter",
+                    None,
+                )),
             }
         }
         // Because of the splitn(2, ..) there can't be more than 2 parts
         _ => unreachable!(),
     }
 }
@@
-        let warehouse = if let Some(query_warehouse) = query.warehouse {
-            let (project_from_arg, warehouse_from_arg) = parse_warehouse_arg(&query_warehouse);
+        let warehouse = if let Some(query_warehouse) = query.warehouse {
+            let (project_from_arg, warehouse_from_arg) = parse_warehouse_arg(&query_warehouse)?;
             let project_id = request_metadata.require_project_id(project_from_arg)?;
             authorizer

Also applies to: 34-51

🧹 Nitpick comments (12)
crates/lakekeeper/src/tests/mod.rs (1)

168-168: Consider consistent variable naming.

The first warehouse creation (line 152) uses warehouse while additional warehouses use create_wh_response. For better consistency and maintainability, consider using the same variable name pattern for all warehouse creation results.

Apply this diff to align the naming:

-        let create_wh_response = ApiServer::create_warehouse(
+        let warehouse = ApiServer::create_warehouse(

And update line 181:

-        additional_warehouses.push((create_wh_response.warehouse_id(), warehouse_name.clone()));
+        additional_warehouses.push((warehouse.warehouse_id(), warehouse_name.clone()));
crates/lakekeeper/src/config.rs (1)

440-442: Warehouse cache config: looks good; add tests for defaults and env overrides.

Serde defaults and Default impl are correct. Please add tests like test_stc_cache to cover:

  • Default values (enabled=true, capacity=1000)
  • Env overrides (LAKEKEEPER_TEST__CACHE__WAREHOUSE__ENABLED and CAPACITY)

Example to add under the existing #[cfg(test)] mod:

@@
     #[test]
     fn test_stc_cache() {
         …
     }
+
+    #[test]
+    fn test_warehouse_cache_defaults_and_env() {
+        // Defaults
+        figment::Jail::expect_with(|_jail| {
+            let config = get_config();
+            assert!(config.cache.warehouse.enabled);
+            assert_eq!(config.cache.warehouse.capacity, 1000);
+            Ok(())
+        });
+
+        // Override enabled=false
+        figment::Jail::expect_with(|jail| {
+            jail.set_env("LAKEKEEPER_TEST__CACHE__WAREHOUSE__ENABLED", "false");
+            let config = get_config();
+            assert!(!config.cache.warehouse.enabled);
+            Ok(())
+        });
+
+        // Override enabled=true and capacity
+        figment::Jail::expect_with(|jail| {
+            jail.set_env("LAKEKEEPER_TEST__CACHE__WAREHOUSE__ENABLED", "true");
+            jail.set_env("LAKEKEEPER_TEST__CACHE__WAREHOUSE__CAPACITY", "2048");
+            let config = get_config();
+            assert!(config.cache.warehouse.enabled);
+            assert_eq!(config.cache.warehouse.capacity, 2048);
+            Ok(())
+        });
+    }

Also applies to: 460-474

crates/lakekeeper/src/server/views/load.rs (1)

91-103: Use shared helper for secret retrieval for consistency.

Prefer the existing maybe_get_secret helper to centralize secret fetch behavior and error mapping.

Apply:

-    let storage_secret: Option<StorageCredential> =
-        if let Some(secret_id) = warehouse.storage_secret_id {
-            Some(
-                state
-                    .v1_state
-                    .secrets
-                    .get_secret_by_id(secret_id)
-                    .await?
-                    .secret,
-            )
-        } else {
-            None
-        };
+    use crate::server::maybe_get_secret;
+    let storage_secret: Option<StorageCredential> =
+        maybe_get_secret(warehouse.storage_secret_id, &state.v1_state.secrets).await?;
crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (1)

95-98: Add active-warehouse filter in view load query (parity with tables).

To short-circuit inactive warehouses earlier and reduce work, add w.status = 'active' to the WHERE, mirroring table load.

 FROM view v
          INNER JOIN tabular ta ON ta.warehouse_id = $1 AND ta.tabular_id = v.view_id
-         INNER JOIN warehouse w ON w.warehouse_id = $1
+         INNER JOIN warehouse w ON w.warehouse_id = $1
 ...
-         WHERE v.warehouse_id = $1 AND v.view_id = $2 AND (ta.deleted_at is NULL OR $3)
+         WHERE v.warehouse_id = $1
+           AND v.view_id = $2
+           AND (ta.deleted_at is NULL OR $3)
+           AND w.status = 'active'

Also applies to: 147-152, 197-201, 407-408

docs/docs/api/management-open-api.yaml (2)

2956-2956: CreateWarehouseResponse as alias of GetWarehouseResponse

Good simplification. Consider documenting that id is deprecated and warehouse-id is the canonical field in the Create response, to guide client generators.


3474-3515: Dual id fields and updated-at: deprecation clarity

  • Requiring warehouse-id and keeping id (deprecated) preserves backward compatibility — good.
  • Suggest adding a note in the property description of id like “Deprecated alias of warehouse-id; will be removed in a future version” and marking both properties readOnly to aid client codegen.
  • Ensure all endpoints that reference GetWarehouseResponse actually include updated-at when available.
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (2)

33-37: Hard-coded TTL — make it configurable

Use a TTL from CONFIG (e.g., CONFIG.cache.warehouse.ttl_seconds) instead of 30s literal to align with ops knobs across environments.


85-87: Metric: prefer entry_count over weighted_size

If no custom weigher is set, weighted_size can be misleading. Use entry_count() to report number of entries. Example:

-    metrics::gauge!(METRIC_WAREHOUSE_CACHE_SIZE, "cache_type" => "warehouse")
-        .set(WAREHOUSE_CACHE.weighted_size() as f64);
+    metrics::gauge!(METRIC_WAREHOUSE_CACHE_SIZE, "cache_type" => "warehouse")
+        .set(WAREHOUSE_CACHE.entry_count() as f64);

Also consider a separate gauge for the name index size for observability parity.

crates/lakekeeper/src/implementations/postgres/warehouse.rs (1)

45-77: Return full row with RETURNING — LGTM (rename var)

Pattern is sound. Nit: row_count is a misnomer; consider renaming to warehouse_row for clarity.

crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (2)

391-413: Optional: avoid orphaned secret on failure

If authorizer call or DB commit fails after creating the secret, the new secret is orphaned. Consider deleting the created secret on error paths.

Apply this pattern:

-        transaction.commit().await?;
-
-        Ok(CreateWarehouseResponse(
-            (*resolved_warehouse).clone().into(),
-        ))
+        if let Err(e) = transaction.commit().await {
+            if let Some(secret_id) = secret_id {
+                let _ = context.v1_state.secrets.delete_secret(&secret_id).await;
+            }
+            return Err(e.into());
+        }
+        Ok(CreateWarehouseResponse((*resolved_warehouse).clone().into()))

705-711: Drop unnecessary Box::pin for readability

Calling .await on validate_access directly is clearer unless pinning is required by signature.

-        Box::pin(storage_profile.validate_access(
+        storage_profile.validate_access(
             storage_credential.as_ref(),
             None,
             &request_metadata,
-        ))
-        .await?;
+        )
+        .await?;
-        Box::pin(warehouse.storage_profile.validate_access(
+        warehouse.storage_profile.validate_access(
             new_storage_credential.as_ref(),
             None,
             &request_metadata,
-        ))
-        .await?;
+        )
+        .await?;

Also applies to: 787-793

crates/lakekeeper/src/service/catalog_store/warehouse.rs (1)

54-74: Consider documenting ResolvedWarehouse.updated_at semantics

Clarify whether updated_at changes on every mutation (rename/status/storage/protection/delete-profile). This enables correct use of get_warehouse_by_id_cache_aware.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c338372 and 3038fe2.

📒 Files selected for processing (24)
  • crates/lakekeeper/src/api/management/mod.rs (6 hunks)
  • crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (18 hunks)
  • crates/lakekeeper/src/config.rs (2 hunks)
  • crates/lakekeeper/src/implementations/postgres/catalog.rs (9 hunks)
  • crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs (5 hunks)
  • crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (4 hunks)
  • crates/lakekeeper/src/implementations/postgres/warehouse.rs (19 hunks)
  • crates/lakekeeper/src/server/config.rs (1 hunks)
  • crates/lakekeeper/src/server/namespace.rs (8 hunks)
  • crates/lakekeeper/src/server/s3_signer/sign.rs (2 hunks)
  • crates/lakekeeper/src/server/tables.rs (2 hunks)
  • crates/lakekeeper/src/server/tables/create_table.rs (1 hunks)
  • crates/lakekeeper/src/server/tables/load_table.rs (3 hunks)
  • crates/lakekeeper/src/server/views/commit.rs (1 hunks)
  • crates/lakekeeper/src/server/views/create.rs (3 hunks)
  • crates/lakekeeper/src/server/views/load.rs (2 hunks)
  • crates/lakekeeper/src/service/catalog_store.rs (7 hunks)
  • crates/lakekeeper/src/service/catalog_store/table.rs (2 hunks)
  • crates/lakekeeper/src/service/catalog_store/view.rs (1 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs (14 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (1 hunks)
  • crates/lakekeeper/src/tests/drop_warehouse.rs (4 hunks)
  • crates/lakekeeper/src/tests/mod.rs (2 hunks)
  • docs/docs/api/management-open-api.yaml (7 hunks)
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-09-18T20:08:00.663Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1254
File: .sqlx/query-552ddb89100de8fb3c374e95c885dfd2da32c9d51d30acf2d60811edbd545dbc.json:3-3
Timestamp: 2025-09-18T20:08:00.663Z
Learning: In the lakekeeper codebase, table_id and view_id are scoped by warehouse_id through composite primary keys (warehouse_id, table_id) and (warehouse_id, view_id). This design allows ID reuse across warehouses while preventing cross-warehouse joins through proper foreign key constraints. When reviewing SQL queries, JOIN conditions like `t.warehouse_id = $1 AND t.table_id = ti.tabular_id` are correct because they ensure warehouse scoping without needing additional `ti.warehouse_id = $1` constraints.

Applied to files:

  • crates/lakekeeper/src/server/tables/create_table.rs
📚 Learning: 2025-09-25T06:54:15.179Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1378
File: crates/lakekeeper/src/api/management/v1/warehouse/undrop.rs:51-53
Timestamp: 2025-09-25T06:54:15.179Z
Learning: In the lakekeeper codebase, when iterating over &[TabularId] and pattern matching TabularId::View(id), the id variable has type &ViewId. Using *id correctly dereferences to get ViewId, which can be passed directly to authorization methods that expect ViewId parameters.

Applied to files:

  • crates/lakekeeper/src/server/namespace.rs
🧬 Code graph analysis (16)
crates/lakekeeper/src/server/config.rs (1)
tests/python/tests/conftest.py (1)
  • warehouse (507-524)
crates/lakekeeper/src/server/tables.rs (1)
tests/python/tests/conftest.py (1)
  • warehouse (507-524)
crates/lakekeeper/src/service/catalog_store.rs (2)
crates/lakekeeper/src/implementations/postgres/catalog.rs (4)
  • get_warehouse_by_id_impl (445-450)
  • set_warehouse_status_impl (492-498)
  • update_storage_profile_impl (500-513)
  • set_warehouse_protected_impl (618-624)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (1)
  • Self (449-453)
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (3)
crates/lakekeeper/src/server/tables/create_table.rs (2)
  • new (42-50)
  • warehouse_id (69-71)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (4)
  • new (85-90)
  • new (114-119)
  • new (194-200)
  • new (225-230)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (1)
  • warehouse_id (154-156)
crates/lakekeeper/src/server/views/create.rs (2)
crates/lakekeeper/src/server/tables.rs (3)
  • request (810-814)
  • request (950-954)
  • request (1033-1104)
crates/lakekeeper/src/service/storage/mod.rs (1)
  • file_io (170-207)
crates/lakekeeper/src/tests/drop_warehouse.rs (1)
tests/python/tests/conftest.py (1)
  • warehouse (507-524)
crates/lakekeeper/src/server/tables/create_table.rs (1)
tests/python/tests/conftest.py (1)
  • warehouse (507-524)
crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs (1)
crates/lakekeeper/src/service/storage/mod.rs (1)
  • join_location (1006-1011)
crates/lakekeeper/src/server/namespace.rs (3)
tests/python/tests/conftest.py (1)
  • warehouse (507-524)
crates/lakekeeper/src/implementations/postgres/namespace.rs (1)
  • drop_namespace (372-537)
crates/lakekeeper/src/service/catalog_store/namespace.rs (1)
  • drop_namespace (409-416)
crates/lakekeeper/src/implementations/postgres/catalog.rs (4)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (3)
  • list_warehouses (415-462)
  • warehouse_id (154-156)
  • rename_warehouse (565-591)
crates/lakekeeper/src/implementations/postgres/warehouse.rs (2)
  • list_warehouses (306-345)
  • rename_warehouse (504-539)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (3)
  • list_warehouses (442-463)
  • Self (449-453)
  • rename_warehouse (431-439)
crates/lakekeeper/src/service/catalog_store.rs (3)
  • get_warehouse_by_id_impl (177-180)
  • transaction (82-82)
  • set_warehouse_deletion_profile_impl (198-202)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (4)
crates/lakekeeper/src/api/management/mod.rs (5)
  • create_warehouse (463-469)
  • rename_warehouse (802-810)
  • update_storage_profile (901-909)
  • update_storage_credential (926-939)
  • from (1566-1571)
crates/lakekeeper/src/implementations/postgres/warehouse.rs (3)
  • create_warehouse (79-149)
  • rename_warehouse (504-539)
  • update_storage_profile (613-654)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (6)
  • create_warehouse (399-418)
  • require_warehouse_by_id (536-543)
  • set_warehouse_protected (623-631)
  • rename_warehouse (431-439)
  • update_storage_profile (607-621)
  • Self (449-453)
tests/python/tests/conftest.py (2)
  • create_warehouse (326-353)
  • warehouse (507-524)
crates/lakekeeper/src/implementations/postgres/warehouse.rs (2)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (6)
  • from (1187-1199)
  • warehouse_id (154-156)
  • warehouses (443-446)
  • set_warehouse_protection (536-563)
  • create_warehouse (311-413)
  • list_warehouses (415-462)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (10)
  • new (85-90)
  • new (114-119)
  • new (194-200)
  • new (225-230)
  • Self (449-453)
  • get_warehouse_by_name (555-572)
  • set_warehouse_status (597-605)
  • update_storage_profile (607-621)
  • create_warehouse (399-418)
  • list_warehouses (442-463)
crates/lakekeeper/src/server/tables/load_table.rs (3)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (1)
  • require_warehouse_by_id_cache_aware (545-553)
crates/lakekeeper/src/server/tables.rs (1)
  • parse_location (1490-1500)
crates/lakekeeper/src/server/mod.rs (1)
  • maybe_get_secret (108-117)
crates/lakekeeper/src/server/views/load.rs (6)
crates/lakekeeper/src/service/catalog_store.rs (1)
  • begin_read (76-76)
crates/lakekeeper/src/implementations/postgres/mod.rs (1)
  • begin_read (79-93)
crates/lakekeeper/src/server/s3_signer/sign.rs (1)
  • state (195-198)
crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (1)
  • load_view (35-117)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (10)
  • require_warehouse_by_id_cache_aware (545-553)
  • from (95-103)
  • from (124-132)
  • from (143-148)
  • from (156-167)
  • from (205-213)
  • from (233-241)
  • from (263-271)
  • from (284-292)
  • from (295-303)
crates/lakekeeper/src/server/tables.rs (1)
  • require_active_warehouse (1502-1512)
crates/lakekeeper/src/tests/mod.rs (3)
crates/lakekeeper/src/api/management/mod.rs (1)
  • create_warehouse (463-469)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (1)
  • create_warehouse (311-413)
crates/lakekeeper/src/implementations/postgres/warehouse.rs (1)
  • create_warehouse (79-149)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (4)
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (3)
  • warehouse_cache_get_by_id (89-101)
  • warehouse_cache_get_by_name (103-125)
  • warehouse_cache_insert (69-78)
crates/lakekeeper/src/service/catalog_store.rs (11)
  • create_warehouse_impl (142-149)
  • transaction (82-82)
  • delete_warehouse_impl (152-156)
  • rename_warehouse_impl (159-163)
  • list_warehouses_impl (166-172)
  • get_warehouse_by_id_impl (177-180)
  • get_warehouse_by_name_impl (185-189)
  • set_warehouse_deletion_profile_impl (198-202)
  • set_warehouse_status_impl (205-209)
  • update_storage_profile_impl (211-216)
  • set_warehouse_protected_impl (218-222)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (4)
  • delete_warehouse (509-534)
  • warehouse_id (154-156)
  • rename_warehouse (565-591)
  • warehouses (443-446)
crates/lakekeeper/src/implementations/postgres/warehouse.rs (6)
  • delete_warehouse (449-502)
  • rename_warehouse (504-539)
  • get_warehouse_by_id (384-420)
  • get_warehouse_by_name (347-382)
  • set_warehouse_status (541-575)
  • update_storage_profile (613-654)
🪛 GitHub Check: check-generated-openapi-matches
crates/lakekeeper/src/implementations/postgres/warehouse.rs

[failure] 45-45:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 95-95:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 316-316:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 352-352:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 392-392:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 582-582:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 546-546:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 509-509:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache

🪛 GitHub Check: clippy
crates/lakekeeper/src/implementations/postgres/warehouse.rs

[failure] 45-45:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 95-95:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 316-316:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 352-352:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 392-392:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 582-582:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 546-546:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache


[failure] 509-509:
set DATABASE_URL to use query macros online, or run cargo sqlx prepare to update the query cache

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: test
  • GitHub Check: clippy
  • GitHub Check: sqlx-check
  • GitHub Check: openfga
🔇 Additional comments (41)
crates/lakekeeper/src/tests/mod.rs (1)

181-181: LGTM! Accessor method usage is correct and consistent.

The transition from direct field access to the .warehouse_id() accessor method is properly implemented and aligns with the PR's objective of returning richer warehouse objects with standardized field access patterns.

Also applies to: 186-186

crates/lakekeeper/src/server/s3_signer/sign.rs (2)

183-187: LGTM! Clone necessary to preserve warehouse for subsequent use.

The .clone() correctly prevents partial move of warehouse, allowing warehouse.storage_secret_id to be accessed at line 193.


231-262: LGTM! Clone necessary for type conversion.

The .clone() at line 237 correctly avoids partial move when calling try_into_s3(), which consumes the storage profile.

crates/lakekeeper/src/server/config.rs (1)

54-71: Good switch to explicit warehouse_id in auth and config.

Using warehouse.warehouse_id for AuthZ and CONFIG.warehouse_prefix is correct and consistent with the warehouse-centric model.

crates/lakekeeper/src/server/tables.rs (1)

253-261: LGTM on using warehouse.warehouse_id in TableCreation.

Keeps warehouse scoping explicit and consistent. Based on learnings.

crates/lakekeeper/src/server/views/commit.rs (1)

209-214: Correctly preserve warehouse_updated_at across view commit.

Propagation avoids dropping warehouse-level timestamp during commits.

crates/lakekeeper/src/server/tables/create_table.rs (1)

205-211: LGTM on TableCreation using warehouse.warehouse_id.

Consistent with the repo-wide warehouse_id surface. Based on learnings.

crates/lakekeeper/src/server/views/create.rs (1)

84-90: Consistent use of warehouse.storage_profile across create_view path.

Good cleanup aligning storage operations to the warehouse’s profile source of truth.

Also applies to: 96-101, 138-141, 158-169

crates/lakekeeper/src/tests/drop_warehouse.rs (1)

56-57: Tests updated to warehouse.warehouse_id(): looks good.

Matches the new accessor and keeps tests aligned with the public API.

Also applies to: 74-75, 98-99, 119-120

crates/lakekeeper/src/service/catalog_store/view.rs (1)

27-28: New field on CatalogView: verified ✓

Verification confirms all CatalogView struct literal initializations properly set warehouse_updated_at:

  • crates/lakekeeper/src/server/views/commit.rs (line 213)
  • crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (line 97)
crates/lakekeeper/src/server/views/load.rs (1)

76-87: Good freshness gating and active-warehouse check.

Using view.warehouse_updated_at to gate the cache and then require_active_warehouse is correct and race-safe.

crates/lakekeeper/src/api/management/mod.rs (1)

792-809: Endpoints now return GetWarehouseResponse — looks good.

Return types and OpenAPI docs are consistent for rename_warehouse, update_storage_profile, and update_storage_credential.

Also applies to: 891-909, 916-939

crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs (1)

118-150: Plumbing warehouse_updated_at and active gating are correct.

Joining warehouse for updated_at and filtering active status at SQL level aligns well with the new cache-aware flow, and the value is correctly propagated to LoadTableResponse.

Also applies to: 496-520, 651-656, 668-689

crates/lakekeeper/src/server/tables/load_table.rs (1)

60-85: Freshness-gated warehouse fetch and config generation look solid.

Good use of warehouse_updated_at to gate cache; secret retrieval via maybe_get_secret and subsequent generate_table_config usage are consistent.

Also applies to: 89-106

crates/lakekeeper/src/service/catalog_store.rs (1)

140-173: API surface shift verified—all implementations aligned with ResolvedWarehouse return types.

The warehouse trait methods now consistently return ResolvedWarehouse across create/rename/list/get/set-status/set-deletion-profile/update-storage-profile/set-protected operations. The postgres implementation confirms:

  • create_warehouse_impl, rename_warehouse_impl, set_warehouse_status_impl, set_warehouse_deletion_profile_impl, update_storage_profile_impl, and set_warehouse_protected_impl all return Result<ResolvedWarehouse, ...>
  • get_warehouse_by_id_impl and get_warehouse_by_name_impl return Result<Option<ResolvedWarehouse>, ...>
  • list_warehouses_impl returns Result<Vec<ResolvedWarehouse>, ...> and correctly accepts status_filter: Option<Vec<WarehouseStatus>>
  • No internal GetWarehouseResponse usage found in service/store layers

The implementation is coherent and trait-aligned across all warehouse management operations.

crates/lakekeeper/src/service/catalog_store/table.rs (1)

24-31: LoadTableResponse warehouse_updated_at field verified across all database implementations.

Verified that the postgres implementation (the only DB backend) correctly populates the warehouse_updated_at field at line 687 of crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs. The struct definition and its single constructor are both properly updated.

docs/docs/api/management-open-api.yaml (3)

1994-1997: Return type switch to GetWarehouseResponse — LGTM

Rename now returns the canonical warehouse payload. Ensure the handler actually serializes this shape and status code 200 across all paths.


2123-2126: Update storage now returns full warehouse — LGTM

Returning the updated warehouse object is consistent with the API surface. Verify server implementation aligns (status 200, schema fields).


2158-2161: Update storage-credential returns warehouse — LGTM

Matches the broader refactor; confirm server emits GetWarehouseResponse with updated_at populated when applicable.

crates/lakekeeper/src/server/namespace.rs (3)

421-425: Passing ResolvedWarehouse by reference

Good: avoids cloning and keeps API consistent across server layer.


498-577: Recursive drop semantics — OK; commit ordering is safe

  • Allowing recursive drop for Hard, or Soft with force, matches expected policy.
  • Committing before authorizer side-effects avoids partial catalog deletion with dangling tasks — good.
  • Minor: the comment “commit before starting the purge tasks” is accurate since tasks become visible post-commit; keep this invariant in task workers.

690-713: Namespace location handling — validate trailing slash invariant

The with_trailing_slash call ensures user-provided locations are normalized. Please confirm default_namespace_location also returns a trailing slash so the invariant holds regardless of input source.

crates/lakekeeper/src/implementations/postgres/warehouse.rs (11)

95-149: Create warehouse returns full record — LGTM

CTE to seed statistics and RETURNING mapped via WarehouseRecord is clean. Error mapping for uniqueness and fk violations looks correct.


269-304: WarehouseRecord → ResolvedWarehouse mapping — LGTM

TryFrom centralizes conversions and validates soft-delete seconds. Good cohesion.


314-345: list_warehouses columns include updated_at — LGTM

Defaults to active; supports explicit status filter. Good.


351-382: get_warehouse_by_name filters to active-only — confirm intent

By-name fetch restricts to status='active' while get_by_id does not. Is that deliberate? If clients expect to resolve inactive warehouses by name (e.g., for reactivation), consider parity or document the difference.


391-420: get_warehouse_by_id includes inactive — confirm consistency

See prior comment; align semantics or document.


508-539: rename_warehouse returns full row; active-only constraint

Renaming requires status='active'. If renaming inactive warehouses should be allowed (e.g., before reactivation), consider dropping the status predicate or enforcing policy at the API layer explicitly.


545-575: set_warehouse_status with RETURNING — LGTM

Straightforward, correct not-found mapping.


581-611: set_warehouse_protection with RETURNING — LGTM

Matches protection endpoint behavior and feeds updated_at to API.


618-654: update_storage_profile with RETURNING — LGTM

Properly handles null secret and returns full shape.


816-831: Tests updated to use warehouse_id — LGTM

Assertions match new ResolvedWarehouse shape.

Also applies to: 847-849, 919-919, 957-967


45-45: sqlx offline data is already present and validated by CI — review comment is incorrect

The .sqlx directory contains 117 query metadata files, and the unittests.yml CI workflow already runs cargo sqlx prepare --check --workspace automatically. No offline data is missing, and no action is required.

Likely an incorrect or invalid review comment.

crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (3)

150-157: CreateWarehouseResponse wrapper looks good

Transparent newtype + IntoResponse(201) preserves JSON shape while giving a typed accessor.


215-241: GetWarehouseResponse additions/deprecation are consistent

Keeping deprecated id alongside warehouse_id and adding updated_at maintains backward compatibility while enabling richer clients.


1186-1201: From mapping is correct

Both id and warehouse_id populated from the same source avoids breaking older clients.

crates/lakekeeper/src/implementations/postgres/catalog.rs (1)

108-115: Return-type refactor to ResolvedWarehouse looks consistent

Postgres layer now uniformly returns ResolvedWarehouse; mappings delegate cleanly to underlying queries/updates.

Also applies to: 369-387, 437-444, 445-451, 468-475, 476-483, 492-499, 500-513, 618-624

crates/lakekeeper/src/service/catalog_store/warehouse.rs (4)

449-463: Nice: warm caches on list_warehouses

Populating caches in bulk reduces early misses.


12-21: Error surface updates look appropriate

DatabaseIntegrityError added across error enums; messages and HTTP mapping remain consistent.

Also applies to: 171-181, 306-315, 318-325, 328-336, 338-346, 350-357, 360-368, 372-380, 383-391


1-22: Import set is fine

warehouse_cache::* imported where needed; keep it consistent after applying cache refresh diffs.


488-533: Verify caller usage pattern is intentional

The verification found 2 callers of require_warehouse_by_id_cache_aware (both in load operations with freshness timestamps) and ~17 callers of the non-cache-aware variant (in create/drop/modify operations). This pattern suggests cache-aware behavior is reserved for read operations requiring freshness guarantees, while mutations use the standard version. Confirm this matches your intended semantics.

Comment thread crates/lakekeeper/src/server/tables.rs Resolved
@c-thiel

c-thiel commented Oct 27, 2025

Copy link
Copy Markdown
Member Author

@CodeRabbit review

@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 6

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
crates/lakekeeper/src/implementations/postgres/secrets.rs (1)

118-126: Do not include serialized secrets in error stacks.

Even on serialization failure, pushing the secret (Debug) into logs risks leakage.

Apply this redaction:

-        let secret_str = serde_json::to_string(&secret).map_err(|_e| {
+        let secret_str = serde_json::to_string(&secret).map_err(|_e| {
             ErrorModel::builder()
                 .code(StatusCode::INTERNAL_SERVER_ERROR.into())
                 .message("Error serializing secret".to_string())
                 .r#type("SecretSerializeError".to_string())
-                // Redacted by veil
-                .stack(vec![format!("secret: {:?}", secret)])
+                .stack(vec!["secret: <redacted>".to_string()])
                 .build()
         })?;

If deeper diagnostics are needed, log only the type name via std::any::type_name::().

crates/lakekeeper/src/implementations/postgres/warehouse.rs (1)

384-420: get_warehouse_by_id should filter active warehouses

Trait docs state “Return only active warehouses. Return Ok(None) if … not active.” This query returns any status.

-        FROM warehouse
-        WHERE warehouse_id = $1
+        FROM warehouse
+        WHERE warehouse_id = $1
+        AND status = 'active'

Add/adjust a test to assert inactive warehouses are not returned by ID. Based on learnings.

crates/lakekeeper/src/implementations/postgres/catalog.rs (1)

648-653: Bug: passing &&id to record_success causes a type mismatch.

Use &id, not &&id.

-        record_success(&&id, transaction, message).await
+        record_success(&id, transaction, message).await
♻️ Duplicate comments (3)
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (2)

798-799: Use structured error logging with error=?e, not e.error

e.error may not exist for all error types; use error=?e for compatibility with tracing.

Apply this diff:

-                .map_err(|e| {
-                    tracing::warn!(error=?e.error, "Failed to delete old storage secret");
-                })
+                .map_err(|e| {
+                    tracing::warn!(error=?e, "Failed to delete old storage secret");
+                })

880-881: Same structured logging issue here

Use error=?e instead of e.error for tracing compatibility.

-                .map_err(|e| {
-                    tracing::warn!(error=?e.error, "Failed to delete old storage secret");
-                })
+                .map_err(|e| {
+                    tracing::warn!(error=?e, "Failed to delete old storage secret");
+                })
crates/lakekeeper/src/service/catalog_store/warehouse.rs (1)

406-418: Cache not refreshed after warehouse mutations (create/rename/status/delete-profile/storage/protected).

Mutations return updated payloads but don’t update caches, risking stale reads. Insert the updated warehouse into caches; for rename, also fix name→id mapping.

Apply these diffs:

@@
     ) -> Result<Arc<ResolvedWarehouse>, CatalogCreateWarehouseError> {
@@
-        .await?;
-        let warehouse_ref = Arc::new(warehouse);
-        Ok(warehouse_ref)
+        .await?;
+        let warehouse_ref = Arc::new(warehouse);
+        warehouse_cache_insert(warehouse_ref.clone()).await;
+        Ok(warehouse_ref)
@@
-    ) -> Result<Arc<ResolvedWarehouse>, CatalogRenameWarehouseError> {
-        Self::rename_warehouse_impl(warehouse_id, new_name, transaction)
-            .await
-            .map(Arc::new)
+    ) -> Result<Arc<ResolvedWarehouse>, CatalogRenameWarehouseError> {
+        let warehouse = Self::rename_warehouse_impl(warehouse_id, new_name, transaction).await?;
+        let warehouse = Arc::new(warehouse);
+        warehouse_cache_insert(warehouse.clone()).await;
+        Ok(warehouse)
@@
-    ) -> Result<Arc<ResolvedWarehouse>, SetWarehouseDeletionProfileError> {
-        Self::set_warehouse_deletion_profile_impl(warehouse_id, deletion_profile, transaction)
-            .await
-            .map(Arc::new)
+    ) -> Result<Arc<ResolvedWarehouse>, SetWarehouseDeletionProfileError> {
+        let warehouse =
+            Self::set_warehouse_deletion_profile_impl(warehouse_id, deletion_profile, transaction)
+                .await?;
+        let warehouse = Arc::new(warehouse);
+        warehouse_cache_insert(warehouse.clone()).await;
+        Ok(warehouse)
@@
-    ) -> Result<Arc<ResolvedWarehouse>, SetWarehouseStatusError> {
-        Self::set_warehouse_status_impl(warehouse_id, status, transaction)
-            .await
-            .map(Arc::new)
+    ) -> Result<Arc<ResolvedWarehouse>, SetWarehouseStatusError> {
+        let warehouse = Self::set_warehouse_status_impl(warehouse_id, status, transaction).await?;
+        let warehouse = Arc::new(warehouse);
+        warehouse_cache_insert(warehouse.clone()).await;
+        Ok(warehouse)
@@
-    ) -> Result<Arc<ResolvedWarehouse>, UpdateWarehouseStorageProfileError> {
+    ) -> Result<Arc<ResolvedWarehouse>, UpdateWarehouseStorageProfileError> {
         Self::update_storage_profile_impl(
             warehouse_id,
             storage_profile,
             storage_secret_id,
             transaction,
         )
-        .await
-        .map(Arc::new)
+        .await
+        .map(Arc::new)
+        .and_then(|w| async {
+            warehouse_cache_insert(w.clone()).await;
+            Ok::<_, UpdateWarehouseStorageProfileError>(w)
+        }.await)
@@
-    ) -> std::result::Result<Arc<ResolvedWarehouse>, SetWarehouseProtectedError> {
-        Self::set_warehouse_protected_impl(warehouse_id, protect, transaction)
-            .await
-            .map(Arc::new)
+    ) -> std::result::Result<Arc<ResolvedWarehouse>, SetWarehouseProtectedError> {
+        let warehouse = Self::set_warehouse_protected_impl(warehouse_id, protect, transaction).await?;
+        let warehouse = Arc::new(warehouse);
+        warehouse_cache_insert(warehouse.clone()).await;
+        Ok(warehouse)

Also ensure the rename path removes the old (project_id, old_name) mapping if warehouse_cache_insert doesn’t handle it internally. Based on learnings.

Also applies to: 435-439, 590-594, 600-604, 611-620, 626-630

🧹 Nitpick comments (9)
crates/lakekeeper/src/config.rs (1)

440-442: Warehouse cache config defaults look correct; consider guarding capacity

Defaults and serde wiring are solid. Consider clamping or validating capacity (>0 and reasonable upper bound) to avoid accidental unbounded memory growth if a bad env is set. A simple guard in get_config() or a NonZeroU64 newtype would work.

Also applies to: 460-474

crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (1)

150-157: Transparent wrapper is fine; add a Location header on 201 Created

Returning 201 with a transparent body preserves compatibility. Improve REST UX by setting Location to the created resource.

Apply this diff:

 impl axum::response::IntoResponse for CreateWarehouseResponse {
-    fn into_response(self) -> axum::http::Response<axum::body::Body> {
-        (http::StatusCode::CREATED, axum::Json(self)).into_response()
-    }
+    fn into_response(self) -> axum::http::Response<axum::body::Body> {
+        let mut res = (http::StatusCode::CREATED, axum::Json(self)).into_response();
+        let loc = format!("/api/management/v1/warehouses/{}", res
+            .extensions()
+            .get::<CreateWarehouseResponse>()
+            .map(|c| c.warehouse_id())
+            .unwrap_or_default());
+        if let Ok(hv) = http::HeaderValue::from_str(&loc) {
+            res.headers_mut().insert(http::header::LOCATION, hv);
+        }
+        res
+    }
 }

Or, simpler (no extensions), compute loc before building the response:

-    fn into_response(self) -> axum::http::Response<axum::body::Body> {
-        (http::StatusCode::CREATED, axum::Json(self)).into_response()
-    }
+    fn into_response(self) -> axum::http::Response<axum::body::Body> {
+        let loc = format!("/api/management/v1/warehouses/{}", self.warehouse_id());
+        let mut res = (http::StatusCode::CREATED, axum::Json(self)).into_response();
+        if let Ok(hv) = http::HeaderValue::from_str(&loc) {
+            res.headers_mut().insert(http::header::LOCATION, hv);
+        }
+        res
+    }

Also applies to: 260-264

crates/lakekeeper/src/service/endpoint_hooks.rs (1)

356-371: Unify hook error logs to structured fields for better grepability

All new dispatchers log string-formatted errors. Prefer structured logging with error=?e and useful context fields (e.g., %warehouse_id).

Example for create_warehouse:

-        futures::future::join_all(self.0.iter().map(|hook| {
-            hook.create_warehouse(warehouse.clone(), request_metadata.clone())
-                .map_err(|e| {
-                    tracing::warn!(
-                        "Hook '{}' encountered error on create_warehouse: {e:?}",
-                        hook.to_string()
-                    );
-                })
-        }))
+        futures::future::join_all(self.0.iter().map(|hook| {
+            let wid = warehouse.warehouse_id;
+            hook.create_warehouse(warehouse.clone(), request_metadata.clone())
+                .map_err(move |e| {
+                    tracing::warn!(error=?e, hook=%hook, %wid, "create_warehouse hook failed");
+                })
+        }))
         .await;

Apply the same pattern to the other new dispatcher methods.

Also applies to: 373-388, 390-410, 412-432, 434-454, 456-476, 478-500

crates/lakekeeper/src/lib.rs (1)

17-17: Public API rename: consider a deprecation alias and SemVer note.

Renaming SecretIdent -> SecretId is a breaking surface change. Provide a deprecated alias for one release cycle and note in changelog/release.

Suggested alias (in crate::service::secrets or a central prelude):

+#[deprecated(note = "Use `SecretId` instead. Will be removed in a future release.")]
+pub type SecretIdent = SecretId;

Also confirm this PR will bump version appropriately and include migration notes.

crates/lakekeeper/src/request_metadata.rs (1)

232-235: Doc typos (“configered”, header name)

  • “configered” → “configured”
  • “x-forward-proto” → “x-forwarded-proto”
-    /// Contains the value of `CONFIG.base_uri` if configered, else the
-    /// (`x-forward-proto`|https)://`x-forwarded-host`:`x-forwarded-port` headers if present,
+    /// Contains the value of `CONFIG.base_uri` if configured, else the
+    /// (`x-forwarded-proto`|https)://`x-forwarded-host`:`x-forwarded-port` headers if present,
crates/lakekeeper/src/service/secrets.rs (2)

14-27: Unify SecretId parameter passing style

Use by-value SecretId consistently (it’s Copy) for simpler APIs.

-    async fn delete_secret(&self, secret_id: &SecretId) -> Result<()>;
+    async fn delete_secret(&self, secret_id: SecretId) -> Result<()>;

Propagate to implementors accordingly.


35-47: into_uuid signature is non-idiomatic

Methods named “into_*” usually take self by value. Either:

  • rename to to_uuid(&self) -> uuid::Uuid, or
  • change to into_uuid(self) -> uuid::Uuid.
-    pub fn into_uuid(&self) -> uuid::Uuid {
-        self.0
-    }
+    pub fn into_uuid(self) -> uuid::Uuid {
+        self.0
+    }

Call sites using map(|id| id.into_uuid()) continue to work.

crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (2)

65-71: Optional safety: add TTL to NAME_TO_ID_CACHE

To bound any unforeseen staleness, align TTL with the primary.

 static NAME_TO_ID_CACHE: LazyLock<Cache<(ProjectId, String), WarehouseId>> = LazyLock::new(|| {
     Cache::builder()
         .max_capacity(CONFIG.cache.warehouse.capacity)
         .initial_capacity(50)
+        .time_to_live(Duration::from_secs(30))
         .build()
 });

135-157: Optional self‑healing on ID miss after name hit

If name→id resolves but id is missing in primary, consider invalidating the name index key to avoid repeated misses.

-    if let Some(value) = WAREHOUSE_CACHE.get(&(warehouse_id)).await {
+    if let Some(value) = WAREHOUSE_CACHE.get(&warehouse_id).await {
         tracing::debug!("Warehouse id {warehouse_id} found in cache");
         metrics::counter!(METRIC_WAREHOUSE_CACHE_HITS, "cache_type" => "warehouse").increment(1);
         Some(value.warehouse.clone())
     } else {
+        // Self-heal stale name index
+        NAME_TO_ID_CACHE
+            .invalidate(&(project_id.clone(), name.to_string()))
+            .await;
         metrics::counter!(METRIC_WAREHOUSE_CACHE_MISSES, "cache_type" => "warehouse").increment(1);
         None
     }
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3038fe2 and e7ff954.

⛔ Files ignored due to path filters (18)
  • .sqlx/query-0c5fd330500c57ef441233f175d55c9478cbdffc0f4cfb02a08e434ad76cc193.json is excluded by !.sqlx/**
  • .sqlx/query-18be9a25b054e4352bf6220e812ac301424384cf2281c044e857b1ab03a0155f.json is excluded by !.sqlx/**
  • .sqlx/query-1bb539d750ffce5afba4eda59bc333feaa881e49af91ab25fb919ccb5eb4cece.json is excluded by !.sqlx/**
  • .sqlx/query-1f121eedb80b741f03995969297e7c0b1e09c1038067c3e374337e01e2ac2617.json is excluded by !.sqlx/**
  • .sqlx/query-367fe5b576e1b20861a378a58b1fb1ee7ed5318cf0e22978486a33e9e4068193.json is excluded by !.sqlx/**
  • .sqlx/query-3aae86c6e5be244b7e43c7b67873a85badeb16c487cff08407130185a25a3b85.json is excluded by !.sqlx/**
  • .sqlx/query-3c443998f727f1f828612fbf5c6e597fac5f0561620ac425ad5be054a3d014f6.json is excluded by !.sqlx/**
  • .sqlx/query-40afad12aa65637bdf8573fc11a5a5d469bb5262cb91c67f1912c7ef3424fad7.json is excluded by !.sqlx/**
  • .sqlx/query-55a50e2a054917b1c1a69d68cd60bf4cf8dfa63ae2530aec8229d9d7c5cd0133.json is excluded by !.sqlx/**
  • .sqlx/query-59390d0a195d73b00806fe41b7457990953577590403aca0fc6bee8f32c2e3a4.json is excluded by !.sqlx/**
  • .sqlx/query-7268056f45996f6a99106a57fa5bf8b6b9a127d5b004683e20d3a1a57387676b.json is excluded by !.sqlx/**
  • .sqlx/query-82807345c242ae4af03f9b1ad7b51bef5afe3c55400e24eb8a62524eead434cd.json is excluded by !.sqlx/**
  • .sqlx/query-99f921a6cf11d3d3019c61d90ebae80e90667d8744dfbeed95982146887dec38.json is excluded by !.sqlx/**
  • .sqlx/query-aae863fa1f0814b2c173f64c86c37c24580e517666212c3c4aa3924bd34d43ea.json is excluded by !.sqlx/**
  • .sqlx/query-aaecbcd318c2f08d0d2065eb8762dd75e45f1260eacdcf4e8b4b31bcffd4c223.json is excluded by !.sqlx/**
  • .sqlx/query-b4b8233e3f73f20d198cbc92622dbcf5468f9e9cc51c37676c719ae29b63b8ac.json is excluded by !.sqlx/**
  • .sqlx/query-bf0985cd760ff026ab3375c84bd1c946a0b6f2b9f71fc74a4cffd7d2c482137b.json is excluded by !.sqlx/**
  • .sqlx/query-ca442849c981769299d8929126778eaa97d68c823a998ae40afa920017f7cb79.json is excluded by !.sqlx/**
📒 Files selected for processing (19)
  • crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (23 hunks)
  • crates/lakekeeper/src/config.rs (3 hunks)
  • crates/lakekeeper/src/implementations/kv2.rs (5 hunks)
  • crates/lakekeeper/src/implementations/mod.rs (3 hunks)
  • crates/lakekeeper/src/implementations/postgres/catalog.rs (8 hunks)
  • crates/lakekeeper/src/implementations/postgres/secrets.rs (4 hunks)
  • crates/lakekeeper/src/implementations/postgres/warehouse.rs (19 hunks)
  • crates/lakekeeper/src/lib.rs (1 hunks)
  • crates/lakekeeper/src/request_metadata.rs (3 hunks)
  • crates/lakekeeper/src/serve.rs (1 hunks)
  • crates/lakekeeper/src/server/mod.rs (1 hunks)
  • crates/lakekeeper/src/server/tables.rs (2 hunks)
  • crates/lakekeeper/src/server/views/commit.rs (3 hunks)
  • crates/lakekeeper/src/service/catalog_store.rs (7 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs (13 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (1 hunks)
  • crates/lakekeeper/src/service/endpoint_hooks.rs (3 hunks)
  • crates/lakekeeper/src/service/mod.rs (1 hunks)
  • crates/lakekeeper/src/service/secrets.rs (2 hunks)
✅ Files skipped from review due to trivial changes (1)
  • crates/lakekeeper/src/implementations/kv2.rs
🚧 Files skipped from review as they are similar to previous changes (1)
  • crates/lakekeeper/src/server/tables.rs
🧰 Additional context used
🪛 GitHub Check: check-format
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs

[warning] 20-20:
Diff in /home/runner/work/lakekeeper/lakekeeper/crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs


[warning] 6-6:
Diff in /home/runner/work/lakekeeper/lakekeeper/crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: test
  • GitHub Check: check-generated-openapi-matches
  • GitHub Check: clippy
  • GitHub Check: sqlx-check
🔇 Additional comments (24)
crates/lakekeeper/src/config.rs (1)

1125-1149: Tests cover defaults and env overrides

Good coverage for enabled/capacity and env mapping; no issues.

crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (4)

385-413: Create path conversion and hooks sequence LGTM

Create -> authorize -> commit -> emit hooks -> map to response is clean and consistent.


735-756: Storage update flow looks correct; good use of update_with and hooks

Normalization/validation precede persistence; hooks receive both request and updated warehouse. All good.

Also applies to: 770-789


1239-1253: From mapping is correct

id and warehouse_id are aligned and updated_at is forwarded. Looks good.


215-241: No additional changes needed; deprecation is already properly marked

The review comment's suggestion is already implemented. The #[deprecated] attribute currently on the id field marks it as deprecated in both the Rust code and the generated OpenAPI schema. Per the web search results, Rust's built-in #[deprecated] automatically handles OpenAPI schema deprecation when using utoipa, so no additional #[schema(deprecated)] attribute is required.

crates/lakekeeper/src/service/endpoint_hooks.rs (1)

635-695: Default no-op implementations keep backward compatibility

Trait expansion is safe; implementors won’t break. Good.

crates/lakekeeper/src/server/mod.rs (1)

109-117: SecretId migration looks correct

Signature/type change aligns with SecretId refactor; behavior unchanged.

crates/lakekeeper/src/server/views/commit.rs (3)

33-34: Import alignment looks good.

Importing SecretId here matches the updated storage_secret_id type.


213-214: Good: preserve warehouse_updated_at across commit.

Carrying warehouse_updated_at forward helps cache validators remain stable.

Ensure CatalogView.warehouse_updated_at is included wherever views are serialized or cached so clients see consistent values.


154-156: No issues found—the review comment is based on an incorrect premise.

SecretId derives Copy (along with Clone, Debug, etc.), making Option also Copy. When the code executes if let Some(secret_id) = ctx.storage_secret_id at line 229, the value is copied, not moved. Consequently, ctx remains fully accessible afterward—as evidenced by the subsequent field accesses at lines 242 and 256 (ctx.storage_profile).

The suggested refactoring using as_ref().clone() is unnecessary and contradicts the intended semantics of Copy types.

Likely an incorrect or invalid review comment.

crates/lakekeeper/src/implementations/postgres/secrets.rs (1)

51-58: Postgres SecretStore now uses SecretId — consistent with trait.

Parameter/return type updates are coherent; SQL bindings already use secret_id.as_uuid().

Run tests for both backends to ensure parity (KV2 and Postgres).

Also applies to: 114-118, 152-153

crates/lakekeeper/src/implementations/mod.rs (1)

75-107: SecretStore API fully aligned across all implementations — verification complete.

All three method signatures (get_secret_by_id, create_secret, delete_secret) are consistent across the enum wrapper and both backends (KV2 and Postgres). SecretId is used uniformly; no stray SecretIdent references remain in the codebase. Delegations in the enum match statement properly route to both backends.

crates/lakekeeper/src/service/mod.rs (1)

18-18: Review comment is incorrect and should be disregarded.

The suggestion assumes a SecretIdent → SecretId rename occurred, but this type never existed in the codebase. Exhaustive searches show zero occurrences of SecretIdent anywhere. The actual change in commit 8fec31f involved renaming TabularDetails.ident to TabularDetails.table_id, not SecretId. The current re-export at line 18 (pub use secrets::{SecretId, SecretStore};) is already correct and requires no deprecated alias.

Likely an incorrect or invalid review comment.

crates/lakekeeper/src/request_metadata.rs (2)

51-71: Structured error type and conversions: good change

Clearer propagation via From → ErrorModel/IcebergErrorResponse. Enables ergonomic use with ?. LGTM.


221-228: All call sites are correctly handled by existing From implementations.

The Result type alias in crates/lakekeeper/src/api/mod.rs defaults error type to IcebergErrorResponse. Since ProjectIdMissing has From implementations for both ErrorModel and IcebergErrorResponse, the ? operator automatically coerces ProjectIdMissing to the expected error type at all 10 call sites across config.rs, warehouse/mod.rs, role.rs, and project.rs.

No additional map_err handling or changes to call sites are needed.

crates/lakekeeper/src/service/secrets.rs (1)

49-66: Conversions and Display: LGTM

From/Intouuid::Uuid and Display are correct and sufficient for DB and logs.

crates/lakekeeper/src/implementations/postgres/warehouse.rs (3)

269-305: Row mapper and TryFrom: LGTM

Centralizing DB→API mapping via WarehouseRecord is clean and reduces duplication.


95-149: Create path returning full ResolvedWarehouse: LGTM

RETURNING shape matches mapper; error handling correctly maps FK and unique constraint cases.


541-575: Verified: Callers confirm expected behavior

Call site verification shows the function is used as a general-purpose status setter with callers explicitly setting WarehouseStatus::Inactive and WarehouseStatus::Active without state transition guards. This confirms the behavior of allowing any status update is intentional and expected.

crates/lakekeeper/src/service/catalog_store.rs (2)

48-49: Module addition for warehouse cache: LGTM

Scoped as pub(crate); good boundary.


140-150: SecretId and ResolvedWarehouse surfaces: LGTM

Public signatures consistently use SecretId and return full ResolvedWarehouse.

crates/lakekeeper/src/implementations/postgres/catalog.rs (1)

369-386: API migration to ResolvedWarehouse looks consistent.

Signatures and return types align across create/get/list/rename/status/storage/protection paths. Good consolidation around ResolvedWarehouse and SecretId.

Also applies to: 437-443, 446-450, 468-474, 476-482, 492-498, 500-513, 618-624

crates/lakekeeper/src/service/catalog_store/warehouse.rs (2)

488-532: Cache-aware getter logic looks sound.

Timestamp comparison handles None/Some cases correctly; fresh fetch updates cache. Nice.


421-428: Cache eviction is already implemented at the appropriate layer.

The review assumes cache eviction is missing from warehouse.rs, but it's actually handled correctly in the warehouse_cache.rs EndpointHook layer. When a warehouse is deleted via the API, the flow is: (1) core deletion via C::delete_warehouse (warehouse.rs), (2) transaction commit, then (3) hooks.delete_warehouse() is called, which invokes warehouse_cache_invalidate(). This function properly invalidates the warehouse cache by ID, with the eviction listener automatically handling the name-to-ID cache cleanup. Adding cache eviction to the store layer would violate separation of concerns and create architectural duplication—infrastructure concerns (caching) should remain in the hook layer, not bleed into business logic.

Likely an incorrect or invalid review comment.

Comment thread crates/lakekeeper/src/serve.rs Resolved
@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor
✅ Actions performed

Comments resolved and changes approved.

1 similar comment
@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor
✅ Actions performed

Comments resolved and changes approved.

coderabbitai[bot]
coderabbitai Bot previously approved these changes Oct 27, 2025
@c-thiel

c-thiel commented Oct 27, 2025

Copy link
Copy Markdown
Member Author

@CodeRabbit full-review.
Close comments if solved.

@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor

@c-thiel: I'll perform a full review of all the changes in this PR and resolve the existing comments as requested.

✅ Actions performed

Comments resolved and changes approved.


Full review triggered.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
crates/lakekeeper/src/server/views/commit.rs (1)

258-269: Likely wrong scope for credentials: use view location, not metadata file path.

generate_table_config should receive the view root (new_view.location), matching create.rs. Passing metadata_location may over-restrict credentials.

Apply this fix:

-        .generate_table_config(
+        .generate_table_config(
             ctx.data_access,
             storage_secret.as_ref(),
-            &new_view.metadata_location,
+            &new_view.location,
             StoragePermissions::ReadWriteDelete,
             request_metadata,
             ctx.view_info.warehouse_id,
             ctx.view_info.tabular_id.into(),
         )
♻️ Duplicate comments (3)
crates/lakekeeper/src/serve.rs (1)

365-372: Fix hook path; include capacity in log

The module path should be under service::catalog_store. Also, include capacity in the enabled log for quick visibility.

Apply:

-    if CONFIG.cache.warehouse.enabled {
-        tracing::info!("Warehouse cache is enabled, registering warehouse cache endpoint hook");
-        hooks.append(Arc::new(
-            crate::service::warehouse_cache::WarehouseCacheEndpointHook {},
-        ));
-    } else {
+    if CONFIG.cache.warehouse.enabled {
+        tracing::info!(
+            "Warehouse cache enabled (capacity={})",
+            CONFIG.cache.warehouse.capacity
+        );
+        hooks.append(Arc::new(
+            crate::service::catalog_store::warehouse_cache::WarehouseCacheEndpointHook {},
+        ));
+    } else {
         tracing::info!("Warehouse cache is disabled");
     }
#!/bin/bash
# Verify the hook type and its impl location
rg -nP 'struct\s+WarehouseCacheEndpointHook\b' -C2
rg -nP 'impl\s+.*EndpointHook\s+for\s+.*WarehouseCacheEndpointHook' -C2
rg -nP 'mod\s+warehouse_cache|pub\s+mod\s+warehouse_cache' -n
crates/lakekeeper/src/server/tables.rs (1)

1080-1091: Location allowlist check on commit — resolved.

require_allowed_location for changed table locations is now enforced before deriving metadata paths. This closes the earlier security gap.

crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (1)

803-806: Log the whole error (error=?e), not e.error; and avoid leaking internals.

Switch to structured logging with error=?e. You’ve already removed raw secret IDs—good.

-                .map_err(|e| {
-                    tracing::warn!(error=?e.error, "Failed to delete old storage secret");
-                })
+                .map_err(|e| {
+                    tracing::warn!(error=?e, "Failed to delete old storage secret");
+                })
                 .ok();

Apply in both places.

Also applies to: 885-888

🧹 Nitpick comments (18)
docs/docs/api/management-open-api.yaml (1)

3474-3515: Deprecation semantics and examples

  • id is deprecated but still required. Consider keeping the field present in responses but removing it from required, and add “Deprecated: use warehouse-id” to its description to guide clients. Keeps compatibility while nudging migration.
  • Add a short deprecation note at the GetWarehouseResponse description level if you want to make this more visible.
  • The examples in the endpoint-statistics description use updated_at (underscore) while the schema defines updated-at (hyphen). Align the example key to updated-at to prevent confusion.
crates/lakekeeper/src/service/endpoint_hooks.rs (1)

356-371: Hook dispatch for warehouse lifecycle is correct; consider DRYing logging

Dispatch pattern and error logging mirror existing hooks. Consider extracting a small helper like run_hooks("create_warehouse", |h| h.create_warehouse(...)) to reduce repetition and keep messages uniform.

Also applies to: 373-388, 390-410, 412-432, 434-454, 456-476, 478-500

crates/lakekeeper/src/implementations/mod.rs (1)

77-85: Standardize SecretId parameter passing to by-value for consistency

SecretId is a Copy type (derives Copy), so get_secret_by_id and delete_secret should both pass it by value. Currently get_secret_by_id takes SecretId by value while delete_secret takes &SecretId by reference, which is non-idiomatic for Copy types. Update delete_secret signature and call sites (lines 101, 104–105 in mod.rs; 152 in postgres/secrets.rs; 101 in kv2.rs; 26 in service/secrets.rs) to pass by value.

crates/lakekeeper/src/server/views/create.rs (1)

88-89: Consistent use of warehouse.storage_profile — good; consider deferring secret fetch.

Logic is correct. Minor: you can avoid fetching storage_secret when not needed (e.g., remote-signing path) by deferring file_io/config generation until it’s confirmed required.

Confirm determine_tabular_location enforces allowed-location checks for view roots (parity with table create/commit). If not, add storage_profile.require_allowed_location(view_location) before writing metadata.

Also applies to: 96-101, 138-142, 158-160

crates/lakekeeper/src/server/views/commit.rs (1)

228-240: Optional: reuse maybe_get_secret for consistency.

Inline secret fetch duplicates maybe_get_secret logic used elsewhere. Consider:

-    let storage_secret = if let Some(secret_id) = ctx.storage_secret_id {
-        Some(state.v1_state.secrets.get_secret_by_id(secret_id).await?.secret)
-    } else { None };
+    let storage_secret = crate::server::maybe_get_secret(ctx.storage_secret_id, &state.v1_state.secrets).await?;
crates/lakekeeper/src/config.rs (2)

460-474: Consider guarding capacity=0 and documenting bounds

Using u64 allows 0 via env. If 0 is invalid, enforce NonZeroU64 or validate on load; also add a brief doc comment on units/expected range.


1125-1149: Add negative/edge-case tests for robustness

Great coverage for defaults and overrides. Consider adding:

  • capacity=0 → expect rejection or well-defined behavior
  • invalid values (e.g., "not-a-number") → expect config extraction failure

If capacity=0 should be rejected, I can add a small validation pass in get_config() that errors early.

crates/lakekeeper/src/tests/drop_warehouse.rs (1)

56-56: Accessor migration LGTM; micro‑nit to avoid repeats

Switch to warehouse_id() is correct. Optionally hoist it once:

  • let wh = warehouse.warehouse_id();
  • let prefix = Some(Prefix(wh.to_string()));
  • reuse wh where needed.

Also applies to: 74-74, 98-98, 119-119

crates/lakekeeper/src/server/views/load.rs (1)

91-104: Tighten secret fetch with map/transpose

Equivalent, shorter, and keeps error context:

-    let storage_secret: Option<StorageCredential> =
-        if let Some(secret_id) = warehouse.storage_secret_id {
-            Some(
-                state
-                    .v1_state
-                    .secrets
-                    .get_secret_by_id(secret_id)
-                    .await?
-                    .secret,
-            )
-        } else {
-            None
-        };
+    let storage_secret: Option<StorageCredential> = warehouse
+        .storage_secret_id
+        .map(|id| state.v1_state.secrets.get_secret_by_id(id))
+        .transpose()
+        .map(|s| s.map(|s| s.secret))?;
crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (1)

63-64: Plumbing warehouse_updated_at through to CatalogView is correct; ensure consumers handle None

CatalogView { warehouse_updated_at, … } is fine. Make sure callers (e.g., cache policy selection) explicitly handle None.

Also applies to: 91-98

crates/lakekeeper/src/implementations/kv2.rs (2)

101-115: Signature asymmetry (by‑value vs by‑ref) is acceptable but consider consistency

get_secret_by_id takes SecretId by value, delete_secret takes &SecretId. If the trait allows, align both (either by value or by ref) for consistency. Not blocking.


251-253: Rename helper for consistency: secret_ident_to_key → secret_id_to_key

The function parameter is secret_id, so renaming to secret_id_to_key improves consistency. Apply locally:

-fn secret_ident_to_key(secret_id: SecretId) -> String {
+fn secret_id_to_key(secret_id: SecretId) -> String {
     format!("secret/{secret_id}", secret_id = secret_id.as_uuid())
 }

Update call sites (lines 33, 49, 86, 105) to secret_id_to_key.

crates/lakekeeper/src/service/secrets.rs (1)

35-47: Name the helper for by-ref conversion to_uuid (keep existing for BC).

into_uuid(&self) reads as by-value; add a clear by-ref helper.

 impl SecretId {
     #[must_use]
     #[inline]
-    pub fn into_uuid(&self) -> uuid::Uuid {
+    pub fn into_uuid(&self) -> uuid::Uuid {
         self.0
     }
+
+    #[must_use]
+    #[inline]
+    pub fn to_uuid(&self) -> uuid::Uuid {
+        self.0
+    }
 }
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (2)

48-49: Use configurable TTL instead of hardcoded 30s.

If CONFIG exposes a TTL, prefer it for flexibility.

-        .time_to_live(Duration::from_secs(30))
+        .time_to_live(Duration::from_secs(CONFIG.cache.warehouse.ttl_secs))

49-75: Update size gauge on eviction to keep metrics fresh.

Optional but helpful; call update_cache_size_metric() at the end of the listener.

         .async_eviction_listener(|key, value: CachedWarehouse, cause| {
             Box::pin(async move {
                 // ...
                 if should_invalidate {
                     NAME_TO_ID_CACHE
                         .invalidate(&(
                             value.warehouse.project_id.clone(),
                             value.warehouse.name.clone(),
                         ))
                         .await;
                 }
+                update_cache_size_metric();
             })
         })
crates/lakekeeper/src/server/tables/load_table.rs (1)

79-85: Defer warehouse fetch to avoid unnecessary lookups when storage_permissions is absent.

The warehouse object is only used inside the if let Some(storage_permissions) block (lines 88–105), so the fetch can be deferred. Verified that CachePolicy::OnlyIfNewerThan(warehouse_last_updated_at) correctly handles both Some and None variants—the implementation checks cache validity even when None (warehouse.rs:533), contrary to the documented comment claiming it skips cache. Moving the fetch inside the conditional eliminates the lookup entirely when unused.

 t.commit().await?;
-
-let warehouse = C::require_warehouse_by_id_cache_aware(
-    warehouse_id,
-    CachePolicy::OnlyIfNewerThan(warehouse_last_updated_at),
-    catalog_state.clone(),
-)
-.await?;
-
 let table_location =
     parse_location(table_metadata.location(), StatusCode::INTERNAL_SERVER_ERROR)?;
 
-let storage_config = if let Some(storage_permissions) = storage_permissions {
-    let storage_secret =
-        maybe_get_secret(warehouse.storage_secret_id, &state.v1_state.secrets).await?;
+let storage_config = if let Some(storage_permissions) = storage_permissions {
+    let warehouse = C::require_warehouse_by_id_cache_aware(
+        warehouse_id,
+        CachePolicy::OnlyIfNewerThan(warehouse_last_updated_at),
+        catalog_state.clone(),
+    )
+    .await?;
+    let storage_secret =
+        maybe_get_secret(warehouse.storage_secret_id, &state.v1_state.secrets).await?;
     Some(
         warehouse
             .storage_profile
crates/lakekeeper/src/implementations/postgres/warehouse.rs (1)

243-261: Use sqlx::query! for DML; query_scalar! is for SELECTs.

query_scalar! on a DELETE is misleading and may break offline checks. Prefer query! with execute().

-    let row_count = sqlx::query_scalar!(r#"DELETE FROM project WHERE project_id = $1"#, project_id)
+    let row_count = sqlx::query!(r#"DELETE FROM project WHERE project_id = $1"#, project_id)
         .execute(&mut **transaction)
         .await
         .map_err(|e| match &e {
crates/lakekeeper/src/service/catalog_store/warehouse.rs (1)

454-461: Rename param for clarity.

include_inactive: Option<Vec<WarehouseStatus>> now conveys arbitrary status filters. Consider status_filter or include_status for accuracy.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c338372 and 5768098.

⛔ Files ignored due to path filters (18)
  • .sqlx/query-0c5fd330500c57ef441233f175d55c9478cbdffc0f4cfb02a08e434ad76cc193.json is excluded by !.sqlx/**
  • .sqlx/query-1bb539d750ffce5afba4eda59bc333feaa881e49af91ab25fb919ccb5eb4cece.json is excluded by !.sqlx/**
  • .sqlx/query-1f121eedb80b741f03995969297e7c0b1e09c1038067c3e374337e01e2ac2617.json is excluded by !.sqlx/**
  • .sqlx/query-367fe5b576e1b20861a378a58b1fb1ee7ed5318cf0e22978486a33e9e4068193.json is excluded by !.sqlx/**
  • .sqlx/query-3aae86c6e5be244b7e43c7b67873a85badeb16c487cff08407130185a25a3b85.json is excluded by !.sqlx/**
  • .sqlx/query-3c443998f727f1f828612fbf5c6e597fac5f0561620ac425ad5be054a3d014f6.json is excluded by !.sqlx/**
  • .sqlx/query-40afad12aa65637bdf8573fc11a5a5d469bb5262cb91c67f1912c7ef3424fad7.json is excluded by !.sqlx/**
  • .sqlx/query-55a50e2a054917b1c1a69d68cd60bf4cf8dfa63ae2530aec8229d9d7c5cd0133.json is excluded by !.sqlx/**
  • .sqlx/query-59390d0a195d73b00806fe41b7457990953577590403aca0fc6bee8f32c2e3a4.json is excluded by !.sqlx/**
  • .sqlx/query-7268056f45996f6a99106a57fa5bf8b6b9a127d5b004683e20d3a1a57387676b.json is excluded by !.sqlx/**
  • .sqlx/query-72b7a1be5ece8e204c0c5d762cbbd1c59ff675d96f67f60e9f3c443c070b504e.json is excluded by !.sqlx/**
  • .sqlx/query-82807345c242ae4af03f9b1ad7b51bef5afe3c55400e24eb8a62524eead434cd.json is excluded by !.sqlx/**
  • .sqlx/query-99f921a6cf11d3d3019c61d90ebae80e90667d8744dfbeed95982146887dec38.json is excluded by !.sqlx/**
  • .sqlx/query-aae863fa1f0814b2c173f64c86c37c24580e517666212c3c4aa3924bd34d43ea.json is excluded by !.sqlx/**
  • .sqlx/query-aaecbcd318c2f08d0d2065eb8762dd75e45f1260eacdcf4e8b4b31bcffd4c223.json is excluded by !.sqlx/**
  • .sqlx/query-b4b8233e3f73f20d198cbc92622dbcf5468f9e9cc51c37676c719ae29b63b8ac.json is excluded by !.sqlx/**
  • .sqlx/query-bf0985cd760ff026ab3375c84bd1c946a0b6f2b9f71fc74a4cffd7d2c482137b.json is excluded by !.sqlx/**
  • .sqlx/query-ca442849c981769299d8929126778eaa97d68c823a998ae40afa920017f7cb79.json is excluded by !.sqlx/**
📒 Files selected for processing (36)
  • crates/lakekeeper/src/api/management/mod.rs (6 hunks)
  • crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (23 hunks)
  • crates/lakekeeper/src/config.rs (3 hunks)
  • crates/lakekeeper/src/implementations/kv2.rs (5 hunks)
  • crates/lakekeeper/src/implementations/mod.rs (3 hunks)
  • crates/lakekeeper/src/implementations/postgres/catalog.rs (8 hunks)
  • crates/lakekeeper/src/implementations/postgres/secrets.rs (4 hunks)
  • crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs (5 hunks)
  • crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (4 hunks)
  • crates/lakekeeper/src/implementations/postgres/warehouse.rs (19 hunks)
  • crates/lakekeeper/src/lib.rs (1 hunks)
  • crates/lakekeeper/src/request_metadata.rs (3 hunks)
  • crates/lakekeeper/src/serve.rs (1 hunks)
  • crates/lakekeeper/src/server/config.rs (1 hunks)
  • crates/lakekeeper/src/server/mod.rs (1 hunks)
  • crates/lakekeeper/src/server/namespace.rs (8 hunks)
  • crates/lakekeeper/src/server/s3_signer/sign.rs (2 hunks)
  • crates/lakekeeper/src/server/tables.rs (2 hunks)
  • crates/lakekeeper/src/server/tables/create_table.rs (1 hunks)
  • crates/lakekeeper/src/server/tables/load_table.rs (3 hunks)
  • crates/lakekeeper/src/server/views/commit.rs (3 hunks)
  • crates/lakekeeper/src/server/views/create.rs (3 hunks)
  • crates/lakekeeper/src/server/views/load.rs (2 hunks)
  • crates/lakekeeper/src/service/catalog_store.rs (7 hunks)
  • crates/lakekeeper/src/service/catalog_store/table.rs (2 hunks)
  • crates/lakekeeper/src/service/catalog_store/view.rs (1 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs (12 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (1 hunks)
  • crates/lakekeeper/src/service/endpoint_hooks.rs (3 hunks)
  • crates/lakekeeper/src/service/mod.rs (1 hunks)
  • crates/lakekeeper/src/service/secrets.rs (2 hunks)
  • crates/lakekeeper/src/service/storage/cache.rs (1 hunks)
  • crates/lakekeeper/src/tests/drop_warehouse.rs (4 hunks)
  • crates/lakekeeper/src/tests/mod.rs (2 hunks)
  • docs/docs/api/management-open-api.yaml (7 hunks)
  • docs/docs/configuration.md (1 hunks)
🧰 Additional context used
🧠 Learnings (3)
📚 Learning: 2025-08-22T05:44:22.632Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1298
File: crates/lakekeeper/src/service/secrets.rs:11-11
Timestamp: 2025-08-22T05:44:22.632Z
Learning: In crates/lakekeeper/src/implementations/kv2.rs, the SecretsState struct has a manual `impl std::fmt::Debug` implementation (lines 239-249) that properly redacts sensitive fields like vault_password (shows "REDACTED") and replaces complex objects like vault_client with simple string representations. This is the correct approach for Debug implementations on secret-handling types.

Applied to files:

  • crates/lakekeeper/src/implementations/kv2.rs
📚 Learning: 2025-09-25T06:54:15.179Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1378
File: crates/lakekeeper/src/api/management/v1/warehouse/undrop.rs:51-53
Timestamp: 2025-09-25T06:54:15.179Z
Learning: In the lakekeeper codebase, when iterating over &[TabularId] and pattern matching TabularId::View(id), the id variable has type &ViewId. Using *id correctly dereferences to get ViewId, which can be passed directly to authorization methods that expect ViewId parameters.

Applied to files:

  • crates/lakekeeper/src/server/namespace.rs
📚 Learning: 2025-10-27T11:26:34.813Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1462
File: crates/lakekeeper/src/service/catalog_store/warehouse.rs:418-430
Timestamp: 2025-10-27T11:26:34.813Z
Learning: In the lakekeeper codebase, cache invalidation for warehouse mutations (create, rename, status updates, storage updates, etc.) is handled through endpoint hooks that run after transaction commits, not within the transaction methods themselves. The WarehouseCacheEndpointHook is responsible for updating the warehouse cache.

Applied to files:

  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: docker / docker
  • GitHub Check: test
  • GitHub Check: check-generated-openapi-matches
  • GitHub Check: clippy
  • GitHub Check: sqlx-check
🔇 Additional comments (40)
crates/lakekeeper/src/service/storage/cache.rs (1)

131-131: Aligns implementation with documented behavior—change is correct.

The metric was already documented in docs/docs/configuration.md:276 as "Current number of entries in the cache." The change from weighted_size() to entry_count() corrects an inconsistency where the implementation didn't match its documented behavior and the metric description in the code. This is a bug fix that brings the implementation into alignment.

crates/lakekeeper/src/server/s3_signer/sign.rs (2)

183-187: LGTM! Clone prevents partial move of warehouse struct.

The clone is necessary because warehouse is accessed again on line 193 to retrieve storage_secret_id. Without the clone, calling try_into_s3() (which consumes storage_profile) would make warehouse partially moved and unusable.


234-247: LGTM! Consistent cloning pattern for cache population.

The clone here maintains consistency with the pattern on line 185 and ensures the warehouse struct remains intact even though only the remote_signing_url_style is extracted. This defensive approach is appropriate for a caching function.

crates/lakekeeper/src/request_metadata.rs (5)

11-12: LGTM!

The new imports support the error conversion implementations below and are correctly utilized.


51-53: LGTM!

The error type is well-defined with a clear, actionable message. The derives and structure are appropriate for error handling.


55-65: LGTM!

The conversion to ErrorModel is correctly implemented with an appropriate BAD_REQUEST status code and clear error type identifier.


67-71: LGTM!

The conversion correctly delegates through the ErrorModel conversion, avoiding code duplication.


221-228: All call sites properly handle the new error type.

Verified the error propagation chain:

  • The Result type uses IcebergErrorResponse as the default error type
  • ProjectIdMissing implements From for both ErrorModel and IcebergErrorResponse
  • All 10 call sites use the ? operator in functions returning Result<...>, which correctly converts ProjectIdMissing to IcebergErrorResponse through the From implementation

The refactored implementation is correct and idiomatic. The breaking API change is properly handled through the conversion chain.

crates/lakekeeper/src/implementations/mod.rs (2)

13-14: Consistent type import

Switch to SecretId looks good and aligns with the broader rename.


92-99: Return type change to SecretId is correct

Returning SecretId from create_secret matches the new identity model.

docs/docs/api/management-open-api.yaml (2)

1994-1997: Good consolidation to GetWarehouseResponse

Pointing rename/storage updates to a single GetWarehouseResponse schema improves consistency and discoverability. LGTM.

Also applies to: 2123-2126, 2158-2161


2956-2956: CreateWarehouseResponse → $ref reuse

Reusing GetWarehouseResponse here avoids drift between “create” and “get” payloads. Looks good.

crates/lakekeeper/src/service/endpoint_hooks.rs (2)

24-33: New API type imports are coherent

The added warehouse request types and identifiers align with the new hook methods. No issues spotted.


635-695: Cache hooks confirmed—all warehouse methods properly overridden

WarehouseCacheEndpointHook correctly overrides all 7 warehouse methods with cache operations: create/update methods call warehouse_cache_insert(), delete calls warehouse_cache_invalidate(). Cache coherence is maintained.

crates/lakekeeper/src/server/tables/create_table.rs (1)

206-211: Use of warehouse.warehouse_id is correct

This aligns the creation path with the new identifier semantics.

crates/lakekeeper/src/lib.rs (1)

17-18: Public re-export updated

SecretIdent → SecretId re-export looks correct and matches the new API.

crates/lakekeeper/src/server/config.rs (1)

57-59: AuthZ and config wiring updated; prefix default is a nice touch

  • Using warehouse.warehouse_id in AuthZ and config generation is consistent with the new model.
  • Adding defaults.prefix from CONFIG.warehouse_prefix improves client bootstrap.

Also applies to: 63-67, 68-71

crates/lakekeeper/src/service/catalog_store/view.rs (1)

27-28: Expose warehouse_updated_at on CatalogView

Field addition looks correct and consistent with the broader API exposing updated-at.

crates/lakekeeper/src/server/mod.rs (1)

108-117: SecretId migration in maybe_get_secret — OK.

crates/lakekeeper/src/service/mod.rs (1)

18-19: Public re-export updated to SecretId — OK.

crates/lakekeeper/src/service/catalog_store/table.rs (1)

24-31: Review comment is incorrect — these fields were never part of LoadTableResponse.

The search shows storage_secret_ident and storage_profile have no presence in LoadTableResponse contexts. These are legitimate fields of the Warehouse struct and related types elsewhere in the codebase. The review comment conflates different struct types. The warehouse_updated_at field is correctly integrated and propagated throughout the codebase (views, tables, database queries).

Likely an incorrect or invalid review comment.

crates/lakekeeper/src/tests/mod.rs (1)

168-181: Based on the verification results, the original review comment is incorrect. The code is properly configured:

  1. memory_io_profile() is defined with #[cfg(feature = "test-utils")], and dev-dependencies only activate features when building test targets.
  2. The call site in crates/lakekeeper/src/tests/mod.rs:172 is in test-only code.
  3. [dev-dependencies] are used for compiling tests, and the Cargo.toml explicitly enables test-utils in the dev-dependencies section (lakekeeper = { path = ".", features = ["test-utils"] }).

This is the standard safe pattern for feature-gated test utilities in Rust. No CI issue exists.


crates/lakekeeper/src/config.rs (1)

440-442: Warehouse cache field wiring looks good

Field is properly added under Cache with serde(default). No issues.

crates/lakekeeper/src/server/views/load.rs (4)

21-23: Imports reflect new cache-aware flow

Added CachePolicy, CatalogWarehouseOps OK.


76-79: Good: DB read ends before hitting cache/secret backends

begin_read/load/commit ordering avoids holding a read tx across external calls.


111-113: Using warehouse.storage_profile is correct

Matches the new warehouse shape and keeps access generation centralized.


80-86: CachePolicy::OnlyIfNewerThan behavior is already documented — no action required.

The CachePolicy::OnlyIfNewerThan variant's documentation explicitly states: "If None is provided, skip the cache entirely" (warehouse.rs, line 399). Passing None when view.warehouse_updated_at is None safely skips the cache and hits the database—no stale data risk. The code is correct and well-documented.

crates/lakekeeper/src/implementations/postgres/tabular/view/load.rs (1)

147-152: SQL→struct mapping looks consistent

Selecting w.updated_at AS warehouse_updated_at and adding the field to Query maps cleanly.

Is warehouse.updated_at nullable in schema? If not, you can drop Option<> to simplify. Otherwise keep Option and handle None upstream.

Also applies to: 407-407

crates/lakekeeper/src/implementations/kv2.rs (2)

21-27: SecretId migration: OK

Switching to SecretId in get_secret_by_id aligns with the new API.


81-83: Use v7 UUID: OK

Time-ordered IDs are appropriate for secrets.

crates/lakekeeper/src/implementations/postgres/secrets.rs (1)

11-12: SecretId migration is clean; error handling is appropriate.

Type changes, query bindings, and tests look consistent; redaction strategy for parse/serialize errors is good.

Also applies to: 54-58, 114-118, 151-153

crates/lakekeeper/src/implementations/postgres/tabular/table/mod.rs (1)

149-151: warehouse_updated_at wiring LGTM.

Selecting w.updated_at and threading through TableQueryStruct → LoadTableResponse is consistent and enables cache freshness checks upstream.

Also applies to: 519-520, 671-689

crates/lakekeeper/src/server/namespace.rs (2)

496-516: ResolvedWarehouse integration looks correct.

Passing &ResolvedWarehouse and using warehouse.warehouse_id keeps DB and authz in sync and simplifies location validation. Based on learnings.


690-713: Location validation via storage_profile is appropriate.

require_allowed_location/default_namespace_location usage is consistent with managed locations. Based on learnings.

crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (2)

49-75: Eviction listener handles rename/replace race correctly.

Conditioning on RemovalCause and checking current entry avoids invalidating fresh name mappings. Nice.


125-132: Metric uses entry_count() — good choice.

Accurately reflects number of cached entries; no weights configured.

crates/lakekeeper/src/api/management/mod.rs (1)

798-807: No issues found; return payload alignment is correct.

The three warehouse endpoints (rename_warehouse, update_storage_profile, update_storage_credential) properly return GetWarehouseResponse throughout the call chain:

  • Handler signatures correctly specify Result<GetWarehouseResponse>
  • OpenAPI specs at lines 798-807, 897-906, 922-931 correctly document the response type
  • V1 implementations consistently convert via .into() and return the warehouse object
  • No call sites in the codebase expect Result<()> from these handlers

Client SDK generation and regression tests remain your responsibility to verify externally, as they lie outside the codebase.

crates/lakekeeper/src/service/catalog_store.rs (1)

147-150: All warehouse methods in PostgresBackend correctly implement trait signatures.

Verification complete for all 8 methods (create, rename, get_by_id, get_by_name, set_deletion_profile, set_status, update_storage_profile, set_protected):

  • All return ResolvedWarehouse or Option<ResolvedWarehouse> ✓
  • Parameters match trait definitions ✓
  • SecretId used throughout; no lingering SecretIdent ✓
crates/lakekeeper/src/api/management/v1/warehouse/mod.rs (1)

480-487: Confirm intent: forcing DB read on GET (CachePolicy::Skip).

This bypasses the new cache and may add load. If staleness tolerance exists, consider Use or OnlyIfNewerThan(last_seen_updated_at) via conditional headers. If strict freshness is required, keep as-is.

crates/lakekeeper/src/implementations/postgres/catalog.rs (1)

442-449: LGTM: ResolvedWarehouse surface is correctly plumbed through.

Signatures align with impls; error types preserved.

Comment thread docs/docs/configuration.md Resolved
@c-thiel

c-thiel commented Oct 27, 2025

Copy link
Copy Markdown
Member Author

@CodeRabbit review

@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

♻️ Duplicate comments (5)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (2)

72-73: updated_at doc is clear now.

Thanks for clarifying the semantics; this resolves the earlier ambiguity.


418-451: Good: mutations avoid cache writes; hooks handle post‑commit.

Sticking to endpoint hooks for cache updates preserves transactional correctness and matches the project pattern.

crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (3)

49-75: Eviction listener correctly handles Replace vs other causes.

Conditionally invalidating the old name only when the current entry differs avoids the same‑name update race. Looks solid.


101-117: Insert guard on updated_at is now safe for Option.

Only skipping on Some/Some with curr >= new_ prevents missing updates when timestamps are absent.


127-134: Gauge uses entry_count(); correct metric for “number of entries.”

Nice fix.

🧹 Nitpick comments (4)
crates/lakekeeper/src/service/catalog_store/warehouse.rs (2)

393-403: CachePolicy docs and behavior are aligned.

OnlyIfNewerThan(None) meaning is explicit now; code below reflects it. Consider normalizing the policy early to reduce match complexity (nit).


500-574: Optional: normalize policy early to simplify branching.

Map OnlyIfNewerThan(None) → Use before the match. This removes the (None, None) case handling inside and keeps intent obvious.

 async fn get_warehouse_by_id_cache_aware(
     warehouse_id: WarehouseId,
     cache_policy: CachePolicy,
     state: Self::State,
 ) -> Result<Option<Arc<ResolvedWarehouse>>, CatalogGetWarehouseByIdError> {
-    let warehouse = match cache_policy {
+    let cache_policy = match cache_policy {
+        CachePolicy::OnlyIfNewerThan(None) => CachePolicy::Use,
+        other => other,
+    };
+    let warehouse = match cache_policy {
         CachePolicy::Skip => {
             // ...
         }
         CachePolicy::Use => {
             // ...
         }
-        CachePolicy::OnlyIfNewerThan(require_updated_after) => {
+        CachePolicy::OnlyIfNewerThan(require_updated_after) => {
             // unchanged…
         }
     };
     Ok(warehouse)
 }
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (2)

80-86: Optional: add TTL to the name→id index for extra resilience.

Even though the listener keeps the index coherent, a small TTL bounds staleness in edge cases.

 static NAME_TO_ID_CACHE: LazyLock<Cache<(ProjectId, String), WarehouseId>> = LazyLock::new(|| {
     Cache::builder()
         .max_capacity(CONFIG.cache.warehouse.capacity)
         .initial_capacity(50)
+        .time_to_live(Duration::from_secs(30))
         .build()
 });

43-77: Reduce hot‑path metric overhead; update gauge on evictions instead.

Move the gauge update into the eviction listener and drop per‑get updates to cut read‑path overhead while keeping accuracy.

@@
-        .async_eviction_listener(|key, value: CachedWarehouse, cause| {
+        .async_eviction_listener(|key, value: CachedWarehouse, cause| {
             Box::pin(async move {
                 // Evictions:
                 // ...
                 if should_invalidate {
                     NAME_TO_ID_CACHE
                         .invalidate(&(
                             value.warehouse.project_id.clone(),
                             value.warehouse.name.clone(),
                         ))
                         .await;
                 }
+                update_cache_size_metric();
             })
         })
@@
-pub(super) async fn warehouse_cache_get_by_id(
+pub(super) async fn warehouse_cache_get_by_id(
     warehouse_id: WarehouseId,
 ) -> Option<Arc<ResolvedWarehouse>> {
-    update_cache_size_metric();
     if let Some(value) = WAREHOUSE_CACHE.get(&warehouse_id).await {
@@
-pub(super) async fn warehouse_cache_get_by_name(
+pub(super) async fn warehouse_cache_get_by_name(
     name: &str,
     project_id: &ProjectId,
 ) -> Option<Arc<ResolvedWarehouse>> {
-    update_cache_size_metric();
     let Some(warehouse_id) = NAME_TO_ID_CACHE

Please sanity‑check gauge accuracy after this change under TTL expirations (it should update via the listener).

Also applies to: 127-134, 136-148, 150-172

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5768098 and 0701e12.

📒 Files selected for processing (3)
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs (12 hunks)
  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (1 hunks)
  • docs/docs/configuration.md (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/docs/configuration.md
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-10-27T11:26:34.813Z
Learnt from: c-thiel
PR: lakekeeper/lakekeeper#1462
File: crates/lakekeeper/src/service/catalog_store/warehouse.rs:418-430
Timestamp: 2025-10-27T11:26:34.813Z
Learning: In the lakekeeper codebase, cache invalidation for warehouse mutations (create, rename, status updates, storage updates, etc.) is handled through endpoint hooks that run after transaction commits, not within the transaction methods themselves. The WarehouseCacheEndpointHook is responsible for updating the warehouse cache.

Applied to files:

  • crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs
  • crates/lakekeeper/src/service/catalog_store/warehouse.rs
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: docker / docker
  • GitHub Check: test
  • GitHub Check: clippy
  • GitHub Check: docker / docker
  • GitHub Check: check-generated-openapi-matches
  • GitHub Check: docker / docker
  • GitHub Check: sqlx-check
  • GitHub Check: docker / docker
🔇 Additional comments (1)
crates/lakekeeper/src/service/catalog_store/warehouse_cache.rs (1)

186-258: All verification checks pass—no actionable issues.

The WarehouseCacheEndpointHook is properly registered in serve.rs (lines 365–369), conditionally gated on CONFIG.cache.warehouse.enabled. The hook struct and EndpointHook implementation both respect the "router" feature flag. All warehouse mutation methods (create_warehouse, delete_warehouse, set_warehouse_protection, rename_warehouse, update_warehouse_delete_profile, update_warehouse_storage, update_warehouse_storage_credential) correctly call warehouse_cache_insert() or warehouse_cache_invalidate() to update the cache on post-commit mutations. Configuration toggles exist and are properly tested.

@c-thiel

c-thiel commented Oct 27, 2025

Copy link
Copy Markdown
Member Author

@CodeRabbit review

@coderabbitai

coderabbitai Bot commented Oct 27, 2025

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@github-actions

Copy link
Copy Markdown
Contributor

✅ PR Title Formatted Correctly

The title of this PR match the correct format. Thank you!

@c-thiel
c-thiel merged commit 443548a into main Oct 27, 2025
@c-thiel
c-thiel deleted the ct/warehouse-cache-impl branch October 27, 2025 13:35
mrjoe7 added a commit to mrjoe7/lakekeeper that referenced this pull request Oct 30, 2025
* feat: Publish images to Dockerhub (lakekeeper#1274)

* feat: Update UI to 0.9.0 with multi-project support (lakekeeper#1275)

* chore: release 0.9.4

Release-As: 0.9.4

* chore: release main (lakekeeper#1262)

* chore(ci): Fix Dockerhub login

* chore(docs): Improve developer guide (lakekeeper#1265)

* chore(docs): add info regarding `view_version`'s internal representation (lakekeeper#1261)

* chore(docs): Architecture clarify Secret Store (lakekeeper#1284)

* fix: Update Limes to 0.2.2 - Fixes compilation issue due to breaking `jwks_client_rs` change (lakekeeper#1282)

* fix: Update Limes to 0.2.2

* increase min rust version

* chore: release 0.9.5

Release-As: 0.9.5

* chore: release main (lakekeeper#1286)

* chore: enable changelog sections for release-please (lakekeeper#1264)

k

* fix(deps): update rust crate rand to v0.9.2 (lakekeeper#1252)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate async-channel to v2.5.0 (lakekeeper#1225)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency mkdocs-material to v9.6.17 (lakekeeper#1289)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate anyhow to v1.0.99 (lakekeeper#1290)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore: Remove bitnami images (lakekeeper#1288)

* feat!: Move to Lakekeeper IO based on hyperscaler SDKs (lakekeeper#1285)

* chore(deps): update rust crate reqwest to v0.12.23 (lakekeeper#1294)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(docs): Improve Cloud storage test docs

* fix: accept "disable" as PG sslmode as documented (lakekeeper#1303)

* feat: Simplify task interface, re-exports, enable delete-after-commit (lakekeeper#1302)

* feat: Introduce `RequestMetadata` for Internal Principals which bypass AuthZ (lakekeeper#1306)

* chore(deps): update azure/setup-helm action to v4.3.1 (lakekeeper#1299)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(test): use nextest filterset instead of needs_env_var (lakekeeper#1304)

* chore(deps): update rust crate openssl-src to v300.5.2 (lakekeeper#1292)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate async-compression to v0.4.28 (lakekeeper#1311)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate thiserror to v2.0.16 (lakekeeper#1296)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: Provide `ApiContext` to externally registered tasks (lakekeeper#1307)

* feat!: Simplify Task interface, extend SpecializedTask interface (lakekeeper#1310)

* feat: Improve authorizer `are_allowed_*` batch check signature (lakekeeper#1315)

* chore(authz): Enforce use of AuthZ decisions with #[must_use] (lakekeeper#1317)

* feat: Task Management APIs (lakekeeper#1316)

* chore(deps): update rust crate tracing-subscriber to v0.3.20 [security] (lakekeeper#1318)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: Add `RunNow` and `RunAt` to Controls for Tasks (lakekeeper#1322)

* chore(deps): update rust crate tokio-util to v0.7.16 (lakekeeper#1313)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(docs): Improve Entra ID docs (lakekeeper#1325)

* chore(docs): Improve Upgrades & Migration docs (lakekeeper#1326)

* feat: Add tasks heartbeat with Catalog state (lakekeeper#1324)

* ci: add configuration for CodeRabbit reviews (lakekeeper#1327)

* feat: Add optional STS session-tags in S3 STS requests for ABAC authorization (lakekeeper#1230)

* feat: Random Server IDs (lakekeeper#1328)

* chore(deps): update rust crate percent-encoding to v2.3.2 (lakekeeper#1312)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat(authz): Deprecate Permission Endpoints for Tables without WarehouseIDs (lakekeeper#1334)

* fix: Tasks endpoints in router (lakekeeper#1335)

* feat(ci): add nextest profile ci_no_secrets for external PRs (lakekeeper#1333)

* chore(deps): update rust crate chrono to v0.4.42 (lakekeeper#1331)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore: Pin examples duckdb version to 1.3 (lakekeeper#1343)

* feat!: Require warehouse_id when checking permissions on views or tables via ID (lakekeeper#1340)

* fix: migrate away from bitnami in unittest.yml (lakekeeper#1344)

* chore: Remove coderabitt config

* fix(docs): Fix inconsistent URL format in README (lakekeeper#1345)

Co-authored-by: Christian <[email protected]>

* feat: Remove serde_yaml & serde_yml (lakekeeper#1341)

* feat!: add `warehouse_id` to PKs of all `table_*` and `view_*` tables (lakekeeper#1254)

* feat: Minor namespace join performance improvements

* fix: Warehouse permissions are directly used for task retrieval & control (lakekeeper#1347)

* fix: Potential Race Condition when undropping Tabulars (lakekeeper#1342)

* fix: table rename authz and error handling (lakekeeper#1346)

Co-authored-by: Andre Luis Anastacio <[email protected]>

* chore(deps): update rust crate google-cloud-auth to v1.1.2 (lakekeeper#1337)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* chore(deps): update rust crate time to v0.3.44 (lakekeeper#1349)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency mkdocs-material to v9.6.20 (lakekeeper#1309)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* feat: Set ServerID during migration (lakekeeper#1348)

* chore(deps): Remove utoipa fork (lakekeeper#1352)

* chore(deps): update rust crate serde_with to v3.14.1 (lakekeeper#1351)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate url to v2.5.7 (lakekeeper#1354)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate async-compression to v0.4.30 (lakekeeper#1323)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* chore(deps): update rust crate serde_json to v1.0.145 (lakekeeper#1250)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* chore(deps): update strum monorepo to v0.27.2 (lakekeeper#1251)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* chore(deps): update serde monorepo to v1.0.226 (lakekeeper#1355)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix(deps): update rust crate clap to v4.5.48 (lakekeeper#1356)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: Add Entity Names to Tasks (lakekeeper#1353)

* fix: case insensitivity of catalog endpoints (lakekeeper#1338)

* fix: Improve delete_warehouse error message for active tasks

* chore(deps): update rust crate tempfile to v3.22.0 (lakekeeper#1359)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christian <[email protected]>

* chore(deps): update rust crate axum-prometheus to 0.9.0 (lakekeeper#1358)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: PgSslMode not supported error string

* feat(authz)!: add OpenFGA schema v4 and v3->v4 migration (lakekeeper#1314)

Co-authored-by: Christian <[email protected]>
Co-authored-by: Christian Thiel <[email protected]>

* chore(deps): update rust crate uuid to v1.18.1 (lakekeeper#1362)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency markdown-grid-tables to v0.6.0 (lakekeeper#1357)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate anyhow to v1.0.100 (lakekeeper#1350)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: clippy

* chore(deps): update rust crate moka to v0.12.11 (lakekeeper#1365)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate tempfile to v3.23.0 (lakekeeper#1367)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update rust crate async-nats to 0.43.0 (lakekeeper#1366)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update actions/setup-node action to v5 (lakekeeper#1371)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update actions/checkout action to v5 (lakekeeper#1369)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update actions/setup-python action to v6 (lakekeeper#1372)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: V3 support (lakekeeper#1364)

* chore: Set Get Task Permission to "CanGetMetadata" (lakekeeper#1376)

* chore(deps): update dependency node to v22 (lakekeeper#1373)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat(authz)!: extend OpenFGA tabular entities with WarehouseId (lakekeeper#1329)


---------

Co-authored-by: Christian <[email protected]>
Co-authored-by: Christian Thiel <[email protected]>

* feat: Add support for tasks affecting views (lakekeeper#1378)

* feat(authz): Add specific Task Actions (lakekeeper#1379)

* chore(tests): Test with Iceberg 1.9.2 & 1.10.0 (lakekeeper#1267)

* feat: Enrich task metadata with concrete tabular type (lakekeeper#1383)

* feat: Add loadTable Snapshots filter (lakekeeper#1385)

* feat: add endpoint for fuzzy search of tabulars (lakekeeper#1387)

* feat: Update UI to 0.10.0 (lakekeeper#1390)

* feat(ui): Update UI to 0.10.1

* chore: Use lakekeeper re-exports in bin (lakekeeper#1391)

* fix(tabular-search): distance and docs for `searchterm is uuid` (lakekeeper#1393)

* chore(examples): Idempotent bucket creation in minimal example (lakekeeper#1386)

In the case where you already have a bucket created, like the "examples" bucket, I ran into an issue where the createbuckets service fails, and this prevents lakekeeper from starting back up.

This fix adds a simple minio flag to ignore buckets that already exist, making things even more user friendly

* feat: Make number of workers spawned for Expiration & Purge configurable (lakekeeper#1395)

* chore: release main (lakekeeper#1295)

* chore: added gif to readme (lakekeeper#1396)

* chore: remove unneded `#[allow(dead_code)]` (lakekeeper#1399)

* fix: Use FnOnce for queue & service registration

* Revert "fix: Use FnOnce for queue & service registration"

This reverts commit 47b03a0.

* chore(docs): Add 0.10 docs

* perf(db): remove `join namespace` from `active_tabulars` view (lakekeeper#1401)

* doc(db): how to connect to db and inspect schema (lakekeeper#1402)

* feat: implement `OpenFgaEntity` for `ServerId` (lakekeeper#1394)

* impl OpenFgaEntity
* Use the implementation

* fix: Use FnOnce for queue & service registration (lakekeeper#1404)

* chore(deps): update dependency mkdocs-material to v9.6.21 (lakekeeper#1406)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: Expose client-managed X-Iceberg-Access-Delegation (lakekeeper#1407)

* fix: Use higher consistency for some OpenFGA queries (lakekeeper#1408)

* feat: Improve Kubernetes Auth docs (lakekeeper#1415)

* chore: release 0.10.1

Release-As: 0.10.1

* fix: Endpoint stats for Project Endpoints (lakekeeper#1412)

* feat: Add create table guard to cleanup location on Failure (lakekeeper#1418)

* chore: Generate ID types with Macro (lakekeeper#1419)

* chore: Re-Export Tokio from lakekeeper-io create (lakekeeper#1420)

* fix: Add support for `write.metadata.metrics.` Table Properties (lakekeeper#1422)

* fix: Update UI to 0.10.2 (lakekeeper#1423)

* chore: release main (lakekeeper#1403)

* fix: Parse empty ProjectID headers as None (lakekeeper#1424)

* chore: release 0.10.2

Release-As: 0.10.2

* chore: release main (lakekeeper#1425)

* feat: Add `debug_migrate_before_serve` env var (lakekeeper#1426)

* feat: Move OpenFGA Authorizer to separate crate (lakekeeper#1421)

* chore(renovate): Group dependencies

* chore(renovate): ignore additional deps

* chore: Rename src/service -> src/server, trait Catalog -> CatalogStore (lakekeeper#1428)

* feat(examples): add k8s iceberg sink connector (avro) (lakekeeper#1336)


---------

Co-authored-by: Christian <[email protected]>

* chore(ci): Fix release please (lakekeeper#1433)

* feat: Expose License Information via API (lakekeeper#1432)

* fix(deps): update all non-major dependencies (lakekeeper#1429)

* chore(ci): Remove mgmt API version update via release-please

* chore: Restructure catalog_store into multiple modules (lakekeeper#1434)

* feat: Validate Downscoping works on Warehouse creation (lakekeeper#1437)

* chore(ci): Fix release please

* docs: Add info about installing sqlx to developer-guide.md (lakekeeper#1438)

* docs: Update developer-guide.md (lakekeeper#1439)

* chore(deps): update all non-major dependencies (lakekeeper#1436)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: Better normalization for ARNs in S3 Profile (lakekeeper#1441)

* chore(deps): update all non-major dependencies (lakekeeper#1442)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(main): release 0.10.3 (lakekeeper#1427)

* fix: Release Please CI outputs

* fix(ci): Revert 0.10.3 release

* chore(main): release 0.10.3 (lakekeeper#1446)

* feat: Introduce CatalogWarehouseOps & CatalogNamespaceOps abstractions (lakekeeper#1440)

* feat: Allow x-user-agent header (lakekeeper#1453)

* feat: Table & View Ops Abstractions, Improved Error Handling (lakekeeper#1454)

* fix: CORS allow access delegation & etag headers (lakekeeper#1455)

* fix: Headers should be lowercase (lakekeeper#1457)

* chore(tests): Add trino information_schema.tables test (lakekeeper#1456)

* chore: Introduce open-api feature to gate utoipa and swagger (lakekeeper#1458)

* chore: Release As 0.11

* fix: Debug assertion table identifier mismatch for signer (lakekeeper#1460)

* feat: Caching Short-Term-Credentials (STC) (lakekeeper#1459)

* feat: Warehouse Cache (lakekeeper#1462)

* chore(deps): update actions/setup-node action to v6 (lakekeeper#1443)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: Version based Warehouse Cache (lakekeeper#1465)

* feat: AuthZ Server and Project Ops (lakekeeper#1471)

* chore(deps): update github artifact actions (lakekeeper#1461)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore: Rename release branch pattern to rel-*

* feat: Catalog returns full Namespace Hierarchy for nested Namespaces (lakekeeper#1472)

---------

Co-authored-by: Christian <[email protected]>
Co-authored-by: Christian Thiel <[email protected]>
Co-authored-by: Dao Thanh Tung <[email protected]>
Co-authored-by: Moritz Zielke <[email protected]>
Co-authored-by: Baptiste Gouhoury <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Dolan Antenucci <[email protected]>
Co-authored-by: Anatoly Popov <[email protected]>
Co-authored-by: Andre Luis Anastacio <[email protected]>
Co-authored-by: Scott Haines <[email protected]>
Co-authored-by: Viktor Kessler <[email protected]>
Co-authored-by: Yohan Valencia <[email protected]>
Co-authored-by: Paul Roman <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant