Introduction

This post is not about GCP vs. AWS. There are a lot of articles comparing both cloud providers. I’m mainly an AWS user but recently I have been working with GCP and, although AWS is much more mature and has a lot of more services, GCP has a couple of services and few advantages that make it a better provider for certain use cases. This post is a short summary of the advantages of GCP over AWS.

If you are an AWS user, Google has a nice article explaining the similarities and differences, so I will focus on where I think GCP surpasses AWS and the use cases where I believe GCP may be a better option.

Network Stack

This is an area where GCP shines. It uses Google’s global ultra low latency internal network.

GCP uses a global SDN, code name Andromeda which offers an incredible performance, specially for low latency micro services and big data processing.

VPCs in GCP are global, you can define them across different regions if you choose to, the whole network is software defined providing great flexibility. Your Load Balancers work at edge locations providing worldwide load balancing and auto scaling.

Andromeda Performance

With GCP you can easily build a global infrastructure with Geo distributed data, very easily. This is very difficult with other cloud providers.

Andromeda Architecture

Developer Experience

Although I’m mainly an AWS user; as a developer I must admit that I prefer working with GCP. The cli is great, it is consistent, fast and easy to use; you can access alpha and beta features very easily as well.

The console experience is probably the best of all cloud providers, specially thanks to the cloud shell where you can get a terminal right from your browser and connect to the VMs securely from the browser without setting any SSH keys, this is awesome!.

GCP VMs boot up very fast, much faster than AWS, this makes scaling out especially responsive. Pricing is much easier to understand and you can customize the amount of CPU and RAM you want, this is very handy!. GCP allows almost all instance types to attach GPUs. This can turn any standard or custom instance into a ML ready VM.

Identity Management works extremely well thanks to Cloud Identity. It integrates with G suite and provides Single Sign On (SSO), so no need to use other solutions like OneLogin which are so popular with other cloud providers.

Finally, most of the services provide emulators. This is awesome, now I can test all my applications from my laptop without using any third party tool or complex integrations.

Pub/Sub

Whereas AWS provides many services for messaging like SQS, SNS, Kinesis, Event Bridge, Kafka, etc GCP has just pub/sub. And to be honest, you don’t need anything else, it is an extremely good and cheap service that you can use for a wide range of use cases from data streaming to micro services. It is a global service, it can scale to handle massive amounts of data and it’s very fast.

Pub/Sub is very easy to integrate and easy to use, it supports many clients and protocols; it also has two modes for consumers: push and pull. On top of that, it is very cost effective. It is also completely Serverless!

Databases

Google is all about data and they are extremely good at managing and scaling big data providing flexible solutions for each use case

Which data base should I use?

In particular they offer 3 solutions that, in my opinion, have no other competitor, and these are the Big Data Solutions. Companies with other cloud providers are building data lakes to store large amount of data into cheap storage like S3 in order to be cost effective; using the traditional frameworks such Spark on EMR to process it and optimize it to be able to query it from S3 using format such Parquet.

Maintaining a data lake is complex, specially if your data mutates very often. It can be come difficult to manage and eventually expensive. Wouldn’t it be great if we could store big data in databases that can scale and are also cost efficient? This would be much easier. Guest what? GCP has some great options. Although Object Storage will always be a lot cheaper, these 3 solutions could work for big data as long as it is not too massive.

Big Table

Big Table is a fully managed NoSQL database. It may be compared with AWS DynamoDB but they are different. DynamoDB is a NoSQL that can scale to handle millions of transactions but it can only store 400Kb per item, its goal is not to handle big data. Big Table in the other hand, is a petabyte-scale DB. It offers consistent sub-10ms latency, so it is extremely fast and reliable. It is easy to scale and cost effective.

Big Query

BigQuery is the gold product of GCP, it is hard to explain what exactly it is since it is quite a big product. It is defined as:

A serverless, highly scalable, and cost-effective cloud data warehouse designed to help you make informed decisions quickly, so you can transform your business with ease

The closest AWS product is Redshift and Redshift Spectrum. BigQuery is serverless and it can scale to query massive amount of data, it has built in ML and BI models and it can be used for a huge range of use cases. What I like about BigQuery is that you can use it for pretty much anything, you can store logs or billing information. It has higher latency than BigTable but it is also a bit cheaper.

