Expand description
The Unity Catalog REST API server.
This crate implements the Unity Catalog REST surface as a set of axum
routers over three pluggable dependencies, injected as trait objects:
- a
ResourceStore— the persistence backend (in-memory,unitycatalog-postgres, orunitycatalog-sqlite); - a
Policy— the authorization decision point; and - a
CommitCoordinator— the Delta catalog-managed commit backend.
ServerHandler composes those dependencies. It is
generic over an authorization context Cx (the identity or request state a
Policy evaluates against), cheap to clone, and satisfies
the store and policy traits by delegation — so the generated handler traits in
api can be blanket-implemented over it. To swap a backend, construct the
handler with a different trait object; no handler code changes.
§Layout
api— per-resource handler traits (generated) plus their hand-written business logic, and theSecuredActionpermission mapping.policy— thePolicyauthorization trait,Permission/Decision, and the allow-allConstantPolicy.store— storage-abstraction traits, re-exported fromunitycatalog-common.rest— theaxumrouters that expose the handlers over HTTP.services—ServerHandlerand theProvides*dependency-injection traits.handlers— reusable handler patterns (e.g. proxy leaves that forward to an upstream catalog).
§Feature flags
memory enables the in-memory store; proxy pulls in the upstream-forwarding
handlers; bin adds the config/CLI/serve wiring used by the uc-server
binary. See the crate README for the full table.