Add location properties from TableMetadata into Table entity internalProps#3226
Conversation
There was a problem hiding this comment.
Looks like a reasonable change to me - I don't see any reason why storing these storage locations is a hefty and/or unreasonable addition to the entities. Happy to switch my opinion if anyone has valid concerns regarding the addition of these locations.
snazy
left a comment
There was a problem hiding this comment.
This change raises a question:
Does Polaris actively support setting these properties at all?
Polaris performs a lot of effort to ensure that table/view/namespace locations do not overlap and conflict with each other.
Seeing this change, I realize that neither of these two properties is subject to the same location-overlap or location-validity checks.
I think this change deserves a broader dev mailing list discussion about these two properties in general, mentioning that these properties (and their deprecated, but still evaluated older properties) can break both location validity and overlap checks and assumptions.
dimas-b
left a comment
There was a problem hiding this comment.
The diff in this PR LGTM in isolation.
However, making use of the new entity properties can be tricky as Polaris code will have to deal with old entities (on upgrade), which may not have the new properties.
So all in all, having a dev discussion could be useful, indeed.
|
I might be wrong but it seems the locations are taken into account for overlap in The problem is that later on in that same method, the internal properties map is computed: But the map currently doesn't include So, the only way to check those locations is to load the table from the object store. |
Correct – code would have to be lenient to the properties being absent. For request signing at least, the idea would be to load the table if the properties are absent, then update the entity, so that next time the properties are there. |
precisely, the idea is to have location props in sync with what is present in the object store, to avoid redundant call as presently the loadCreds is doing unneccessary call to load from objectstore. when we plan to use it we need to handle backfill, Here is the discuss in Alex on the same Re: opening mail list thread, sure happy to facilitate the discussion over MT on how to handle back fill, me and Alex had some idea which Alex mentioned, on this context but defintely more inputs are certainly welcomed. |
|
This PR is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
adutra
left a comment
There was a problem hiding this comment.
I think this change can be useful, even if there is no call site today in Polaris that could benefit from the new entity properties.
There was a problem hiding this comment.
This change LGTM purely from the java code perspective and I do not mind merging it.
TBH, I lost context with any related dev discussions. @singhpk234 : Could you update on the status?
From my POV, I do not require a dev discussion, but it might be worth opening for the sake of awareness of other Polaris developers.
|
Thanks for the review everyone, i merged this since there were no objection, i will followup with the credential endpoint optimisation ! |
* "Stale" job: don't close stale issues (apache#3683) This PR also fixes the configuration and upgrades the action to the latest version. * Fix integration-tests after apache#3704 (apache#3711) Short story: This change fixes the int-tests in `:polaris-runtime-service`. Long story is this: In `:polaris-runtime-service` we intentionally declare "just" a `platform(libs.quarkus.bom)` dependency, because of the `:polaris-spark-integration-*` module. It is however generally recommended by Quarkus to _only_ use `enforcedPlatform(libs.quarkus.bom)` to effectively prevent breaking changes coming from transitive dependencies. Which is exactly what happend after apache#3704. Why did CI not catch this issue? The answer is pretty simple: The effective Gradle task inputs, including the `intTestRuntimeClasspath` did not change. So the previously cached test outcomes could be reused, and the int-tests did not run. Just adding the `runtimeClasspath` as another task-input of the `intTest` may _not_ work as intended. Why does _removing_ `implementation(platform(libs.opentelemetry.bom))` help? Simply because that lets the dependencies fall back to to the declared transitive dependencies. We do not have direct dependencies to OTel. The correct fix here _would_ be to use `implementation(enforcedPlatform(libs.quarkus.bom))`, but that breaks the Spark plugin integration tests. There is a better alternative: Let the Spark plugin tests leverage polaris-apprunner, which is meant for exactly the use case of effectively decoupling some module from the build requirements of a Quarkus application. * CI: fix missing Gradle build scans (apache#3709) Publishing the Gradle build scans requires the `DEVELOCITY_ACCESS_KEY` secret. For workflow-calls, each secret to be propagated to a called workflow must be explicitly defined. This change propagates the secrets from `ci-main.yml` to the called `ci.yml`. * Add Polaris Community Meetings for 2026-01-22 and 2026-02-05 (apache#3715) * Add location propertiesfrom TableMetadata into Table entity internalProperties (apache#3226) * Compile client modules with Java 17 compatibility (apache#3712) * Last merged commit ba048c8 --------- Co-authored-by: Alexandre Dutra <[email protected]> Co-authored-by: JB Onofré <[email protected]> Co-authored-by: Prashant Singh <[email protected]>
About the change
Presently since not all the location properties are stored in the entity one has to do complete loadTable table even for existing use cases such as credential endpoint which in present scenario since polaris doesn't store the complete metadata copy inside the persistence is kind of expensive.
With this we will have a way to do cred vending, in future (to remote sign) without going to object store.
Note if we take dependency on this we would have to think of backfill but for step 1 it seems reasonable step, would love to know what other folks think
polaris/runtime/service/src/main/java/org/apache/polaris/service/catalog/iceberg/IcebergCatalogAdapter.java
Lines 616 to 625 in 8ba112e
co-author : @adutra
Checklist
CHANGELOG.md(if needed)site/content/in-dev/unreleased(if needed)