This topic describes how a RAM user can use Resource Orchestration Service to query information about an ApsaraDB for ClickHouse cluster.
Prerequisites
You need a RAM user to use Resource Orchestration Service. Create a RAM user and grant it the following permissions.
-
Full access to Resource Orchestration Service:
AliyunROSFullAccess. -
Full access to ApsaraDB for ClickHouse:
AliyunClickHouseFullAccess.NoteFor demonstration purposes, this example uses the
AliyunClickHouseFullAccesspolicy. In a production environment, grant permissions based on your business requirements and the principle of least privilege. For more information about ApsaraDB for ClickHouse permission policies, see Identity-based policies.
Procedure
-
Log on to the ROS console. In the top navigation bar, select your desired region from the region drop-down list.
-
In the left-side navigation pane, click Stack, and then choose .
-
Specify Template: Select Select an Existing Template.
-
Template Import Method: Select Enter Template Content.
-
-
In the Template content section, select ROS and enter the template code.
The following code is a template for a ROS data source that queries information about ApsaraDB for ClickHouse clusters. For more details, see DATASOURCE::ClickHouse::DBClusters.
-
Click Next.
-
On the Create Stack page, configure the following parameters.
For demonstration purposes, only the required parameters for this example are listed. For more information about the parameters for creating a stack, see Create a stack by using an existing template.
Parameter
Required
Description
Example
Stack Name
Yes
The name of the stack.
getClickHouseInfoTestDBClusterId
Yes
The cluster ID.
cc-bp1gf42v00340****
DBClusterName
Yes
The cluster name.
testROS
-
Click create one..
After the stack is created, its Status on the Stack Information tab changes to Create successful.
-
After the stack is created successfully, click the Outputs tab to view the cluster details.