湖仓构建 LAKEFORMATION-基于策略授权的服务授权项:LakeFormation LakeCat API

时间:2024-10-22 17:23:05

LakeFormation LakeCat API

您可以在自定义策略语句的Action元素中指定LakeFormation LakeCat API相关操作。详细操作如表3所示。

表3 LakeFormation支持的操作项

操作项

描述

访问级别

资源类型(*为必须)

条件键

lakeformation:function:describe

查询LakeFormation元数据的函数的权限。

read

-

-

lakeformation:function:drop

删除LakeFormation元数据的函数的权限。

write

-

-

lakeformation:function:alter

修改LakeFormation元数据的函数的权限。

write

-

-

lakeformation:function:create

创建LakeFormation元数据的函数的权限。

write

-

-

lakeformation:catalog:describe

查询LakeFormation元数据的数据目录的权限。

read

-

-

lakeformation:catalog:create

创建LakeFormation元数据的数据目录的权限。

write

-

-

lakeformation:catalog:alter

修改LakeFormation元数据的数据目录的权限。

write

-

-

lakeformation:catalog:drop

删除LakeFormation元数据的数据目录的权限。

write

-

-

lakeformation:database:describe

查询LakeFormation元数据的数据库的权限。

read

-

-

lakeformation:database:create

创建LakeFormation元数据的数据库的权限。

write

-

-

lakeformation:database:alter

修改LakeFormation元数据的数据库的权限。

write

-

-

lakeformation:database:drop

删除LakeFormation元数据的数据库的权限。

write

-

-

lakeformation:table:describe

查询LakeFormation元数据的数据表的权限。

read

-

-

lakeformation:table:alter

修改LakeFormation元数据的数据表的权限。

write

-

-

lakeformation:table:create

创建LakeFormation元数据的数据表的权限。

write

-

-

lakeformation:table:drop

删除LakeFormation元数据的数据表的权限。

write

-

-

lakeformation:transaction:operate

操作LakeFormation事务的权限。

write

-

-

lakeformation:user:describe

查询LakeFormation用户以及关联角色关系的权限。

read

-

-

lakeformation:policy:create

创建LakeFormation权限策略的权限。

write

-

-

lakeformation:policy:export

批量查询LakeFormation权限策略的权限。

read

-

-

lakeformation:policy:drop

删除LakeFormation权限策略的权限。

write

-

-

lakeformation:policy:describe

查询LakeFormation权限策略的权限。

read

-

-

lakeformation:group:describe

查询LakeFormation用户组以及关联角色关系的权限。

read

-

-

lakeformation:group:alter

修改LakeFormation用户组以及关联角色关系的权限。

write

-

-

lakeformation:instance:describe

查询LakeFormation实例的权限。

read

-

-

lakeformation:role:create

创建LakeFormation角色的权限。

write

-

-

lakeformation:role:describe

查询LakeFormation角色的权限。

read

-

-

lakeformation:role:drop

删除LakeFormation角色的权限。

write

-

-

lakeformation:role:alter

修改LakeFormation角色以及关联用户组关系的权限。

write

-

-

lakeformation:credential:describe

获取访问LakeFormation认证信息的权限。

read

-

-

lakeformation:configuration:describe

查询用户配置的权限。

read

-

-

lakeformation:user:alter

修改LakeFormation用户以及关联角色关系的权限。

write

-

-

lakeformation:tableFile:alter

修改文件的权限。

write

-

-

lakeformation:tableFile:describe

查询文件的权限。

read

-

-

lakeformation:tableFile:drop

删除文件的权限。

write

-

-

lakeformation:tableFile:create

创建文件的权限。

write

-

-

lakeformation:tableFileGroup:create

创建文件组的权限。

write

-

-

lakeformation:tableFileGroup:describe

查询文件组的权限。

read

-

-

lakeformation:tableFileGroup:alter

修改文件组的权限。

write

-

-

lakeformation:tableFileGroup:drop

删除文件组的权限。

write

-

-

lakeformation:metadata:restore

恢复元数据的权限。

write

-

-

lakeformation:metadataEvent:describe

查询元数据事件的权限。

read

-

-

LakeFormation LakeCat API通常对应着一个或多个操作项。表4展示了API与操作项的关系,以及该API需要依赖的操作项。

表4 API与操作项的关系

API

对应的操作项

依赖的操作项

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/functions

lakeformation:function:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions/names

lakeformation:function:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions/{function_name}

lakeformation:function:describe

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions/{function_name}

lakeformation:function:drop

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions/{function_name}

