All Products
Search
Document Center

Dataphin:Create a KingbaseES data source

Last Updated:Jun 23, 2026

Create a KingbaseES data source to enable Dataphin to read business data from or write data to KingbaseES.

Permission requirements

Only custom global roles with the Create Data Source permission and system roles such as super administrator, data source administrator, Domain Architect, and project administrator can create data sources.

Procedure

  1. On the Dataphin homepage, choose Management Hub > Datasource Management from the top menu bar.

  2. On the Datasource page, click +Create Data Source.

  3. On the Create Data Source page, select KingbaseES from the Relational Database section.

    You can also select KingbaseES from the Recently Used section or search for it by keyword.

  4. On the Create KingbaseES Data Source page, configure the connection parameters for the data source.

    1. Configure the basic information for the data source.

      Parameter

      Description

      Data Source Name

      The name must meet the following requirements:

      • It can contain only Chinese characters, letters, digits, underscores (_), and hyphens (-).

      • It can be up to 64 characters long.

      Datasource Code

      Once configured, you can reference tables in Flink_SQL nodes using the format datasource_code.table_name or datasource_code.schema.table_name. To access the data source in the corresponding environment automatically, use the variable format ${datasource_code}.table or ${datasource_code}.schema.table. For more information, see Dataphin data source table development methods and .

      Important
      • The data source code cannot be modified after it is configured.

      • You can preview data on the object details page in the asset directory and asset checklist only after the data source code is configured.

      • In Flink SQL, only MySQL, Hologres, MaxCompute, Oracle, StarRocks, Hive, SelectDB, and GaussDB data warehouse service (DWS) data sources are currently supported.

      Version

      The supported versions are V8R3, V8R6, and V9R1.

      Data Source Description

      Description for the KingbaseES data source. Maximum 128 characters.

      Data Source Configuration

      Based on whether your business data source uses separate production and development environments:

      • If your business data source uses separate environments, select Production + Development Data Source.

      • If your business data source does not use separate environments, select Production Data Source.

      Tags

      You can add tags to the data source for categorization. For more information about how to create tags, see Manage data source tags.

    2. Configure the connection parameters.

      If you set Data Source Configuration to Production + Development Data Source, you must configure connection information for both environments. If you set it to Production Data Source, you only need to configure connection information for the production data source.

      Note

      We recommend configuring production and development as separate data sources to isolate environments. However, Dataphin supports using the same data source with identical parameter values for both.

      Set Configuration Method to JDBC URL or Host. The default is JDBC URL.

      JDBC URL configuration method

      Parameter

      Description

      JDBC URL

      The format of the connection URL is jdbc:kingbase8://host:port/dbname. Example: jdbc:kingbase8//192.168.*.212:54321/dataphin.

      Schema

      The database name in the KingbaseES instance. You can find it on the data management page of the instance.

      Username and Password

      The username and password for logging on to the database.

      Host configuration method
      • Host configuration method

        Parameter

        Description

        Server Address

        Enter the IP address and port number of the server.

        Click +Add to add multiple IP addresses and port numbers. Click the image icon to delete extra entries. You must keep at least one entry.

        dbname

        Enter the database name.

      • Parameter configuration

        Parameter

        Description

        Parameter

        • Parameter name: Select an existing parameter name or enter a custom parameter name.

          Custom parameter names can contain only letters, digits, periods (.), underscores (_), and hyphens (-).

        • Parameter value: This is required if a parameter name is selected. The value can contain only letters, digits, periods (.), underscores (_), and hyphens (-), and can be up to 256 characters long.

        Note

        Click +Add Parameter to add multiple parameters. Click the image icon to delete extra parameters. You can add a maximum of 30 parameters.

        Username, Password

        The username and password for logging on to the KingbaseES database.

      Note

      If you create a data source using the Host configuration method and later switch to the JDBC URL method, the system concatenates the server IP address and port number to populate the JDBC URL field.

    3. Configure the advanced settings.

      Parameter

      Description

      socketTimeout

      The socket timeout period for the database, in seconds. The default is 1800 seconds (30 minutes).

      Note
      • If you configure socketTimeout in the JDBC URL, the value from the JDBC URL is used.

      • For data sources created before Dataphin V3.11, the default socketTimeout is -1, which indicates no timeout.

      connectTimeout

      The connection timeout period for the database, in seconds. The default is 900 seconds (15 minutes).

      Note
      • If you configure connectTimeout in the JDBC URL, the value from the JDBC URL is used.

      • For data sources created before Dataphin V3.11, the default connectTimeout is -1, which indicates no timeout.

      Connection Retries

      The number of automatic retry attempts when a database connection times out. If all retries fail, the connection attempt fails.

      Note
      • The default number of retries is 1. You can set this parameter to a value from 0 to 10.

      • The number of connection retries applies by default to offline integration nodes and global quality checks. The Asset Quality module must be enabled for global quality checks. You can configure the number of retries for each offline integration node.

    Note

    Parameter precedence:

    • If a parameter is defined in the JDBC URL, Advanced Settings, and Host Configuration sections, the value from the JDBC URL is used.

    • If a parameter is defined in both the JDBC URL and Advanced Settings sections, the value from the JDBC URL is used.

    • If a parameter is defined in both the Advanced Settings and Host Configuration sections, the value from Advanced Settings is used.

  5. Select a Default Resource Group. This resource group is used to run tasks related to the data source, such as database SQL queries, offline full-database migrations, and data previews.

  6. Click Test Connection, or click OK to save the configuration and create the KingbaseES data source.

    Clicking Test Connection verifies connectivity to Dataphin. Clicking OK saves the configuration and automatically tests the connection for all selected clusters. The data source is created even if connection tests fail.