Public Cloud Compute Services Review (May 2020 update)

Table of Contents

GCP Compute Services

Google Compute Engine

Technology

The technology behind Google Cloud’s VMs is KVM

SLA

Monthly Uptime Percentage to Customer of at least 99.99%

Machine Types

  • Predefined machine types
    Predefined machine types have a fixed collection of resources (Up to 224 VCPU & 896 GB Memory).
  • Custom machine
    Up to 416 VCPU & The memory per vCPU of a custom machine type must be between 0.5 GB and 8 GB per vCPU. If you require more memory, you must use one of the mega-memory machine types, which allow you to create instances with a total of 1.4 TB per VM instance.
  • GPU
    Up to 8 GPU & 96 GB of GPU Memory

Machine Options

  • Dedicated Instances
    • On Demand Instances allows you to pay a fixed rate by second with no Commitment.
    • Reserved Instances (Committed-use discounts ) If your workload is stable and predictable, you can purchase a specific amount of vCPUs and memory for a discount off of normal prices in return for committing to a usage term of 1 year or 3 years. The discount is up to 57% for most machine types or custom machine types. The discount is up to 70% for memory-optimized machine types.
    • Spot Instances (Preemptible VM) An instance that you can create and run at a much lower price than normal instances. However, Compute Engine might terminate (preempt) these instances if it requires access to those resources for other tasks.
      • Get upto 79% discount
      • Can not live Migrate and auto Restart
      • 24 hours max use and Not covered under SLA
      • Charged if only started for 10 min , Less use will not be billed.
      • When you attach GPU to preemptible – you quota will be used.
      • Compute Engine sends signal for preemption to VM 30 sec
      • Average preemption rate varies between 5% and 15% per seven days per project
    • Shielded VM
      Shielded VM offers verifiable integrity of your Compute Engine VM instances, so you can be confident your instances haven’t been compromised by boot- or kernel-level malware or rootkits. Shielded VM’s verifiable integrity is achieved through the use of Secure Boot, virtual trusted platform module (vTPM)-enabled Measured Boot, and integrity monitoring.
  • Dedicate Host (Sole-tenant nodes) Sole-tenant nodes are physical Compute Engine servers dedicated to hosting only VM instances from your specific project.
  • On Premises – Anthos GKE on-prem (GKE on-prem) is hybrid cloud software that brings GKE to on-premises data centers.

Disks (Block & File Devices)

By default, each Compute Engine instance has a single boot persistent disk that contains the operating system. When your applications require additional storage space, you can add one or more additional storage options to your instance.

Persistence Disk
  • Network Storage & Attached VM through network Interface
  • Persistent and independent of compute(instance)
  • Zonal (or regional with synchronous replication across two zones in a region)
  • Used as Bootable, Snapshots
  • Type:
    • Standard (magnetic) up to 64TB
    • SSD up to 64TB
  • Resize dynamically (even when instance is running)
  • Attached to multiple VM for read only data
  • Automatic Encryption – You can choose your own key
  • Lower performance with corresponding Local SSD/ Ram disk
Local Disk
  • Local Disk can be attached to VM
  • Ephemeral in nature; Data stays on Restart but not on Instance stopped / terminate
  • Provided high IOPS based on size of disk; Upto 680K read and 360 write
  • You can attach a maximum of 24 local SSD partitions for a total of 9 TB per instance.
  • Can not live migrate
  • SCSI or NVMe Interface
  • Not available for Shared Core
File Server

A file server, also called a storage filer, provides a way for applications to read and update files that are shared across machines. It manages multiples filer solution like Elastifile, Quobyte, Avere, Panzura and others. Support petabytes for Elastifile and Quobyte

Ram Disk

RAM disks share instance memory with your applications and use the RAM assigned to the VM instance.

  • Faster than any disk option available
  • Ephemeral – goes away on stop, restart, terminate

Auto Scaling

Autoscaling is a feature of managed instance groups. A managed instance group is a pool of homogeneous instances, created from a common instance template. An autoscaler adds or deletes instances from a managed instance group. Although Compute Engine has both managed and unmanaged instance groups, only managed instance groups can be used with autoscaler.

  • Compute Engine offers autoscaling to automatically add or remove virtual machines from an instance group based on increases or decreases in load.
  • This allows your applications to gracefully handle increases in traffic and reduces cost when the need for resources is lower.
  • You just define the autoscaling policy and the autoscaler performs automatic scaling based on the measured load.

