This topic describes how to create a custom node type. To create a custom node type, you must configure the basic information, specify a wrapper, and set code editor and interaction parameters.

Prerequisites

DataWorks Enterprise Edition or higher is activated.

Procedure

  1. Go to the Custom Node Types tab.
    1. Log on to the DataWorks console.
    2. In the left-side navigation pane, click Workspaces.
    3. In the top navigation bar, select the region where the target workspace resides. Find the target workspace and click Data Analytics in the Actions column.
    4. On the DataStudio page, click Node Config in the top navigation bar. The Node Plugin list tab appears by default.
    5. In the left-side navigation pane, click Custom Node Types.
  2. On the Custom Node Types tab, click Create in the upper-right corner. The Configure Custom Node Type page appears.
  3. In the Basic Information section, set relevant parameters.
    Basic Information section
    Parameter Description
    Name The name of the custom node type. Make sure that the name is unique. The name must start with a letter and can contain letters and spaces.
    Icon The icon of the custom node type. Select an icon from the drop-down list.
    Tabs The services where the custom node type can be used. Valid values: Temporary query, Manual business process, and Data Development.
    Description The description of the custom node type.
    Usage Notes The usage notes of the custom node type. You can modify the default usage notes as required.
  4. In the Wrapper section, set the Plug-in type and Wrapper parameters.
    The Plug-in type parameter specifies the type of wrapper to be associated with the node type. Valid values:
    • Engine type: If you select this type, you must select a wrapper whose functionality is defined by using a code package, for example, a JAR package. Generally, a wrapper of this type is applicable to a node type that uses a custom compute engine.
    • Business type: If you select this type, you must select a wrapper whose functionality is defined by using a manually triggered workflow. Generally, a wrapper of this type is used to encapsulate multiple nodes to implement specific business logic.
  5. In the Editor settings section, set relevant parameters.
    Editor settings section
    Parameter Description
    Editor Type The type of the editor that is supported by the custom node type. Valid values: Editor Only and Data Source Selection Section and Editor
    Use MaxCompute as Engine Specifies whether to use MaxCompute as the compute engine. If your wrapper uses MaxCompute as the compute engine, select Yes. In other scenarios, select No.
    Note This parameter is available only when Editor Type is set to Editor Only.
    Connection Type The type of connections that are supported by the custom node type. You can select one or more types from the drop-down list. Only connections that are created by using URLs are supported.
    Note This parameter is available only when Editor Type is set to Data Source Selection Section and Editor.
    Editor Language The type of programming language that is supported by the custom node type. Valid values: ODPS SQL, JSON, Shell, Python, MySQL, XML, and YAML.
    Code Template The code template of the custom node type. You can use the ${author} and {createTime} variables in a code template, which indicate the creator and creation time of the template, respectively.
    Advanced Settings Specifies whether to configure a template for the runtime parameters of nodes of this type.
    Parameter Template The template of the runtime parameters of nodes of this type.
    Note This parameter is available only when the Advanced Settings check box is selected.
    Node Chinese Tips The tips that help users write code in the code editor. The tips are planned to appear in the upper-right corner of the code editor. The tips can be up to 256 characters in length.
    Node English Tips
  6. In the Interaction section, set relevant parameters.
    Interaction section
    Parameter Description
    Shortcut Menu
    • The options to appear in the shortcut menu. By default, the following operations are selected: Rename, Move, Clone, Steal Lock, View Versions, Locate in Operation Center, Delete, and Submit for Review.
    • More options include Edit, Copy Resource Name, and Send to DataWorks Desktop (Shortcut).
    Tool Bar
    • The options to appear in the toolbar. By default, the following options are selected: Save, Commit, Commit and Unlock, Steal Lock, Run, Show/Hide, Run with Arguments, Stop, Reload, Run Smoke Test in Development Environment, View Smoke Test Log in Development Environment, Run Smoke Test, View Smoke Test Log, Go to Operation Center of Development Environment, and Format.
    • More options include Operation Center, Deploy, and Precompile.
    Right-Side Bar
    • The tabs to appear on the right-side navigation pane of the code editor. By default, the Scheduling configuration and Structure options are selected.
    • More options include Version, Lineage, and Parameters.
    Auto Parse Option Specifies whether to display the Automatic parsing parameter for this type of nodes. If you turn on this switch, the Automatic parsing parameter is displayed on the Scheduling configuration tab of this type of nodes. Otherwise, this parameter is not displayed. In an automatic parsing process, the system parses the input and output of a node based on the lineage that is specified in the code.
  7. Click Save and Exit. The custom node type appears on the Custom Node Types tab.
    In the Tabs column, you can select one or more services where the custom node type can be used based on your needs. Valid values are Data Development, Manual business process, and Temporary query.Custom Node Types tab
    In the Actions column, you can click Change or Delete to edit or delete the custom node type. Only the owner of the current workspace or the creator of the custom node type can perform these operations.
    • Change: You can click Change to go to the Configure Custom Node Type page. On this page, you can modify the configurations of the custom node type based on your needs.
    • Delete: If no nodes of this custom node type are in the Deployed state, you can delete the custom node type. If a node of this custom node type is in the Deployed state, an error message appears after you click Delete. You must undeploy the node before you delete the custom node type.