lakeformation:function:alter

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions

lakeformation:function:create

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/functions

lakeformation:function:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs

lakeformation:catalog:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs

lakeformation:catalog:create

-

PUT /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}

lakeformation:catalog:alter

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}

lakeformation:catalog:drop

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}

lakeformation:catalog:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases

lakeformation:database:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases

lakeformation:database:create

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}

lakeformation:database:describe

-

PUT /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}

lakeformation:database:alter

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}

lakeformation:database:drop

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/names

lakeformation:database:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/tables

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/list-by-names

lakeformation:table:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables

lakeformation:table:create

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}

lakeformation:table:describe

-

PUT /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}

lakeformation:table:alter

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}

lakeformation:table:drop

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/names

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/column-statistics/batch-get

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/column-statistics

lakeformation:table:alter

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/column-statistics

lakeformation:table:alter

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/batch-alter

lakeformation:table:alter

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/batch-create

lakeformation:table:alter

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/batch-drop

lakeformation:table:alter

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/batch-get

lakeformation:table:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/partition-names

lakeformation:table:describe

-

GET /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/names

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/column-statistics/batch-get

lakeformation:table:describe

-

POST /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/column-statistics

lakeformation:table:alter

-

DELETE /v1/{project_id}/instances/{instance_id}/catalogs/{catalog_name}/databases/{database_name}/tables/{table_name}/partitions/column-statistics

lakeformation:table:alter

-

GET /v1/{project_id}/instances/{instance_id}/users

lakeformation:user:describe

-

POST /v1/{project_id}/instances/{instance_id}/policies/grant

lakeformation:policy:create

-

GET /v1/{project_id}/instances/{instance_id}/policies/policy

lakeformation:policy:export

-

POST /v1/{project_id}/instances/{instance_id}/policies/revoke

lakeformation:policy:drop

-

GET /v1/{project_id}/instances/{instance_id}/policies/show

lakeformation:policy:describe

-

GET /v1/{project_id}/instances/{instance_id}/policies

lakeformation:policy:export

-

GET /v1/{project_id}/instances/{instance_id}/groups

lakeformation:group:describe

-

-

lakeformation:group:alter

-

-

lakeformation:group:alter

-

-

lakeformation:group:alter

-

-

lakeformation:group:describe

-

POST /v1/{project_id}/instances/{instance_id}/metaobj/count

lakeformation:instance:describe

-

POST /v1/{project_id}/instances/{instance_id}/roles

lakeformation:role:create

-

GET /v1/{project_id}/instances/{instance_id}/roles

lakeformation:role:describe

-

DELETE /v1/{project_id}/instances/{instance_id}/roles/{role_name}

lakeformation:role:drop

-

GET /v1/{project_id}/instances/{instance_id}/roles/{role_name}

lakeformation:role:describe

-

PUT /v1/{project_id}/instances/{instance_id}/roles/{role_name}

lakeformation:role:alter

-

GET /v1/{project_id}/instances/{instance_id}/roles/names

lakeformation:role:describe

-

GET /v1/{project_id}/instances/{instance_id}/roles/{role_name}/principals

lakeformation:role:describe

-

POST /v1/{project_id}/instances/{instance_id}/roles/{role_name}/grant-principals

lakeformation:role:alter

-

POST /v1/{project_id}/instances/{instance_id}/roles/{role_name}/revoke-principals

lakeformation:role:alter

-

PUT /v1/{project_id}/instances/{instance_id}/roles/{role_name}/update-principals

lakeformation:role:alter

-

POST /v1/{project_id}/instances/{instance_id}/credential

lakeformation:credential:describe

-

GET /v1/{project_id}/instances/{instance_id}/configurations

lakeformation:configuration:describe

-

POST /v1/{project_id}/instances/{instance_id}/users/{user_name}/grant-roles

lakeformation:user:alter

-

POST /v1/{project_id}/instances/{instance_id}/users/{user_name}/revoke-roles

lakeformation:user:alter

-

PUT /v1/{project_id}/instances/{instance_id}/users/{user_name}/update-roles

lakeformation:user:alter

-

GET /v1/{project_id}/instances/{instance_id}/users/{user_name}/roles

lakeformation:user:describe

-

POST /v1/{project_id}/instances/{instance_id}/policies/check-permission

lakeformation:policy:describe

-

-

lakeformation:metadata:restore

-

GET /v1/{project_id}/instances/{instance_id}/metadata-event

lakeformation:metadataEvent:describe

-

support.huaweicloud.com/api-lakeformation/lakeformation_04_0031.html