Autoscaling policy and target utilization

To create an autoscaler, you must specify the autoscaling policy and a target utilization level that the autoscaler uses to determine when to scale the group. You can choose to scale using the following policies:

  • Average CPU utilization
  • HTTP load balancing serving capacity, which can be based on either utilization or requests per second.
  • Stackdriver Monitoring metrics

Billing Model

  • All vCPUs, GPUs, and GB of memory are charged a minimum of 1 minute. After 1 minute, instances are charged in 1 second increments.
  • Discounts:
    • Sustained use discounts (When an instance uses a vCPU or a GB of memory for more than 25% of a month) up to 30%
    • Committed use discounts up to 70%
    • Pre-emptible up to 80%

Other

  • Linux & Windows Support
  • Public and Custom Image Support
  • Managed and unmanaged Instance Groups Support
  • Snapshot support
  • Start & Termination Script
  • Migration tools and methodology

 

Google Kubernetes Engine & Registry (and Build)

Google Kubernetes Engine provides a managed environment for deploying, managing, and scaling your containerized applications using Google infrastructure. The environment GKE provides consists of multiple machines (specifically, Google Compute Engine instances) grouped together to form a cluster.

GKE clusters are powered by the Kubernetes open source cluster management system and Docker Image Support with the following features:

  • Google Cloud Platform’s load-balancing for Compute Engine instances
  • Node pools to designate subsets of nodes within a cluster for additional flexibility
  • Multi-zone Clusters or Regional Clusters
  • Automatic scaling of your cluster’s node instance count
  • Automatic upgrades for your cluster’s node software
  • Node auto-repair to maintain node health and availability
  • Hybrid Networking
  • Workload Portability, on-premises and cloud
  • Dashboard for your project’s GKE clusters and their resources. You can use these dashboards to view, inspect, manage, and delete resources in your clusters
  • Identity and Access Management Integration
  • Logging and Monitoring with Stackdriver for visibility into your cluster

Google Container Registry is a private container image registry that runs on Google Cloud Platform. Container Registry supports Docker Image Manifest V2 and OCI image formats with the additional features:

  • Perform vulnerability analysis
  • Fine-grained access control.
  • Existing CI/CD integrations

Google Cloud Build is a service that executes your builds on Google Cloud Platform’s infrastructure.

Cloud Build can import source code from a variety of repositories or cloud storage spaces, execute a build to your specifications, and produce artifacts such as Docker containers or Java archives.

GKE uses Google Compute Engine instances for nodes in the cluster. You are billed for each of those instances according to Compute Engine’s pricing, until the nodes are deleted.

Support GKE on premises with Anthos GKE on-prem that brings Google Kubernetes Engine (GKE) to on-premises data centers. With GKE on-prem, you can create, manage, and upgrade Kubernetes clusters in your on-premises environment.

Google is also pushing the concept of Serverless in containers with Knative. Knative provides an open API and runtime environment that enables you to run your serverless workloads anywhere you choose: fully managed on Google Cloud, or on Anthos on Google Kubernetes Engine (GKE), or on your own Kubernetes cluster.

Batch on GKE (Batch) the GCP batch solution  for scheduling and managing batch workloads. With Batch, you can leverage the on-demand and flexible nature of cloud. Batch is based on Kubernetes and containers so your jobs are portable.

 

Google App Engine

Google App Engine is a fully managed platform that completely abstracts away infrastructure so you focus only on code.

Google offers two environments:

  • App Engine Flexible Environment
    App Engine allows developers to focus on doing what they do best, writing code. Based on Google Compute Engine, the App Engine flexible environment automatically scales your app up and down while balancing the load. Microservices, authorization, SQL and NoSQL databases, traffic splitting, logging, versioning, security scanning, and content delivery networks are all supported natively. In addition, the App Engine flexible environment allows you to customize the runtime and even the operating system of your virtual machine using Dockerfiles.
  • App Engine Standard Environment
    The App Engine standard environment is based on container instances running on Google’s infrastructure. Containers are preconfigured with one of several available runtimes. Applications run in a secure, sandboxed environment, allowing the App Engine standard environment to distribute requests across multiple servers, and scaling servers to meet traffic demands. Your application runs within its own secure, reliable environment that is independent of the hardware, operating system, or physical location of the server.
