Updated on 2026-11-20 GMT+08:00

Managing a Metadata Task

During enterprise data asset management, gaining a complete understanding of database asset distribution and managing data through classification and grading are essential to data security governance. However, enterprise databases often contain numerous instances, tables, and views. Traditional manual sorting is labor-intensive, prone to omissions, and frequently lags behind, making it hard to meet compliance requirements for timely and accurate asset inventories. You can create a metadata task in DSC to connect to databases and fetch instances, tables, and views. After the task completes, you can view data details on the pivot table page and configure descriptions, tags, security levels, and categories to implement effective data classification and grading.

Authorizing database assets in the asset center will automatically enable metadata tasks. In the asset list on the asset management page, the Metadata Task column displays the metadata task status.

Prerequisites

DSC has been allowed to access the database assets. For details, see Allowing or Disallowing Access to Cloud Assets.

Data Sources That Support Metadata Task Creation

Metadata tasks can be created for the following data sources: MySQL, TDSQL, PostgreSQL, Dameng, Kingbase, GaussDB, DWS, Hive, and MRS_HIVE.

Creating a Metadata Scanning Task

  1. Log in to the DSC console.
  2. Click in the upper left corner and select a region or project.
  3. In the navigation pane on the left, choose Asset Center > Asset Management.
  4. Click the Metadata Tasks tab and click Create in the upper left corner. On the Create Collection Task page that is displayed, configure data source. For details about the parameters, see Table 1.

    Table 1 Parameter description

    Parameter

    Description

    Data Source

    Select a data source.

    Metadata tasks can be created for the following data sources: MySQL, TDSQL, PostgreSQL, Dameng, Kingbase, GaussDB, DWS, Hive, and MRS_HIVE.

    Database Instance

    Select an authorized database instance from the drop-down list.

    Add Configuration

    You can click Add Configuration to add multiple groups of data source configurations so that one collection task can connect to multiple database instances at the same time. To delete a group of configurations, click Delete in the upper right corner. This is applicable to scenarios where the metadata of multiple databases needs to be collected in batches.

    • Data Source (mandatory): Select a data source type from the drop-down list, for example, MySQL.
    • Database Instance (mandatory): Select a database instance from the drop-down list, for example, dsc-test.

  5. Click Next. The Configure subtasks page is displayed.

    Enable or disable the following metadata scanning configuration items:

    • Scan user tables: Configure whether to obtain the user table structure information from the database. If this function is enabled, the metadata of user-defined data tables will be collected.
    • Scan system tables: Configure whether to scan system tables, such as those in information_schema, which may contain a large amount of system metadata.
    • Scan column constraints: Configure whether to collect constraint information about each column, such as primary keys, foreign keys, unique constraints, and non-null constraints.
    • Scan views: Configure whether to obtain the view structure information from the database. A view is a virtual table created based on a base table.
    • Scan permissions: Configure whether to collect permission assignment information about database objects, including users' and roles' access permissions on tables and columns.
    • Extract sample data: Configure whether to extract some sample data from data tables to assist in sensitive data identification and classification.

  6. Click Next. On the Configure Task Information page, configure task information. For details about the parameters, see Table 2.

    Table 2 Parameters description

    Parameter

    Description

    Task Details

    • Task: You can customize the name of a collection task. This parameter is mandatory. The value can contain only letters, digits, underscores (_), and hyphens (-), and cannot exceed 255 characters.
    • Task Description: Task description. This parameter is optional.

    Task Settings

    Click or to enable or disable Delete disconnected metadata.

    When to Execute

    • Identification Period: You can select Once, Daily, Weekly, or Monthly.
    • When to Execute: You can select Now or As scheduled.
    • Start time: If you select As scheduled, click to set the start time.

  7. Click Next. On the configuration confirmation page that is displayed, confirm the parameters.
  8. Click Finish. A new metadata collection task is created.

    After the task is created, you can view the new task and its status in the metadata task management list.

Related Operations

  • Running a metadata task: In the Operation column of a metadata task, click Run.
  • Editing a metadata task: In the Operation column of a metadata task, click Edit.
  • Deleting a metadata task: In the Operation column of a metadata task, click Delete.

    After a metadata task is deleted, the metadata collected by the task will be cleared and cannot be restored. Exercise caution when performing this operation.

References

  • After creating a metadata task, you can manage data assets by level and category on the asset view page. For details, see Asset View.
  • For more operations related to classification and grading, see Classification and Grading.