Google Cloud SQL Connection
The Google Cloud SQL connection type enables automations to query and write data to managed MySQL, PostgreSQL, or SQL Server instances running on Google Cloud Platform. It is used by the plugin-sql-databases plugin, which delegates to the sql-database-connector.
Connection Type
| Property | Value |
|---|---|
| Type ID | GCLOUD_SQL |
| Category | Relational Databases |
| Testable | Yes |
| Entity class | DBConnectionDetails |
Friendly Example
| What you enter | Example |
|---|---|
| Connection name | Cloud SQL - Analytics DB |
| Used for | Reading approved analytics data for scheduled automation reports |
| Main details to collect | Public IP (or instance connection name), port, database name, username, and password |
| Best person to provide it | Google Cloud or database administrator |
After it is saved, workflow builders select Cloud SQL - Analytics DB in a node instead of entering these details again.
Connection Modes
| Mode | When to use |
|---|---|
| All Details | Provide the host (public IP), port, database name, username, and password individually. The platform builds the JDBC URL automatically. |
| JDBC URL | Paste a full JDBC connection string directly. Useful when your DBA provides a pre-built URL or when connecting via the Cloud SQL Auth Proxy. |
For production workloads, Google recommends using the Cloud SQL Auth Proxy instead of a raw public IP. The proxy handles TLS and IAM-based authentication transparently. When the proxy is running locally on the Qinfinite host, set host to 127.0.0.1 and port to the proxy's local listening port.
Mandatory Fields
| Field | What It Means | Example |
|---|---|---|
host | Public IP address of the Cloud SQL instance, or 127.0.0.1 when using the Cloud SQL Auth Proxy. Found in the Google Cloud Console under the instance's Overview tab. | 34.90.123.45 |
port | TCP port the database engine listens on. Default is 3306 (MySQL), 5432 (PostgreSQL), or 1433 (SQL Server). | 5432 |
database | Name of the database to connect to | analytics |
username | Database login username | qinfinite_automation |
password | Password for the database user. Encrypted at rest. | •••••••• |
JDBC URL Format
MySQL:
jdbc:mysql://34.90.123.45:3306/analytics
PostgreSQL:
jdbc:postgresql://34.90.123.45:5432/analytics
SQL Server:
jdbc:sqlserver://34.90.123.45:1433;databaseName=analytics;encrypt=true
SSL/TLS in the JDBC URL
Cloud SQL can be configured to require SSL. If your instance enforces SSL:
MySQL:
jdbc:mysql://34.90.123.45:3306/analytics?useSSL=true&requireSSL=true&verifyServerCertificate=true
PostgreSQL:
jdbc:postgresql://34.90.123.45:5432/analytics?ssl=true&sslmode=verify-full
When connecting through the Cloud SQL Auth Proxy, SSL is already handled by the proxy. You do not need to add SSL parameters to the JDBC URL in that case.
Advanced Fields
| Field | What It Means | Example |
|---|---|---|
sslMode | SSL enforcement level. Options: disabled, preferred, required, verify-ca, verify-full. Use required or verify-full for production. | required |
connectionTimeout | Maximum time in milliseconds to wait when opening a connection before failing. | 10000 |
Setup Instructions
-
Open the Google Cloud Console and navigate to SQL under the Databases section. Select your Cloud SQL instance and open the Overview tab. Note the Public IP address (or the Instance connection name if you are using the Auth Proxy, formatted as
project:region:instance). -
Enable public IP access if it is not already enabled. Go to Connections > Networking and add the Qinfinite platform's outbound IP address to the Authorized networks list. If you prefer not to expose a public IP, set up the Cloud SQL Auth Proxy on the Qinfinite host instead.
-
Create a dedicated database user with the minimum permissions required:
MySQL:
CREATE USER 'qinfinite_automation'@'%' IDENTIFIED BY 'strong-password';
GRANT SELECT, INSERT, UPDATE, DELETE ON analytics.* TO 'qinfinite_automation'@'%';
FLUSH PRIVILEGES;PostgreSQL:
CREATE USER qinfinite_automation WITH PASSWORD 'strong-password';
GRANT SELECT, INSERT, UPDATE, DELETE ON ALL TABLES IN SCHEMA public TO qinfinite_automation;Alternatively, create the user from the Cloud Console under Users if you prefer a UI-based approach.
-
Create the connection in the Global Configurator using the public IP, port, database name, and the credentials from the step above.
-
Test the connection. Click Test Connection to confirm the credentials and network path are correct before saving.
Troubleshooting
| Symptom | Likely Cause |
|---|---|
Connection refused or Communications link failure | The platform's IP address is not in the Cloud SQL Authorized networks list, or the instance does not have a public IP enabled. Add the IP or set up the Auth Proxy. |
Access denied for user '...'@'...' | Wrong username or password, or the user account does not permit connections from the platform's IP. Verify the GRANT statement and the host pattern. |
SSL connection error | The instance is set to Require SSL but the JDBC URL does not include SSL parameters. Add the appropriate useSSL or ssl parameters for your engine. |
Unknown database / database does not exist | The database name in the connection does not exist on the instance. Check the exact name in the Cloud Console under Databases. |