As a Data-warehouse for BI, Redshift is probably better but for AI and ML BigQuery is better.

Spanner

Cloud Spanner is a fully managed, scalable, relational database service for regional and global application data. I don’t think there is DB similar to this one in other cloud providers. It is massive but it is also fully relational. It allows you to use regular SQL at a massive scale with strong consistent transactions. Do you remember the trade-offs between SQL vs. NoSQL? well, now they are gone, you can use SQL and scale globally, but at a price, it is not cheap.

ML/AI

Google has the best ML platform. It has tools for all types of users and use cases. From low level VMs for Deep Learning to high level APIs. The number of services is huge.

AWS is slowly catching up and has become really close to GCP offering thanks to SageMaker, but still GCP offer a more up to date and accurate set of tools. It provides VMs which are specialized in Deep Learning, great integration with Kubernetes, ML Training and much more.

Kubernetes

Regarding Kubernetes, there’s not much to say, GCP has the upper hand compared to other cloud providers. It is cheaper, up to date, faster and easier to use than other cloud providers. GKE is probably the best cloud service in the word because of its flexibility and price. It allows an easy migration from on-prem to the cloud. It is secure, easy to setup, provides great auto scaling and it is easy to monitor.

The best thing is that GCP empower Kubernetes and provides a friendly ecosystem to run pretty much any work load, from micro services or data streaming to big data pipeline. Kubernetes ecosystem is huge and all of these tools are verified and tested in GCP.

AWS is focusing more on Serverless whereas GCP on Kubernetes, both technologies are awesome. I wrote an article recently comparing both options.

Cost

In general GCP is cheaper than other cloud providers, as always it depends on the services that you use and how you use them. If you use Kubernetes them GCP will be a clear winner in terms of cost efficiency.

It is also the clear winner when it comes to compute and storage costs. GCP provides a better approach to discounted long-term usage and the preemptible VMs are extremely cheap.

It is hard to beat the price of GKE clusters running on preemptible VMs.

Use Cases

AWS is still the best cloud provider, it has a more mature offering and more services than GCP. It also has huge user base and better support. In case you have doubts, go with AWS. Amazon has done a great job catching up with GCP ML capabilities and has also reduced the cost of some services; but I still believe that for some use cases GCP may be a better option:

Machine Learning , specially Deep Learning or when you use Kubernetes.

, specially or when you use Kubernetes. Big Data Stream Processing thanks to Pub/Sub and DataFlow . Thanks to the network stack, the latency is lower on GCP and pipelines run faster and at a cheaper cost. For batch, both providers are equally as good.

thanks to Pub/Sub and . Thanks to the network stack, the latency is lower on GCP and pipelines run faster and at a cheaper cost. For batch, both providers are equally as good. Distributed Real Time Systems . If you require extreme low latency for your micro services Google SDN + pub/sub is a great solution. For example Go microservices + gRPC run really fast. Also, Akka is a great fit for GCP.

. If you require extreme low latency for your micro services Google + pub/sub is a great solution. For example + run really fast. Also, is a great fit for GCP. Kubernetes . This is the main advantage of GCP, if you want a portable infrastructure that runs efficiently at a low cost, GKE is a great tool. For Serverless, AWS may be a better choice.

. This is the main advantage of GCP, if you want a portable infrastructure that runs efficiently at a low cost, is a great tool. For may be a better choice. Global Big Data Databases. If you don’t want to use a data lake and want to store big data at a scale Spanner or Big Table are amazing databases that can make your life a lot easier.

In short, if you want fast low latency micro services running on Kubernetes and/or you have lots of data, then consider GCP.

Conclusion

I strongly recommended trying out the services and develop small POCs on both platforms to get hands on experience on both platforms. Both providers have a generous free tier. Do not take in consideration just the reports from consultants, you need to be your own judge and try out both platforms.

I personally like Kubernetes, it makes your code portable across providers, making it a lot easier to switch between them.

If you are an AWS user, start by reading the platform overview and then check the best practices. After that, read the guide for AWS professionals.

GCP is also very easy to secure and easier to manage than AWS. Finally take a look to all the services that GCP has to offer, it is catching up quickly.

I think it is great that we have several options, competition is good, we are in great moment for software development, so whichever platform you choose, it is going to be a good one. Just remember what the most important asset is, and invest on it: developers!