Skip to content

CatalogService

CatalogService is a Unity Catalog API service to handle HTTP requests at /api/2.1/unity-catalog/catalogs URL.

Method URL Handler Params
GET listCatalogs
POST createCatalog JSON-ified CreateCatalog
GET /{name} getCatalog
  • name
PATCH /{name} updateCatalog
  • name
DELETE /{name} deleteCatalog
  • name

CatalogService is also used to create IcebergRestCatalogService.

Creating Instance

CatalogService takes the following to be created:

While being created, CatalogService creates an UnityAccessEvaluator.

CatalogService is created when:

UnityAccessEvaluator

CatalogService creates an UnityAccessEvaluator (with the given UnityCatalogAuthorizer) when created.

listCatalogs

HttpResponse listCatalogs()

listCatalogs...FIXME


listCatalogs is used when:

  • CatalogService is requested to handle HTTP GET requests on catalogs URL
  • FIXME

Demo

$ http http://localhost:8081/api/2.1/unity-catalog/catalogs
HTTP/1.1 200 OK
content-length: 184
content-type: application/json
date: Thu, 4 Jul 2024 17:56:19 GMT
server: Armeria/1.28.4

{
    "catalogs": [
        {
            "comment": "Main catalog",
            "created_at": 1720090500565,
            "id": "17562adb-e6f8-463e-b82a-22264b067d6b",
            "name": "unity",
            "properties": {},
            "updated_at": null
        }
    ],
    "next_page_token": null
}
$ http http://localhost:8081/api/2.1/unity-catalog/catalogs | jq '.catalogs[].name'
"unity"