Queries compute engine instances.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ListCalcEngines

The operation that you want to perform.

CalcEngineType String Yes ODPS

The type of the compute engine instance. Valid values: ODPS, EMR, BLINK, HOLO, MaxGraph, HYBRIDDB_FOR_POSTGRESQL, ADB_MYSQL, and HADOOP_CDH. The values are not case-sensitive.

Name String Yes abc

The name of the compute engine instance, which must be exactly matched.

ProjectId Long Yes 27

The DataWorks workspace to which the compute engine instance is bound.

RegionId String Yes cn-shanghai

The region ID of the compute engine instance. For example, the ID of the China (Shanghai) region is cn-shanghai, and that of the China (Zhangjiakou) region is cn-zhangjiakou. The system automatically determines the value of this parameter based on the endpoint that is used to call the operation.

EnvType String No PRD

The environment in which the compute engine instance runs. Valid values: DEV and PRD. The value DEV indicates the development environment. The value PRD indicates the production environment.

PageSize Integer No 10

The number of entries to return on each page. Default value: 10. Maximum value: 20.

PageNumber Integer No 1

The number of the page to return. Valid values: a positive integer greater than or equal to 1. Default value: 1.

Response parameters

Parameter Type Example Description
Data Struct

The query results for compute engine instances that are returned on multiple pages.

CalcEngines Array of CalcEngines

The list of compute engine instances.

BindingProjectId Integer 27

The ID of the workspace to which the compute engine instance is bound.

BindingProjectName String abc

The name of the workspace to which the compute engine instance is bound.

CalcEngineType String ODPS

The type of the compute engine instance. Valid values: ODPS, EMR, BLINK, HOLO, MaxGraph, HYBRIDDB_FOR_POSTGRESQL, ADB_MYSQL, and HADOOP_CDH

DwRegion String cn-zhangjiakou

The region of the DataWorks workspace to which the compute engine instance is bound.

EngineId Integer 35

The ID of the compute engine instance.

EngineInfo Map {"pubEndpoint":"http://service.cn.maxcompute.aliyun.com/api","endpoint":"http://service.cn.maxcompute.aliyun-inc.com/api","resourceGroupType":"ODPS","resourceGroupId":"361826516****","vpcEndpoint":"http://service.cn.maxcompute.aliyun-inc.com/api","projectName":"onefall_test_zjk","taskSameAsOwner":"true"}

The details of the compute engine instance.

  • ODPS
    
    {
      "pubEndpoint": "service.cn.maxcompute.aliyun.com/api",
      "endpoint": "service.cn.maxcompute.aliyun-inc.com/api",
      "resourceGroupType": "ODPS",
      "resourceGroupId": "361826516****",
      "vpcEndpoint": "service.cn.maxcompute.aliyun-inc.com/api",
      "projectName": "onefall_test_zjk",
      "taskSameAsOwner": "true"
    }
                                            
  • EMR

{
  "emrClusterId": "C-xxx",
  "specs": "{\"emrClusterId\":\"C-xxx\",\"emrAccessMode\":\"simple\",\"emrResourceQueueName\":\"default\",\"emrProjectId\":\"FP-xxx\"}",
  "endpoint": "emr.aliyuncs.com",
  "emrResourceQueueName": "default",
  "emrAccessMode": "simple",
  "resourceGroupType": "DW",
  "projectName": "xx-xxxx",
  "emrProjectId": "FP-xxxx",
  "taskSameAsOwner": "false"
}       
                                
  • BLINK

{
  "bayesProjectId": "xxxx",
  "bayesProjectName": "xc_blxxixxxnk_1",
  "cluster": "xxxssxsx",
  "endpoint": "https://stream.console.aliyun.com",
  "engineType": "BLINK",
  "name": "xsxsxxxxx",
  "projectName": "xc_blxxxsxink_1",
  "queue": "root.xc_blxsxxxxxxink_1",
  "resourceGroupType": "DW",
  "specs": "{\"cluster\":\"xxxxxx\",\"bayesProjectName\":\"xc_blxxixxxnk_1\",\"bayesProjectId\":\"ssxxxsa\",\"name\":\"sxsxsxxx\",\"queue\":\"root.sxxsxxsx\"}",
  "taskSameAsOwner": false
}
                                
  • HOLO

{
  "endpoint": "hgprecn-cn-xsxssxsx-cn-shanghai-internal.hologres.aliyuncs.com:80",
  "engineType": "ODPS",
  "odpsEndpoint": "hgprecn-cn-xsxssxxs-cn-shanghai-internal.hologres.aliyuncs.com:80",
  "odpsProjectName": "xsxssxsxsx",
  "projectName": "xsxssxsxsx",
  "resourceGroupType": "DW",
  "specs": "{\"pubEndpoint\":\"hgprecn-cn-xsxssxsxs-cn-shanghai.hologres.aliyuncs.com:80\",\"commonBuyInstanceId\":\"hgprecn-cn-xsxsxsxs\",\"project\":\"holo_upxsxgrade1\",\"common_buy_instance_id\":\"hgprecn-cn-xsxsxs\",\"endpoint\":\"hgprecn-cn-xsxxsxs-cn-shanghai-internal.hologres.aliyuncs.com:80\",\"port\":\"80\",\"host\":\"hgprecn-cn-xsxsxsxs-cn-shanghai-internal.hologres.aliyuncs.com\",\"vpcEndpoint\":\"hgprecn-cn-xsxsxsxs-cn-shanghai-vpc.hologres.aliyuncs.com:80\",\"authType\":2,\"region\":\"cn-shanghai\"}",
  "taskSameAsOwner": false
}
                                
  • MaxGraph

