Sunday, February 19, 2017

Cloud Spanner available in public beta!

Hi Cloud lovers!

This week, Google made a very important announcement: they launched the public beta of Cloud Spanner. So what is Cloud Spanner?

What is Cloud Spanner?


In short, it's a globally distributed relational database service. It's a fully managed service so you don't have to worry about maintenance or anything, just have to use it to enjoy its spectacular scalability and performance :)
Also Cloud Spanner is from a category of database called NewSQL. NewSQL databases try to get the best of RDBMS and NoSQL, where RDBMS brings SQL query, schema and ACID transaction and NoSQL brings availability (HA), scalability and flexibility.


So why is that Cloud Spanner so spectacular? it is in the way it keeps a common time between data centers using atomic clock and GPS receivers. Each master server in each datacenter trade reading in order to settle a common time. That way, every time a new data is send to Cloud Spanner, a timestamp is associated with it and so when it is replicated to other data centers, they will be replayed in the correct order.

Google calls this timekeeping technology TrueTime, and only Google has it.


Spanner already has 5 years of internal history


Internally at Google, Spanner has been used for already 5 years for services like Gmail, AdWords, Google Play and more than 2000 other services.  Usually, when a new technology appears in the market, best practices are lacking because of the lack of experience on that new technology. But in Spanner's case, it already has a long life inside Google and there are many Spanner experts that can share experiences as well as best practices on the new released product.

If you visit the official Cloud Spanner documentation site, you will already find so many details on Spanner concept, best practices etc... I strongly recommend visiting this site and learn more about Cloud Spanner.

Cloud Spanner deployment models


Cloud Spanner offers 2 deployment models:

  1. Regional deployment: it will replicate your databases across zones within a region (3 replicas)
  2. Global deployment: it will replicate your databases across 2 regions (5 replicas)

Cloud Spanner sounds amazing, is there any pitfalls?


Right now, Cloud Spanner is available in Beta. There's some features that are not available yet.

  • Global deployment: right now you can only deploy Cloud Spanner in a regional deployment. And in the Beta phase, only the next 3 regions are supported:
    • regional-us-central1 — Central United States
    • regional-europe-west1 — Western Europe
    • regional-asia-east1 — Eastern Asia-Pacific
  • DML (Data Manipulation Language): right now, Cloud Spanner doesn't offer DML (INSERT, UPDATE, DELETE) in SQL. So in SQL, you're able to query using SELECT but for any data manipulation query, you will have to use the client libraries or API/gRPC.


What about the performances?


As a guideline, you will find on the official Cloud Spanner documentation that the read/write queries per second (QPS) offered by this database will depend on the number of node you configure in your Cloud Spanner instance.

In short, if you follow their best practices, you will get per node:
  • up to 10000 QPS of reads 
  • up to 2000 QPS of write  (writing single rows at 1 KB data per row),
  • 2 TiB of storage
If you want more details about how Cloud Spanner performs depending on specific workloads, I recommend reading that excellent article that Quizlet published.

Hope you are excited by Cloud Spanner as much as me! you can start testing it right now here!

Welcome to my new blog about GCP!

Hi cloud lovers!

Welcome to my new blog about Google Cloud Platform (GCP)!



This blog will be covering tips, examples and explanations about GCP.

A little about me. I'm working as a Sales Engineer at Google in Tokyo. I'm covering there all the Google Cloud stacks, means GCP as well as G Suite (Google productivity suite) and I'm helping customers to make best use of GCP to implement the best scalable apps possible.  But I hope to see more and more customers bringing their on-prem workload (even any Windows workloads!) on GCP since I believe that GCP is Enterprise ready!
This year at work, I'm covering the game industry in Japan so I might be able to share you some best practices or learning from some of the projects I would work on.

Before joining Google, I used to work at Microsoft as a consultant first, then as a Sales Engineer (TSP) on infrastructure as well as client side technologies. 
I will try in this blog to leverage my 10 years experience on Infrastructure to bring you as much valuable content as possible that will help you make best use of GCP :)

Happy reading!
Samir