PolarDB-X 2.0

Updated at: 2024-11-07 02:23

Property definition

  • Data source type: polardbx20

  • Supported configuration modes (ConnectionPropertiesMode):

    • Connection string mode (UrlMode)

    • Instance mode (InstanceMode)

Instance mode of the current Alibaba Cloud account

Parameter

Type

Example

Required

Description and note

Parameter

Type

Example

Required

Description and note

regionId

String

cn-shanghai

Yes

The ID of the region to which the instance belongs.

instanceId

String

pc-2ze82jv51re2990g5

Yes

The ID of the PolarDB for Oracle cluster.

database

String

mysql_database

Yes

The name of the database.

username

String

xxxxx

Yes

The username.

password

String

xxxxx

Yes

The password.

properties

JSON Object

{
    "useSSL": "false"
}

No

The properties of the driver.

envType

String

Dev

Yes

The information about the data source environment. Valid values:

  • Dev: The development environment.

  • Prod: The production environment.

Instance mode of another Alibaba Cloud account

Parameter

Type

Example

Required

Description and note

Parameter

Type

Example

Required

Description and note

regionId

String

cn-shanghai

Yes

The ID of the region to which the instance belongs.

instanceId

String

pc-2ze82jv51re2990g5

Yes

The ID of the PolarDB for Oracle cluster.

database

String

polardbx_database

Yes

The name of the database.

username

String

xxxxx

Yes

The username.

password

String

xxxxx

Yes

The password.

crossAccountOwnerId

String

1

Yes

The ID of another Alibaba Cloud account.

crossAccountRoleName

String

cross-role

Yes

The name of the RAM role assumed by another Alibaba Cloud account.

properties

JSON Object

{
    "useSSL": "false"
}

No

The properties of the driver.

envType

String

Dev

Yes

The information about the data source environment. Valid values:

  • Dev: The development environment.

  • Prod: The production environment.

Connection string mode

Parameter

Type

Example

Required

Description and note

Parameter

Type

Example

Required

Description and note

address

Array

[
  {
    "host": "127.0.0.1",
    "port": 3306
  }
]

Yes

The address, which contains only a single pair of host and port.

database

String

polardbx_database

Yes

The name of the database.

username

String

xxxxx

Yes

The username.

password

String

xxxxx

Yes

The password.

properties

JSON Object

{
    "useSSL": "false"
}

No

The properties of the driver.

envType

String

Dev

Yes

The information about the data source environment. Valid values:

  • Dev: The development environment.

  • Prod: The production environment.

Configuration example of a data source

Instance mode of the current Alibaba Cloud account

{
    "envType": "Prod",
    "ownerId": "1107550004253538",
    "regionId": "cn-beijing",
    "instanceId": "pxc-bjrikym49rir1s",
    "database": "my_database",
    "username": "my_username",
    "password": "my_password",
    "properties": {
        "socketTimeout": "2000"
    }
}

Instance mode of another Alibaba Cloud account

{
    "envType": "Prod",
    "regionId": "cn-beijing",
    "instanceId": "pxc-bjrikym49rir1s",
    "database": "my_database",
    "username": "my_username",
    "password": "my_password",
    "properties": {
        "socketTimeout": "2000"
    },
    "crossAccountOwnerId": "123123123",
    "crossAccountRoleName": "cross-role"
}

Connection string mode

{
    "envType": "Prod",
    "address": [
        {
            "host": "127.0.0.1",
            "port": "3306"
        }
    ],
    "database": "my_database",
    "username": "my_username",
    "password": "my_password",
    "properties": {
        "socketTimeout": "2000"
    }
}
  • On this page (1, T)
  • Property definition
  • Instance mode of the current Alibaba Cloud account
  • Instance mode of another Alibaba Cloud account
  • Connection string mode
  • Configuration example of a data source
  • Instance mode of the current Alibaba Cloud account
  • Instance mode of another Alibaba Cloud account
  • Connection string mode
Feedback
phone Contact Us

Chat now with Alibaba Cloud Customer Service to assist you in finding the right products and services to meet your needs.

alicare alicarealicarealicare