Create a MaxCompute compute source SKILL
Use natural language to instruct code agents such as Qoder and CodeX to connect a MaxCompute project to Dataphin as a compute source. This document explains this SKILL, covering its features, prerequisites, usage examples, and execution results. An appendix lists the input parameters for reference.
Overview
This SKILL lets you use natural language to connect a MaxCompute project to Dataphin as a compute source. This connection enables offline data development tasks in the project to run on the MaxCompute compute engine. A compute source provides the runtime foundation for tasks and is distinct from a data source, which is responsible for reading and writing data. You must create a compute source before you can bind it to a project.
Use cases:
-
Prepare MaxCompute compute resources for a Dataphin project, such as separate ones for development and production environments.
-
Create a new MaxCompute compute engine or bind an existing MaxCompute project to Dataphin.
-
Perform a connectivity pre-check before creating the compute source, and create it only after the check passes.
A MaxCompute project can be bound to only one Dataphin compute source, and an API to unbind it is not currently available. If a project is already in use, you must either use a different project or delete the existing compute source. For projects with development and production environment separation, you typically need to create two compute sources, one for development and one for production. Each source must point to a different MaxCompute project to ensure environment isolation.
Prerequisites
-
Your account has the necessary permissions to manage compute sources.
-
You have the MaxCompute connection information, including the service endpoint, project name, AccessKey ID, and AccessKey Secret.
Examples
You can describe your requirements to the code agent using natural language. Here are some example prompts you can copy and use:
-
Help me connect this MaxCompute project to Dataphin and create a compute source.
-
Create a MaxCompute compute engine for the project, one for development and one for production.
-
Run a connectivity pre-check before creating the compute source, and create it only if the check passes.
Interaction steps:
-
After you issue the creation command, the code agent confirms the target tenant, compute source name, type (MaxCompute), and connection configuration (service endpoint, project, and access credentials).
-
The code agent typically recommends running a connectivity pre-check first and then creating the source after the check passes.
-
Creation is a write operation. The code agent informs you of the new compute source's name, type, target tenant, connection configuration (without the key), and whether the operation can be rolled back. The agent proceeds only after you confirm.
-
For projects that require development and production environment separation, the code agent typically creates two compute sources, one for development and one for production, each pointing to a different MaxCompute project.
Execution results
The operation returns the following results:
-
Response: A successful creation returns the ID of the new compute source.
-
Completion status: A successful command response indicates that the request was accepted. The code agent typically verifies the creation by querying the compute source list by name. If necessary, it may perform an additional connectivity check using the ID.
-
Verification: You can view the new compute source in the compute source list in the Dataphin console and confirm its connection status.
A successful command-line response only indicates that the request was accepted. The final status is displayed in the Dataphin console.
Appendix: Input parameters
The following table lists the parameters for creating a MaxCompute compute source. This list is for reference. In practice, the code agent automatically identifies the required information from your instructions and prompts for any missing details. You do not need to provide system-generated parameters.
|
Parameter |
Required |
Description |
Example |
|
Tenant ID |
Yes |
The ID of the target Dataphin tenant. It is a 19-digit number. |
1234567890123456789 |
|
Compute source name |
Yes |
The name of the compute source. It can contain letters, numbers, and underscores (_). |
mc_prod_compute |
|
Compute source description |
No |
A description of the compute source's purpose. This can be left blank. |
Production environment MaxCompute compute source |
|
Service endpoint |
Yes |
The endpoint of the MaxCompute service. |
http://service.cn-shanghai.maxcompute.aliyun.com/api |
|
Project name |
Yes |
The name of the MaxCompute project. It must be consistent with the name in the MaxCompute console. |
my_project |
|
Access credentials |
Yes |
The AccessKey ID and AccessKey Secret required to access MaxCompute. |
— |