{
  "endpoint": "http://pre-graphcompute.aliyuncs.com",
  "engineType": "ODPS",
  "odpsEndpoint": "http://pre-graphcompute.aliyuncs.com",
  "odpsProjectName": "xsxsxsxs",
  "projectName": "xsxsxsxs",
  "resourceGroupType": "DW",
  "taskSameAsOwner": false
}
                                
  • HYBRIDDB_FOR_POSTGRESQL

{
  "endpoint": "hybriddb_for_postgresql_mo12121ck_endpoint",
  "engineType": "ODPS",
  "odpsEndpoint": "hybriddb_for_postgresql_m121212ock_endpoint",
  "odpsProjectName": "sxasaxsaxaxas",
  "projectName": "sxasaxsaxaxas",
  "resourceGroupType": "DW",
  "specs": "{\"connectionString\":\"gp-xsxsxsxxs.gpdb.rds.aliyuncs.com\",\"database\":\"xsxsxxsxs\",\"password\":\"xxxxxxx\",\"instanceId\":\"gp-cdcdacdacda\",\"port\":\"3432\",\"ownerId\":\"12121212\",\"username\":\"sdasaddsa\"}",
  "taskSameAsOwner": false
}
                                
  • ADB_MYSQL

{
  "endpoint": "adb_mysql_mock_endpoint",
  "engineType": "ODPS",
  "odpsEndpoint": "adb_mysql_mock_endpoint",
  "odpsProjectName": "am-xsaxaxa",
  "projectName": "am-xsxsaxa",
  "resourceGroupType": "DW",
  "specs": "{\"connectionString\":\"am-xsaxsa.ads.aliyuncs.com:3306\",\"database\":\"xsaxsaxa\",\"password\":\"xsaxsaxassxsa\",\"instanceId\":\"am-xsaxsasx\",\"username\":\"xsaxsadsd\"}",
  "taskSameAsOwner": false
}
                                
  • HADOOP_CDH

{
  "bindingBaseId":
  "xsaxsaxs",
  "endpoint": "xsaaaaa",
  "engineType":
  "ODPS",
  "odpsEndpoint": "axsxaxssxs",
  "odpsProjectName":
  "ssxxax",
  "projectName": "xsaxsaxsa",
  "resourceGroupId":
  45208xxxxxx,
  "resourceGroupType": "GATEWAY",
  "specs":
  "{\"cluster\":{\"hive\":{\"hiveServer2Url\":\"jdbc:hive2://xxxxxxer-1-cn-shanghai-pre-kerberos-1:10000\",\"hiveMetastore\":\"thrift://xxxxxxxr-1-cn-shanghai-pre-kerberos-1:9083\",\"version\":\"2.1.1\"},\"configFiles\":{\"coreSite\":\"4534574xxxxxx\",\"hdfsSite\":\"453457919xxxxxxx\",\"mapredSite\":\"45345750xxxxxx\",\"yarnSite\":\"4534575xxxxx\",\"krb5Conf\":\"4534576xxxxx1\",\"hiveSite\":\"453457xxxxx20\"},\"spark\":{\"version\":\"2.4.0\"},\"cdh\":{\"version\":\"6.3.2\"},\"hdfs\":{\"version\":\"3.0.0\"},\"impala\":{\"impalaUrl\":\"jdbc:impala://cdh-xsxssxxsx-1-cn-shanghai-pre-kerberos-1:21050\",\"version\":\"3.2.0\"},\"yarn\":{\"YarnUrl\":\"http://cdh-xsxsxsxsxs-1-cn-shanghai-pre-kerberos-1:8032\",\"webUrl\":\"http://cdh-xsxsxssxxssx-1-cn-shanghai-pre-kerberos-1:8088\",\"version\":\"3.0.0\"},\"presto\":{\"prestoUrl\":\"jdbc:presto://cdh-xssxsxxsxsxs-1-cn-shanghai-pre-kerberos-1:8080/hive/default\",\"version\":\"0.244.1\"}},\"instanceId\":161sdads733,\"authDetail\":{\"principal\":\"hive@HADOOP.COM\",\"keytabFileId\":\"45345815xsxsxs3\",\"type\":\"kerberos\",\"username\":\"xsxsxsxsa@HADOOP.COM\"},\"resGroupStatus\":\"\",\"hadoopAuthType\":\"kerberos\",\"clusterIdentifier\":\"xssxsxsxsx\",\"clusterId\":xsxsx,\"resGroupId\":4520870619xsxssxxs,\"accessMode\":\"security\",\"authType\":2}",
  "taskSameAsOwner": false
}  
                                
