PostgreSQL interface for Cloud Spanner is now generally available

Google Cloud recently announced the general availability of the PostgreSQL interface for Cloud Spanner. The new interface increases the portability of workloads to and from Spanner and provides a globally distributed option for developers already familiar with PostgreSQL.

First announced last fall, the new feature adds another option to the Google Standard SQL on Google Cloud interface. While the supported syntax is similar to standard PostgreSQL, workloads that rely on stored procedures, extensions, triggers, or non-serializable isolation require a redesign to run on Spanner.

Justin Makeigsenior product manager at Google Cloud, explains how PostgreSQL is now the de facto standard for operational databases:

Enterprises and digital natives are standardizing on PostgreSQL as a common “API” for their operational databases (…) As organizations modernize in the cloud, they seek to avoid the onerous lock-in associated with the latest databases. generation and leverage the industry skills and tools they already have. A growing number of them are standardizing on PostgreSQL.

To see the differences between the two interfaces, developers should refer to the article Dialect parity between Google Standard SQL and PostgreSQL. Andi GutmansVP/GM databases at Google, comments:

This reinforces our commitment to being the most open cloud so customers have flexibility and choice in when and where to run. Spanner offers virtually unlimited scalability with industry-leading 5-9 availability and zero maintenance windows.

Makeig explains how portability helps regulated industries:

Schemas and queries you write on Spanner’s PostgreSQL interface will mostly run unmodified in another PostgreSQL environment, whether in Google Cloud or elsewhere. This portability is especially important for industries such as financial services, where emerging regulations and industry directives require critical services to demonstrate critical vendor exit strategies to ensure business continuity.

Google Cloud recently announced the preview of AlloyDB for PostgreSQL, a PostgreSQL-compatible managed service targeting enterprise deployments. CockroachDB, Yugabyte and Aurora Amazon also offer a PostgreSQL compatible distributed database as a service. To reassure existing customers, Makeig adds:

Google is fully committed to the continued support and evolution of Google Standard SQL. Spanner’s ANSI SQL dialect and ecosystem is the best choice for teams already familiar with Google Cloud. Along with a wide range of features, it offers compatibility with BigQuery’s SQL.

The new PostgreSQL interface is configured per database at build time. Administrators can provision and manage PostgreSQL databases using the existing console, APIs and gcloud command line interface.

Execution of the new granular instances, customers can run a Spanner database starting at $65/month, or $40/month on a three-year commitment. There are no additional costs associated with the new PostgreSQL interface.