This topic describes how to connect to OceanBase Cloud using Google Cloud Private Service Connect.
Prerequisites
- You have registered a Google Cloud account and created a project.
- You have registered an OceanBase Cloud account and created an instance and a tenant. For more information, see Create an instance and Create a tenant. This topic uses the Oracle compatible tenant as an example.
Procedure
Log in to the OceanBase Cloud console and click Networking in the left navigation pane.
On the Private Connectivity tab, click Create Private Connection.
In Step 1: Create your Private Service Connect service, select Google Cloud as the cloud provider, and select the target instance and tenant.
Open the Google Cloud console and copy the project ID displayed on the page.

Return to the OceanBase Cloud console, enter the project ID in 3. Create a Private Service Connect service under Step 1: Create your Private Service Connect service, and click Create.
After the service is created, copy the Target Service information in Step 2: Create an endpoint and connect.

Open the Private Service Connect page in the Google Cloud Networking Services console, and click + CONNECT ENDPOINT in the Endpoints section.
On the Connect endpoint page, enter the following information:
ParameterDescriptionTarget Select Published service. Endpoint name Specify a name for your Endpoint. Network Select a network for your Endpoint. Subnetwork Select a subnet for your Endpoint. IP Address Select an IP address for your Endpoint. If necessary, you can create a new one. Enable global access Select Enable global access to access the Endpoint from any region. This option is optional. 
Click ADD ENDPOINT.
On the Private Service Connect page, find the endpoint you just created and copy the PSC Connection ID.

Return to the OceanBase Cloud console. In the Step 2: Create an endpoint and connect section, enter the PSC Connection ID in the PSC Connection ID field, then click Connect.
In the Step 3: Connect section, choose an existing account or create a new one, and select the target connection method. Copy the generated connection string to your client.
Currently, OceanBase Cloud supports multiple clients, drivers, and languages. For more information, see Overview.
Enter the account name and password generated in Step 12 in the CLI of your MySQL client. You can now connect to and use OceanBase Cloud.
What to do next
After creating an Endpoint, you can view its details on the Topology Diagram tab. This tab is located on the tenant's Overview page. If you need to update the Endpoint due to VPC changes, OceanBase Cloud allows you to delete the existing Endpoint and recreate it.
Delete an Endpoint:
In the OceanBase Cloud console, navigate to the Instances page, and click the name of the target tenant to go to the tenant overview page.
On the Topology Diagram tab, click the delete button to remove the existing Endpoint.
