This post covers strategies for maximizing write throughput to Cloud Spanner.

Too busy to read? Check out the video above for the summary.

The scenario

As a reminder of the scenario we are working within this series of blog posts, imagine an online shop built on the back of a traditional database that we want to migrate to Cloud Spanner.
We start with a backup of that imaginary database, where all data is exported to CSV files and uploaded to Google Cloud Storage(GCS). A loader program then reads all the files from GCS, processes them and writes the data to Cloud Spanner.

The previous blog post discussed how to choose the right primary keys for the scenario to enable scalable reads and writes. The approach we took didn’t utilize the full data load potential of Cloud Spanner because we were writing only one row per transaction. …


This post covers how to choose the right primary keys to enable scalable data writes in Cloud Spanner.

Too busy to read? Check out the video above for the summary.

The scenario

Imagine an online shop built on the back of a traditional database that we need to migrate to Cloud Spanner.
We start with a backup of that imaginary database, where all data is exported to CSV files and uploaded to Google Cloud Storage(GCS). A loader program then reads all the files from GCS, processes them and writes the data to Cloud Spanner. So far so good; having the files in Google Cloud Storage and processing them from a Compute Engine instance close to our Cloud Spanner instance is great. …


Setting up and managing a distributed database for better scalability and high availability is difficult and can cause numerous operational headaches. Often you have to choose between scalability and consistency, but ease of set up and manageability are also important factors to consider. Google Cloud Spanner combines the scalability of a NoSQL database with the qualities of traditional relational SQL databases, including schemas, ACID (atomicity, consistency, isolation, durability), consistency across rows and tables, and ad hoc queries.
This post shows you how to get started with Google Cloud Spanner.

Too busy to read? …


When multiple teams are working on a software development project it makes sense to have multiple Google Cloud Platform projects for more fine-grained access and permission control over project resources. With this approach, however, you need a way to connect services without having these services exposed to the public. That’s where a VPN helps. You can use a VPN to securely connect the networks in which your services are running. In this blog post we’ll set up a 1:1 connection between two networks. The Google VPN setup also allows for 1:n and n:m VPN setups between networks.

Quick summary of steps needed

  • In each of your projects create a dedicated network for your instances that you want to connect via…


Currently there is no one-line command to move a Linux VM instance between Google Cloud Platform projects, but I’ve created an easy to follow step-by-step guide that you can use. (Note: This guide does not cover Windows.)

Quick summary of steps needed

  • Detach the boot disk from the VM that you intend to move by deselecting “Delete boot disk on instance delete” and terminating the VM
  • Create an image from the detached boot disk
  • Upload the image to Google Cloud Storage and share it with the new project
  • Create a custom image under the new project based on the image you uploaded to Google Cloud…

About

Robert Kubis

Google Cloud DA, Developer, Do-it mentality, Enthusiast. Enjoying tech trends, food, travel, all kinds of outdoor activities, flying. Views are my own.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store