Jump to Content
Databases

Recap of what’s new with Cloud Spanner (at Google Cloud Next ’23)

September 13, 2023
https://storage.googleapis.com/gweb-cloudblog-publish/images/GCN23_GE_BlogHeader_2436x1200_6.max-2500x2500.png
Jagdeep Singh

Director of Product management

Mohit Gulati

Senior Product Manager

The last few weeks were very exciting for users of Cloud Spanner, Google’s fully managed, horizontally scalable database that offers up to 99.999% availability. We had several big announcements leading up to and at Google Cloud Next ‘23: breaking data silos between transactional and analytical data using Data Boost, integration with Google’s always-on, generative AI collaborator Duet AI, and enabling schema authors to push down critical identity logic into the database using auto-generated keys. Let’s dig deeper into each of these announcements.

Run isolated analytical queries on transactional data with Data Boost

During the show, we announced the general availability of Cloud Spanner Data Boost, a break-through technology that delivers high-performance, workload-isolated, on-demand processing of operational data to support analytics, reporting, ML, and more. 

Data Boost takes advantage of Google’s disaggregated compute and storage architecture to provide on-demand, isolated compute resources to process analytical queries directly on the storage layer, with virtually no impact to the existing transactional workload. And you retain all the things you love about Spanner, including the virtually infinite scale, global external consistency, and unmatched availability.

With Data Boost, you can be confident about running batch or analytic workloads against your transactional database or enabling broad data sharing. Analysts and other users can get access to fresh data without impacting latency-sensitive transactional workloads, and without comprimising access controls. And the best part is, you can probably set everything up over coffee and potentially lower your overall operational costs before your second cup. 

To watch Data Boost in action check out the session from Next ‘23, read more about it in the blog, or learn how to enable Data Boost with the guidance in the documentation

Write SQL with Duet AI assistance in Spanner Studio

We also announced a preview of Spanner and Duet AI, which provides a robust, IDE-like experience with AI-assisted SQL capabilities that are tightly integrated into Cloud Spanner Studio running in your browser. 

Spanner users often rely on third-party IDEs and SQL clients to define tables, run ad-hoc queries, or update existing data. Not only do they have to choose, download and configure secure connectivity for these clients, but the context switching between the Google Cloud console and external clients can be distracting and slow down workflows. Developers working on large, complex projects spend a lot of time and cognitive effort to understand new code bases, languages, and dialects.

Spanner users can now explore and manage their data more efficiently via three major improvements to Spanner Studio:

  • Object Explorer - Navigate your database structure in a familiar tree-like hierarchy

  • Improved SQL editor - Structure, modify, and query your data from a single interface

  • Duet AI assistance - Duet AI in Cloud Spanner uses a specialized Large Language Model (LLM) to provide users with multi-line SQL completion and generation of SQL statements from natural language prompts. 

These features address long-standing requests for enhanced data management capabilities. And with Duet AI, Spanner provides new levels of power and ease in the Spanner console, putting users’ data at their fingertips. 

To watch Duet AI and Spanner in action, check out this session from the Databases keynote from Next. ‘23 Learn more about how you can use Duet-AI in Spanner by reading more about it in our documentation.

Push identity logic into the database with auto-generated keys

Finally, we announced support for auto-generated keys in Spanner, allowing schema authors to push down critical identity logic into the database. This simplifies application code and reduces opportunities for errors or inconsistencies. Auto-generated keys also help you migrate from relational databases that expect keys based on integer sequences. Like everything in Spanner, auto-generated keys are designed from the ground up not to compromise scalability, availability, or performance over the entire lifecycle of your applications.

With the launch of auto-generated keys, Cloud Spanner has two new ways of generating primary keys in the database: UUIDs and integer sequences. 

  • The default recommendation for primary keys in Spanner is to use a Universally Unique Identifier, or UUID, 128-bit identifiers generated using a public specification (rfc-4122). A table can use the new GENERATE_UUID() function in PostgreSQL or GoogleSQL dialect databases in a primary key default value expression to automatically populate new rows with a UUID v4 value.

  • For customers with an existing schema that uses an integer primary key, Spanner now offers a SEQUENCE object that generates unique integers as part of a primary key DEFAULT expression. However, unlike a monotonic sequence, the values generated by a Spanner sequence are distributed uniformly and thus won’t hotspot at scale. You can generate a value from that sequence in a default expression using the nextval() function in PostgreSQL or GET_NEXT_SEQUENCE_VALUE() in GoogleSQL.

To learn more about auto-generated keys with Spanner, read the launch blog or our documentation here (GoogleSQL) and here (PostgreSQL)

At Next ‘23,, we also shared stories about how customers are using Spanner to scale their business and serve their end users. We shared how CERC is using Spanner to disrupt the exchange receivables market using Spanner innovations — watch a recording of the session. We also shared how Google ads and Gmail run on Spanner to get the highest levels of availability and reliability; you can watch a recording of the session here.

But we’re far from done. Watch this space for news about  our latest Spanner  innovations. In  the meantime learn more about what makes Spanner unique and how it’s being used today. Or try it yourself for free for 90-days or for as little as $65 USD/month for a production-ready instance that grows with your business without downtime or disruptive re-architecture.

Posted in