Add lightweight tableExists endpoint to tables service#631
Open
jiang95-dev wants to merge 1 commit into
Open
Conversation
Adds GET /v0|v1/databases/{databaseId}/tables/{tableId}/exists which
returns HTTP 200 if the table exists and HTTP 404 otherwise.
Existence is determined via a HouseTable reference lookup
(findTableRefById) that does not parse metadata.json or read from HDFS,
making it cheaper than GET Table. Authorization is enforced via
@secured(GET_TABLE_METADATA).
Adds service/handler/controller plumbing plus e2e and mock controller
tests, including a test that verifies existence is reported even when
metadata.json is corrupted (since GET Table would fail in that case).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add a new lightweight
tableExistsendpoint which bypass HDFS and only query HTS. This is useful to Metacat and ODD which only need to know if table exists without knowing its metadata.Changes
For all the boxes checked, please include additional details of the changes made in this pull request.
Testing Done
For all the boxes checked, include a detailed description of the testing done for the changes made in this pull request.
Additional Information
For all the boxes checked, include additional details of the changes made in this pull request.