Help Center/ FunctionGraph/ User Guide/ Configuring Functions/ Configuring Triggers/ Document Database Service (DDS) Trigger (Offline Soon)
Updated on 2025-08-19 GMT+08:00

Document Database Service (DDS) Trigger (Offline Soon)

This section describes how to create a DDS trigger on the FunctionGraph console. The trigger triggers a function each time a table in the DDS database is updated.

The DDS trigger is about to be brought offline. You are advised not to create DDS triggers.

Notes and Constraints

  • The DDS triggers are available only to existing users. You can check whether the trigger type is supported on the console.
  • The valid payload size of a request body is 6 MB when a DDS trigger is used.

Prerequisites

  • Function and configuration:
  • DDS:
    • You have created a DDS DB instance.
    • You have created a DDS database.
    • You have configured the subnet permissions for the DDS security group. For details, see .

Creating a DDS Trigger

  1. Log in to the FunctionGraph console. In the navigation pane, choose Functions > Function List.
  2. Click the function to be configured to go to the function details page.
  3. Choose Configuration > Triggers and click Create Trigger.

    Figure 1 Creating a trigger

  4. Configure the following parameters.

    Table 1 Parameters for creating a DDS trigger

    Parameter

    Description

    Example Value

    Trigger Type

    Mandatory.

    Select Document Database Service (DDS).

    Document Database Service (DDS)

    DB Instance

    Mandatory.

    Select the created DDS database instance. If no instance is available, click Create DB Instance.

    dds_fg

    Password

    Mandatory.

    Password of the DDS DB instance administrator rwuser. The password must contain uppercase letters, lowercase letters, digits, and special characters.

    DDStest@123

    Database

    Mandatory.

    Enter a database name. Note that admin, local, and config are reserved database names and cannot be used here.

    DDS_test

    Collection

    Mandatory.

    Enter a custom database collection name. For details about how to create a database collection, see Creating a Collection.

    DDS_set

    Batch Size

    Mandatory.

    Maximum amount of data that can be processed by a function at a time. The value ranges from 1 to 10000.

    100

  5. Click OK.

Configuring a DDS Event to Trigger the Function

  1. Return to the FunctionGraph console. In the navigation pane, choose Functions > Function List.
  2. Click the name of the function to be configured. The function details page is displayed.
  3. Select a version and click Test. The Configure Test Event dialog box is displayed.
  4. Set the parameters described in Table 2 and click Save.

    Table 2 Test event information

    Parameter

    Description

    Configure Test Event

    You can choose to create a test event or edit an existing one.

    Use the default option Create new test event.

    Event Templates

    Select Document Database Service (DDS) to use the built-in DDS event template.

    Event Name

    The event name can contain 1 to 25 characters and must start with a letter and end with a letter or digit. Only letters, digits, underscores (_), and hyphens (-) are allowed. For example, dds-123test.

    Event data

    The system automatically loads the built-in DDS event template, which is used in this example without modifications.

  5. Click Test. The function test result is displayed.

Helpful Links

Manage function triggers through APIs. For details, see Function Trigger APIs.