Skip to content

Commit 6c44077

Browse files
AuthorizeKey and Server Authorization
1 parent 32c44db commit 6c44077

File tree

4 files changed

+48
-1
lines changed

4 files changed

+48
-1
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# AuthorizeKey
2+
3+
`AuthorizeKey` defines authorization policies of the API services of [UnityCatalogServer](../server/UnityCatalogServer.md) for [Server Authorization](index.md):
4+
5+
* [CatalogService](../server/CatalogService.md)
6+
* [FunctionService](../server/FunctionService.md)
7+
* [ModelService](../server/ModelService.md)
8+
* [PermissionService](../server/PermissionService.md)
9+
* [SchemaService](../server/SchemaService.md)
10+
* [Scim2UserService](../server/Scim2UserService.md)
11+
* [TableService](../server/TableService.md)
12+
* [TemporaryPathCredentialsService](../server/TemporaryPathCredentialsService.md)
13+
* [VolumeService](../server/VolumeService.md)
14+
15+
Every operation of an API service is decorated with `AuthorizeKey` annotation for server authorization.
16+
17+
`AuthorizeKey` consists of a [SecurableType](../basic-server-access-control/index.md#securables) and an optional name of the securable.
18+
19+
`AuthorizeKey` maps request parameters to [SecurableType](../basic-server-access-control/index.md#securables)s (default: (empty)).
20+
21+
The Unity Catalog server uses [UnityAccessDecorator](UnityAccessDecorator.md) to [findAuthorizeKeys](UnityAccessDecorator.md#findAuthorizeKeys).
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# AuthorizeKeys
2+
3+
`AuthorizeKeys` maps multiple [AuthorizeKey](AuthorizeKey.md)s to a request payload parameter.

docs/server-authorization/UnityAccessDecorator.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,20 @@ serviceName = [serviceName], methodName = [methodName]
8484

8585
`findServiceMethod` returns the one and only `methodName` method of the `Class`, if found. Otherwise, it's undefined (`null`).
8686

87+
### Find Authorize Keys { #findAuthorizeKeys }
88+
89+
```java
90+
List<KeyLocator> findAuthorizeKeys(
91+
Method method)
92+
```
93+
94+
??? note "Static Method"
95+
`findAuthorizeKeys` is a Java **class method** to be invoked without a reference to a particular object.
96+
97+
Learn more in the [Java Language Specification]({{ java.spec }}/jls-8.html#jls-8.4.3.2).
98+
99+
`findAuthorizeKeys`...FIXME
100+
87101
### Find Authorize Expression { #findAuthorizeExpression }
88102

89103
```java

docs/server/TableService.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# TableService
22

3-
`TableService` is an API service that [UnityCatalogServer](UnityCatalogServer.md) uses to handle HTTP requests at `/api/2.1/unity-catalog/tables` URL.
3+
`TableService` is an API service of [UnityCatalogServer](UnityCatalogServer.md) to handle HTTP requests at `/api/2.1/unity-catalog/tables` URL.
44

55
Method | URL | Handler | Params
66
-|-|-|-
@@ -39,6 +39,15 @@ HttpResponse createTable(
3939
CreateTable createTable)
4040
```
4141

42+
`createTable` handles `POST` requests with the following [AuthorizeKeys](../server-authorization/AuthorizeKeys.md):
43+
44+
Value | Key
45+
-|-
46+
`SCHEMA` | `schema_name`
47+
`CATALOG` | `catalog_name`
48+
49+
---
50+
4251
`createTable` requests the system-wide [TableRepository](#TABLE_REPOSITORY) instance to [persist](../persistent-storage/TableRepository.md#createTable) the given [table metadata](CreateTable.md).
4352

4453
## List Tables { #listTables }

0 commit comments

Comments
 (0)