When to choose the flexible environmentWhen to choose the standard environment
Using the App Engine flexible environment means that your application instances run within Docker containers on Google Compute Engine virtual machines (VMs).Using the App Engine standard environment means that your application instances run in a sandbox, using the runtime environment of a supported language listed below.
Generally, good candidates for the flexible environment are applications that receive consistent traffic, experience regular traffic fluctuations, or meet the parameters for scaling up and down gradually.For some languages, building an application to run in the standard environment is more constrained and involved, but your applications will have faster scale up times.
The flexible environment is optimal for applications with the following characteristics:
• Source code that is written in a version of any of the supported programming languages: Python, Java, Node.js, Go, Ruby, PHP, or .NET
• Runs in a Docker container that includes a custom runtime or source code written in other programming languages.
• Depends on other software, including operating system packages such as imagemagick, ffmpeg, libgit2, or others through apt-get.
• Uses or depends on frameworks that include native code.
• Accesses the resources or services of your Cloud Platform project that reside in the Compute Engine network.
The standard environment is optimal for applications with the following characteristics:
• Source code is written in specific versions of the supported programming languages: Python 2.7, Python 3.7 (beta), Java 8, Java 7, Node.js 8 (beta), PHP 5.5, PHP 7.2 (beta), Go 1.6, 1.8, 1.9, and Go 1.11 (beta)
• Intended to run for free or at very low cost, where you pay only for what you need and when you need it. For example, your application can scale to 0 instances when there is no traffic.
• Experiences sudden and extreme spikes of traffic which require immediate scaling.

Applications running in the App Engine flexible environment are deployed to virtual machine types that you specify. You are billed for each of those instances according to Compute Engine’s pricing.

Applications running in the App Engine standard environment are deployed to instance classes that you specify, that have a cost per hour per instance.

General Features:

  • Fully managed serverless application platform
  • Wide Selection of Application Platforms; Java, PHP, Node.js, Python, C#, .Net, Ruby and Go and Docker to deploy your web applications.
  • Variety of Application Deployment Option (Cloud Source Repositories, IntelliJ IDEA, Visual Studio)
  • Monitoring, Logging, and Diagnostics
  • Application Versioning
  • Scaling
  • GCP Resources Customization
  • Traffic Splitting
  • Application Security

Google App Engine allows Scheduling Tasks With Cron for Python. The App Engine Cron Service allows you to configure regularly scheduled tasks that operate at defined times or regular intervals. This is a basic Batch service.

For more complex Batch you can use Google Data Flow. Cloud Dataflow is a fully-managed service for transforming and enriching data in stream (real time) and batch (historical) modes with equal reliability and expressiveness.

Google Data Flow features:

  • Based on Apache Beam (java & Python)
  • Automated Resource Management
  • Dynamic Work Rebalancing
  • Horizontal Auto-scaling

Applications running in the App Engine flexible environment are deployed to virtual machine types that you specify. You are billed for each of those instances according to Compute Engine’s pricing.

Applications running in the App Engine standard environment are deployed to instance classes that you specify, that have a cost per hour per instance.

Cloud Dataflow service usage is billed in per second increments, on a per job basis.

Google Functions

Language Runtimes

Cloud Functions can be written using JavaScript (Node.js 6-8-10), Python (Python 3.7.6), or Go (Go 1.11 and 1.13(beta)) runtimes on Google Cloud Platform with Ubuntu and Debian (for node.js 6).

Events and Triggers

  • HTTP—invoke functions directly via HTTP requests.
  • Cloud Storage
  • Cloud Pub/Sub
  • Cloud Firestore
  • Firebase (Realtime Database, Storage, Analytics, Auth)
  • Stackdriver Logging—forward log entries to a Pub/Sub topic by creating a sink. You can then trigger the function.

Timeout

Function execution time is limited by the timeout duration, which you can specify at function deployment time. A function times out after 1 minute by default, but you can extend this period up to 9 minutes. When function execution exceeds the timeout, an error status is immediately returned.

SLA

Monthly Uptime Percentage <= 99.5%

Billing Model

  • Invocations are charged at a per-unit rate, excluding the first 2 million free invocations per month and are charged regardless of the outcome of the function or its duration.
  • Compute time. Compute time is measured in 100ms increments, rounded up to the nearest increment.
  • Memory provisioned.
  • Outbound data transfer (that is, data transferred from your function out to somewhere else) is measured in GB and charged at a flat rate. Outbound data to other Google APIs in the same region is free, as is inbound data