Skip to content

[#12457] feat(secret): Add load*WithResolvedProperties for catalog/schema/fileset - #12458

Open
lasdf1234 wants to merge 7 commits into
apache:mainfrom
lasdf1234:feat/secret-resolved-properties
Open

[#12457] feat(secret): Add load*WithResolvedProperties for catalog/schema/fileset#12458
lasdf1234 wants to merge 7 commits into
apache:mainfrom
lasdf1234:feat/secret-resolved-properties

Conversation

@lasdf1234

@lasdf1234 lasdf1234 commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

What changes were proposed in this pull request?

Add an explicit API so connectors and REST services can load catalog/schema/fileset with secret URNs resolved to plaintext in properties(), without changing default loadCatalog omit behavior.

  • Core: SecretPropertyUtils.buildResolvedProperties + dispatcher load*WithResolvedProperties returning Catalog/Schema/Fileset
  • REST: optional ?view=resolved on existing load endpoints
  • OpenAPI, Java/Python clients
  • Wire Spark/Flink/Trino/Lance/Iceberg consumers to use resolved load

Example:

Catalog catalog = metalake.loadCatalogWithResolvedProperties(catalogName);
Map<String, String> props = catalog.properties(); // URN → plaintext

Why are the changes needed?

Fix: #12457

Entity secrets (epic #12297) persist URNs in properties; default HTTP load omits those keys. Connectors and Lance/IRC need plaintext for connection config without weakening the safe default load path or duplicating credential vending.

Does this PR introduce any user-facing change?

  • Yes: new client methods loadCatalogWithResolvedProperties / loadSchemaWithResolvedProperties / loadFilesetWithResolvedProperties
  • REST load endpoints accept optional view=resolved
  • Default loadCatalog().properties() semantics unchanged

How was this patch tested?

  • ./gradlew :core:test --tests 'org.apache.gravitino.secret.TestSecretPropertyUtils' -PskipITs
  • Server REST unit tests for catalog/schema/fileset ?view=resolved
  • Connector / Lance / Iceberg compile checks

lasdf1234 and others added 3 commits August 13, 2026 18:00
…talog/schema/fileset

Co-authored-by: Cursor <cursoragent@cursor.com>
…s OpenAPI path

Co-authored-by: Cursor <cursoragent@cursor.com>
…options

Use loadCatalogResolvedProperties when building Lance table storage
options so secret URNs are replaced with plaintext.

Co-authored-by: Cursor <cursoragent@cursor.com>
Keep the implementation PR focused; design discussion can stay in the issue.

Co-authored-by: Cursor <cursoragent@cursor.com>
@lasdf1234 lasdf1234 changed the title [#12457] feat(secret): Add resolved plaintext properties for catalog/schema/fileset [#12457] feat(secret): Add load*WithResolvedProperties for catalog/schema/fileset Aug 13, 2026
lasdf1234 and others added 3 commits August 13, 2026 19:36
…edProperties

Replace Map-based load*ResolvedProperties with Catalog/Schema/Fileset
returning load*WithResolvedProperties so callers get plaintext via
properties() in one load. REST uses optional ?view=resolved on existing
load endpoints; remove dedicated /properties + PropertyMapResponse.
Wire Spark/Flink/Trino/Lance/Iceberg to the new API.

Co-authored-by: Cursor <cursoragent@cursor.com>
…d path

- Fix CI: auth expression method signatures, Lance CatalogOperator stub,
  Trino mock loadCatalogWithResolvedProperties
- Emit redacted Load* events for resolved loads (no plaintext in payload)
- Wire Java/Python GVFS property merge to resolved load APIs
- Add FilesetOperationDispatcher loadWithResolvedProperties e2e test
- Align SupportsCatalogs default UOE; document CatalogInfo limits
- Update catalog docs for view=resolved vs credential vending

Co-authored-by: Cursor <cursoragent@cursor.com>
Stub loadCatalogWithResolvedProperties in Lance mode-parsing unit tests,
and backfill the default in-use property on catalog resolved loads so
describeNamespace matches BaseCatalog#properties().

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions

Copy link
Copy Markdown

Code Coverage Report

Overall Project 68.58% -0.34% 🟢
Files changed 62.27% 🟢

Module Coverage
aliyun 1.72% 🔴
api 49.27% -0.36% 🟢
authorization-common 85.96% 🟢
aws 42.04% 🟢
azure 2.47% 🔴
catalog-common 9.92% 🔴
catalog-fileset 79.77% 🟢
catalog-glue 68.95% 🟢
catalog-hive 79.4% 🟢
catalog-jdbc-common 45.7% 🟢
catalog-jdbc-doris 81.8% 🟢
catalog-jdbc-mysql 79.33% 🟢
catalog-jdbc-postgresql 83.39% 🟢
catalog-jdbc-starrocks 79.16% 🟢
catalog-kafka 77.01% 🟢
catalog-lakehouse-generic 59.18% 🟢
catalog-lakehouse-hudi 79.1% 🟢
catalog-lakehouse-iceberg 85.86% 🟢
catalog-lakehouse-paimon 84.23% 🟢
catalog-model 77.72% 🟢
cli 44.48% 🟢
client-java 77.96% +3.82% 🟢
common 52.75% 🟢
core 83.4% -0.52% 🟢
filesystem-hadoop3 76.45% -1.49% 🟢
flink 0.0% 🔴
flink-common 48.62% -2.93% 🟢
flink-runtime 0.0% 🔴
gcp 14.12% 🔴
hadoop-auth 68.0% 🟢
hadoop-common 12.7% 🔴
hive-metastore-common 53.4% 🟢
iceberg-aliyun-bundle 0.0% 🔴
iceberg-common 64.75% 🟢
iceberg-rest-server 74.96% -1.17% 🟢
idp-basic 86.02% 🟢
integration-test-common 0.0% 🔴
jobs 62.92% 🟢
lance-common 31.3% -20.08% 🔴
lance-rest-server 63.47% 🟢
lineage 53.02% 🟢
optimizer 83.17% 🟢
optimizer-api 21.95% 🔴
server 87.43% +0.72% 🟢
server-common 79.41% 🟢
spark 28.57% 🔴
spark-common 45.84% -5.09% 🟢
tencent 69.84% 🟢
trino-connector 40.33% +0.15% 🟢
Files
Module File Coverage
api SupportsCatalogs.java 0.0% 🔴
SupportsSchemas.java 0.0% 🔴
FilesetCatalog.java 0.0% 🔴
client-java FilesetCatalog.java 92.37% 🟢
BaseSchemaCatalog.java 92.31% 🟢
GravitinoMetalake.java 90.89% 🟢
GravitinoClient.java 71.08% 🟢
core SecretPropertyUtils.java 97.83% 🟢
FilesetOperationDispatcher.java 95.88% 🟢
SchemaNormalizeDispatcher.java 95.24% 🟢
SchemaHookDispatcher.java 90.2% 🟢
FilesetNormalizeDispatcher.java 86.96% 🟢
FilesetEventDispatcher.java 84.54% 🟢
CatalogEventDispatcher.java 83.17% 🟢
FilesetHookDispatcher.java 82.86% 🟢
SchemaEventDispatcher.java 82.81% 🟢
SchemaOperationDispatcher.java 75.6% 🟢
CatalogManager.java 68.24% 🟢
CatalogNormalizeDispatcher.java 37.5% 🔴
CatalogHookDispatcher.java 35.19% 🔴
SupportsCatalogs.java 20.0% 🔴
SchemaDispatcher.java 0.0% 🔴
filesystem-hadoop3 BaseGVFSOperations.java 74.25% 🟢
flink-common GravitinoCatalogStore.java 33.33% 🔴
GravitinoCatalogManager.java 19.3% 🔴
iceberg-rest-server DynamicIcebergConfigProvider.java 38.76% 🔴
lance-common GravitinoLanceNamespaceWrapper.java 47.43% 🔴
GravitinoLanceTableOperations.java 2.87% 🔴
GravitinoLanceNameSpaceOperations.java 1.42% 🔴
server SchemaOperations.java 100.0% 🟢
CatalogOperations.java 99.07% 🟢
FilesetOperations.java 86.36% 🟢
spark-common GravitinoCatalogManager.java 51.52% 🔴
BaseCatalog.java 14.76% 🔴
trino-connector GravitinoCatalog.java 95.45% 🟢
CatalogConnectorManager.java 29.78% 🔴

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.

feat(secret): Deliver resolved plaintext properties for connectors / Lance / IRC

1 participant