Database Service

Updated at:

The Database Service is Alibaba Cloud's data storage product that provides data storage capabilities. It integrates with Function Compute, flow orchestration, and other services to form a complete project and serves as a key component of the project.

Database Service Types

Database service type

Specification

ApsaraDB RDS for PostgreSQL

Default specification is pg.n2e.1c.1m

ApsaraDB RDS for MySQL

Default specification is mysql.n1e.small.1

Billing

The Function AI Platform itself is free. You pay only for the database services you use. For pricing details of data storage products, see the billing overview for each database service.

Database service type

Billing method

Billing overview

ApsaraDB RDS for PostgreSQL

Subscription

Billing overview

ApsaraDB RDS for MySQL

Subscription

Billing overview

Create a Database Service

Some templates automatically create the required database service when you deploy a project. You can also add a database service manually.

Deploy a Database Service Using a Template

This topic uses the Flow-based RAG Application template as an example.

  1. In the Function AI console, go to the Explore page and quickly find the Flow-based RAG Application template by searching or filtering categories.

  2. Click the target template card to open its product page, then click Deploy Now.

    The template name is Flow-based RAG Application. Related products include Function Compute (FC), Object Storage Service (OSS), Apsara File Storage NAS, Virtual Private Cloud (VPC), Simple Log Service (SLS), CloudFlow, and ApsaraDB RDS. The code repository is devsapp/start-flow-rag. The architecture diagram at the bottom of the page shows the offline knowledge base embedding flow: OSS buckets enter the text_splitter through the gateway_oss_trigger_stream node, split into multiple parallel branches, and each branch passes through embedding, pgvector_helper, and insert stages to write data into the vectordb database.

  3. In the Basic Configuration section for the database service, you will see that the Database service type is ApsaraDB RDS for PostgreSQL, with a default specification of pg.n2e.1c.1m. Use the Billing section above to estimate costs. Configure all required settings for the project template, then click Preview and Deploy.

    On the deployment configuration page, select the VectorDB component in the navigation pane on the left. The right pane displays its basic settings: database type is PostgreSQL, database name is flow_rag_database, and the vSwitch is marked as Auto-configured.

  4. Review the billing information for related products under View Resource Preview, then click .

  5. After deployment completes, go to the Configuration tab to view the settings needed to log on to the database.

Add a Database Service Manually

  1. On the project details page, click Create Service in the upper-left corner, select Database, and click to go to the service creation page.

  2. Enter the basic configuration for the database service, then click Preview & Deploy in the lower-left corner to automatically deploy the database service.

    The service name cannot be changed after deployment. Basic configuration includes Database type (such as ApsaraDB RDS for PostgreSQL), Region, Database instance name, Database name, Engine version, Username, Password, VPC, and vSwitch. In Advanced Configuration, you can enable Install vectorization plugin (supported only for PostgreSQL engine version 16.0).

  3. After successful creation, you can access the database service from your application.

    On the Configuration tab of the VectorDB service details page, you can view basic database settings, including Database instance name, Database type (PostgreSQL), Engine version, Database name, Username, and Password. Both VPC and vSwitch are set to Auto-configured. Click Log on to Database in the upper-right corner to access the database directly.

Update a Database Service

After creating a database service, you can update the database password. Click Save and then Deploy to apply your changes.

On the Basic Configuration page, locate the Password field to make changes. The password must be 8 to 32 characters long and include uppercase letters, lowercase letters, numbers, and special characters.