Create an AnalyticDB PostgreSQL public node
An AnalyticDB PostgreSQL node uses an AnalyticDB PostgreSQL cloud computing resource to process data from both AnalyticDB PostgreSQL and MaxCompute. This topic describes how to create an AnalyticDB PostgreSQL public node.
Background
Before you begin, make sure that you have created an AnalyticDB PostgreSQL cloud computing resource. For instructions, see Create a cloud computing resource.
Procedure
Log on to the Data Resource Platform console.
In the upper-left corner of the page, click the
icon and select collaboration.In the top menu bar, click the
icon, select the target workspace, and then click asset processing.NoteIf you are already on the Asset Processing page, skip clicking Asset Processing.
In the left-side navigation pane, click the
icon and select public node.Click the
icon. On the public node page, click create node.In the create node dialog box, select the AnalyticDB PostgreSQL node type and click OK.
On the node editing page, configure the following settings.
On the node properties tab on the right side of the page, specify the node identifier, node name, and node description.
Parameter
Description
node name
A customizable name for the node.
node identifier
A unique, customizable identifier for the node within the workspace.
public node version
Defaults to the development version (Beta) on creation. The version number increments with each publish.
node directory
The directory where the node is located.
node description
A description that helps users understand and find the node.
In the editor, enter an SQL statement and click the
icon.(Optional) To use a user-defined function in the SQL statement, click the reference functions tab, find the required function in the list, and then return to the editor to enter it. If the function list is empty, you must create a function first. For more information, see Create a user-defined function.
In the Confirm Node Information dialog box, verify that the node identifier, node name, and node directory are correct, and then click Confirm.
Click the runtime configuration tab on the right side of the page and select a development computing engine.
(Conditionally required) If your code contains input tables, output tables, or node variables, you must manually add the node inputs, node outputs, and node variables. Alternatively, you can click the
icon in the editor to automatically parse the inputs, outputs, and variables of the public node.The following steps demonstrate automatic parsing.
Click the
icon in the editor. The parsed inputs, outputs, and node variables are displayed on the runtime configuration tab.Turn on the
switch next to node input to view the node input.Turn on the
switch next to node output to view the node output.Specify the values for the node variables.
Parameter
Description
node input
input identifier
The identifier for the input variable. You can customize this based on the script content, for example, Input.
input data structure
The data format for the input table, defined by a data model. Select the logical table that specifies the input schema for this computing resource.
If you select a data table, ensure that its data model matches the output data model of the upstream node.
An asterisk (*) indicates an arbitrary data structure, used for operations on tables without a data model.
node output
output identifier
The identifier for the output variable. You can customize this based on the script content, for example, Output.
output data structure
The data format for the output table, defined by a data model. Select the format that specifies the output schema for this computing resource.
If you select a data table, ensure that the node's output data model matches the input data model of the downstream node.
An asterisk (*) indicates an arbitrary data structure, used for operations on tables without a data model.
node variable
variable name
The name of the algorithm variable. You can customize the name.
variable value
The value of the variable. The value must be a string.
variable description
A description of the variable.
On the node editing page, click the
icon in the upper-left corner.Click the
icon. In the node variable dialog box, verify the parameter types and default values, and then click OK.NoteIf no parameters are parsed, the node variable dialog box does not appear after you click the run icon.
View the run result and log. If the message "Current task status:SUCCESS" appears, the public node ran successfully.
Next steps
After creating the node, publish it for use in production. For instructions, see Publish a public node.