EnvType String PRD

The environment in which the compute engine instance runs. Valid values:

  • DEV: development environment
  • PRD: production environment
GmtCreate String Oct 10, 2019 3:42:44 PM

The time when the compute engine instance was created. It is a timestamp.

IsDefault Boolean true

Indicates whether the compute engine instance is the default instance of the same type.

Name String abc

The display name of the compute engine instance.

Region String cn-zhangjiakou

The region where the compute engine instance resides.

TaskAuthType String PROJECT

The identity that is assigned to access the compute engine instance. Valid values:

  • USER: current user
  • PROJECT: project executor
  • SUBACCOUNT: sub-account
  • STS_ROLE: STS role
TenantId Long 1234567

The ID of the tenant.

PageNumber Integer 1

The page number of the returned page.

PageSize Integer 20

The number of entries returned per page. Default value: 10. Maximum value: 100.

TotalCount Integer 1

The total number of compute engine instances.

HttpStatusCode Integer 200

The HTTP status code returned.

RequestId String 0bc1ec92159376****

The ID of the request.

Success Boolean true

Indicates whether the request to query compute engine instances is successful.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListCalcEngines
&CalcEngineType=ODPS
&Name=abc
&ProjectId=27
&RegionId=cn-shanghai
&<Common request parameters>

Sample success responses

XML format

<data>
    <calcEngines>
        <bindingProjectId>27</bindingProjectId>
        <bindingProjectName>abc</bindingProjectName>
        <calcEngineType>ODPS</calcEngineType>
        <dwRegion>cn-zhangjiakou</dwRegion>
        <engineId>35</engineId>
        <engineInfo>
            <pubEndpoint>http://service.cn.maxcompute.aliyun.com/api</pubEndpoint>
            <endpoint>http://service.cn.maxcompute.aliyun-inc.com/api</endpoint>
            <resourceGroupType>ODPS</resourceGroupType>
            <resourceGroupId>361826516****</resourceGroupId>
            <vpcEndpoint>http://service.cn.maxcompute.aliyun-inc.com/api</vpcEndpoint>
            <projectName>abc</projectName>
            <taskSameAsOwner>true</taskSameAsOwner>
        </engineInfo>
        <envType>PROD</envType>
        <gmtCreate>Oct 10, 2019 3:42:44 PM</gmtCreate>
        <isDefault>true</isDefault>
        <name>abc</name>
        <region>cn-zhangjiakou</region>
        <taskAuthType>PROJECT</taskAuthType>
        <tenantId>1234567</tenantId>
    </calcEngines>
    <pageNumber>1</pageNumber>
    <pageSize>20</pageSize>
    <totalCount>1</totalCount>
</data>
<httpStatusCode>200</httpStatusCode>
<requestId>0bc1ec92159376****</requestId>
<success>true</success>

JSON format

{
    "data": {
        "calcEngines":
        [
            {
                "bindingProjectId": 27,
                "bindingProjectName":
            "abc",
                "calcEngineType":
                "ODPS",
                "dwRegion": "cn-zhangjiakou",
                "engineId":
                35,
                "engineInfo": {
                    "pubEndpoint":
                "http://service.cn.maxcompute.aliyun.com/api",
                    "endpoint": "http://service.cn.maxcompute.aliyun-inc.com/api",
                    "resourceGroupType":
                "ODPS",
                    "resourceGroupId": "361826516****",
                    "vpcEndpoint":
                "http://service.cn.maxcompute.aliyun-inc.com/api",
                    "projectName": "abc",
                    "taskSameAsOwner":
                "true"
                },
                "envType": "PROD",
                "gmtCreate":
                    "Oct 10, 2019 3:42:44 PM",
                "isDefault": true,
                "name": "abc",
                "region":
                    "cn-zhangjiakou",
                "taskAuthType": "PROJECT",
                "tenantId":
                    1234567
            }
        ],
        "pageNumber": 1,
        "pageSize":
                    20,
        "totalCount": 1
    },
    "httpStatusCode":
                    200,
    "requestId": "0bc1ec92159376****",
    "success": true
}

Error codes

HTTP status code Error code Error message Description
400 Invalid.Tenant.ConnectionNotExists The connection does not exist. The error message returned because the specified data source does not exist.
400 Invalid.Tenant.ProjectNotExists The project does not exist. The error message returned because the specified project does not exist.
403 Invalid.Tenant.UserIsNotProjectOwnerOrAdmin The user is not a project administrator or owner. The error message returned because the user is not the project owner or project administrator.
400 Invalid.Tenant.UserNotInProject The user is not in the project. The error message returned because the user is not added to the project.
403 Invalid.Tenant.UserNotInTenant The user is not in tenant. The error message returned because the user does not belong to the tenant.

For a list of error codes, visit the API Error Center.