To use Cloud SQL effectively, you should understand some of the concepts on which it is built. This page provides an overview of key terms and concepts that apply to Cloud SQL.
For an introduction to using Cloud SQL, see Cloud SQL overview.
Cloud SQL instance
A Cloud SQL instance corresponds to one virtual machine (VM). The VM includes the database instance and accompanying software containers to keep the database instance up and running.
Database instance
A database instance is the set of software and files that operate the databases: MySQL, PostgreSQL or SQL Server.
Public and private IP
In Cloud SQL, public IP means that the instance is accessible through the public internet. In contrast, instances using only private IP are not accessible through the public internet, but are accessible through a Virtual Private Cloud (VPC). Cloud SQL instances can have both a public and a private IP address.
High availability
Cloud SQL instances using high availability (HA) provide greater reliability than non-HA instances.
HA in Cloud SQL works by having two synchronized instances: a primary instance and a standby instance. Each instance has exactly one VM. Each instance is in a different zone in the same region.
Failover
A failover is when Cloud SQL switches serving from the original primary instance to the standby instance.
Autofailover is a mechanism that automatically triggers failover when a Cloud SQL instance didn't issue a heartbeat in the previous interval.
Standby instances
The standby instance is used in high availability to replace the primary instance when failover occurs. The standby instance doesn't appear in the Google Cloud console. When failover occurs, connections to the primary instance are automatically transferred to the standby instance.
Clone
When you clone a Cloud SQL instance, you create a new instance that is a copy of the source instance, but is completely independent. After cloning is complete, changes to the source instance are not reflected in the clone, and changes in the clone are not reflected in the source instance.
Replication
Replication is the ability to create copies of a Cloud SQL instance or an on-premises database, and offload work to the copies. The main reason for using replication is to scale the use of data in a database without degrading performance on the primary instance.