Today’s guest post comes from Carter Maslan, CEO of Camio, a startup that converts real-time video into useful information.



I adore our dog Jane. She moved 3,000 miles away, but I still wake up to her ...
Today’s guest post comes from Carter Maslan, CEO of Camio, a startup that converts real-time video into useful information.



I adore our dog Jane. She moved 3,000 miles away, but I still wake up to her barking and pillow-fluffing. That's because our son shares his Camio feed with us. We get video alerts on the iPad he leaves behind as a pet monitor. These alerts come out of Camio’s AI technology, which includes hundreds of servers running neural nets competing to learn the exact moments our family wants to see. To riff on an old Google bumper sticker, "My other pet sitter is a data center" — or actually many data centers running Camio.



Camio is a cloud-based video monitoring service for watching, storing, analyzing and searching for real-time videos. It turns any camera into a smart home or business monitor, where real-time video is uploaded and saved in the cloud. Retailers can use Camio to watch and understand foot traffic in stores. Families can capture video from birthday parties and family reunions. Building owners protect offices from theft and vandalism. Care providers monitor elders living alone. Parents know at a glance when their kids get home or the dog sitter leaves.



People can use Camio to view live feeds and engage in auto-answering two-way chats for free, from anywhere in the world. They can also receive alerts when particular search conditions are met, such as when a car pulls into the driveway.



A huge technical challenge we had was to design and implement a highly scalable backend system for capturing, storing, retrieving and analyzing millions of videos — without building and managing our own servers. We wanted to spend every incremental engineering dollar on making the product great, instead of investing in infrastructure.



We had already been using Google App Engine, Google Compute Engine, Google Cloud Datastore and Google Cloud Storage, and then one of our engineers read about the Google Cloud Platform for Startups credit program. We asked one of our investors, Greylock Partners, to endorse our application to the program, which prompted us to explore Google BigQuery, Google Cloud Monitoring, Google Cloud Bigtable, Managed VMs and other services too.



As a result of being in the startup program, we were able to access valuable technical resources, including consultations with many of Google’s top engineers. The credits also allowed us to defer operating costs, so we could devote more resources to building our product.



We store videos in Cloud Storage, a high capacity, highly scalable storage solution ideal for working with extremely large data objects. The videos are processed by Compute Engine to identify patterns and events, and the metadata output from Compute Engine is indexed in Cloud Datastore, a NoSQL schemaless database for non-relational data. The videos themselves are delivered to users via App Engine. It’s all scalable, and able to grow as we grow.



There’s no advantage in our doing the things that Google does so well for us. Being maniacally focused on our product — that’s the road to success.



Posted by Carter Maslan, CEO, Camio

Every day, our customers log into the Cloud Console to manage resources running on Google Cloud Platform. Many of you spend a lot of time there, deploying, configuring and managing various aspects of the platform.
Every day, our customers log into the Cloud Console to manage resources running on Google Cloud Platform. Many of you spend a lot of time there, deploying, configuring and managing various aspects of the platform.



We’re excited to share a beta of the new UI design, which helps you focus on what matters most to you.









Highlights include:




  • Improved Navigation:


    • Global navigation: We’ve re-architected the navigation so that you can access features in several different ways. Open the menu to see all Cloud Platform offerings in one consolidated place or use the keyboard shortcut to quickly enter into search based navigation.



    • Local navigation: We’ve streamlined the navigation layout of each feature to allow complete focus within that space and maximized all screen real estate.




  • Search: Newly-added navigational search allows you to jump to any feature, page or API in the console from a persistent search box.



  • Customization: Focus the console to reflect only the services you actually use by “pinning” them to the top bar for fast one-click access from anywhere.







  • Increased visibility: Identify and address issues from a configurable dashboard of your resources and services.










The new console is in beta for a month until it’s released to general availability in late November. Please visit console.cloud.google.com, click the button at the top that reads, “Try the beta console,” and let us know what you think by using the feedback icon:



in the new UI.



-Posted by Stewart Fife, Product Manager, Google Cloud Platform

We know that you spend a lot of time trying to understand the log data generated by your systems and applications. Getting insights from logs to run a business can be challenging. Logs are often high volume and inherently noisy, making it difficult to monitor and find patterns of interest in an ad hoc manner.
We know that you spend a lot of time trying to understand the log data generated by your systems and applications. Getting insights from logs to run a business can be challenging. Logs are often high volume and inherently noisy, making it difficult to monitor and find patterns of interest in an ad hoc manner.



Today, we're happy to announce that we're bringing Google Cloud Logging and Google Cloud Monitoring closer together to help you gain better insights into your logs. As part of this, we have just launched the following Beta features:




  • Logs-based Metrics let you create a metric from a logs filter expression that you build in Cloud Logging. You can use these metrics to build dashboards and create alerting policies in Cloud Monitoring.

  • Advanced Logs Filters provide a rich filter syntax to select log entries and create logs-based metrics.

  • Charts to Logs allow you to quickly go from charts to the corresponding logs, where you can investigate and resolve issues.




Logs-based Metrics

You often want to be alerted when particular events occur, or occur at an elevated rate, or exceed a specified count. Existing monitoring tools do not allow you to easily connect your logs to your monitoring console. With this launch, Google Cloud Monitoring adds to its current out-of-the-box metrics the ability to use granular metrics from your logs.



Let’s look at an example. You’re running a particular Google App Engine module, "redis," and version, "walkshare3." You want to be alerted when that server is not able to fulfill HTTP requests due to a particular error. Your first step is to create a metric that counts the log entries from your app that show a 5XX status and contain the string "self.handle_exception." In Cloud Logging, you build a logs filter that shows just those log entries.



Select the metric icon



next to the filter bar and provide a name and description for your new metric:









You are not limited to looking at error logs. For example, you can create a metric that counts the number of requests for a particular URL:





Select the Metrics tab in Cloud Logging and view the metrics you created. Edit them, or go directly to Cloud Monitoring and use the metrics for charts and alerts. In addition to your user-defined logs metrics, you can use three built-in system metrics that count important logging events for each log:





To create an alert, select Create alert from metric. This takes you directly to the Cloud Monitoring dialog for creating alerting policies, where your metric is already inserted into the condition box (see below). In this example, you decide to set an alert if the number of 5XX errors your metric is tracking increases by more than 30% in a 15-minute period. Finish creating the alerting policy, choose a notification method, and you're done.





To create a chart that displays your logs-based metrics, use the Cloud Monitoring chart-creation tools. You will see your logs-based metrics listed alongside all the other metrics:





Our early access users are already getting value from the capability. Here is what one customer had to say:




We have been very pleased with the Logs-based Metrics solution. We were sitting on a lot of valuable log data but had been missing insights and there was no good way to gather metrics from them. We experimented with some open source solutions, but it's a lot of work to manage it for the amount of logs we produce. We like that Cloud Logging is a fully managed service with great performance, scalability and feature set. We can now add new metrics on a running production system which has helped us diagnose issues and monitor new signals." - Arjen van der Ende, Engineer at Q42



Advanced Logs Filters

The power of logs-based metrics is largely due to the new advanced logs filters in Cloud Logging. With these filters you can create complex Boolean tests and even select log entries from multiple log sources. The following advanced filter shows your tests for 5XX status and handler exception shown above:





The following example shows how to narrow down requests that have high latency. The filter shows requests with latency higher than 500ms:





Charts to Logs

We are also keenly aware of the cost of context-switching between monitoring and logging tools when you're trying to investigate an issue. So we're working hard to make it easy for you to drill down and navigate information naturally. Starting today, you can easily view the specific log entries that underlie events displayed in charts. We’ve added a link in chart menus that will take you to Cloud Logging to review relevant logs. For example, if you are seeing spikes in the Response Latency for App Engine and want to see details on the requests and handlers that have high latency, you can quickly go to a filtered view in the logs viewer:





This launch will help Developers and Ops administrators identify trends based on log data that they would have otherwise missed. It will help them solve problems faster by creating granular metrics and easily drilling down to logs when resolving an incident. These are key advances in our journey to make ops easy in the cloud and we look forward to sharing more with you soon!



We invite you to test out these new features, and welcome your feedback. Please send feedback through the Developers Console or directly at cloud-logging-feedback@google.com.



- Posted by Deepak Tiwari, Product Manager, Google Cloud Platform

Firebase is a platform for building Android, iOS and web-based mobile apps, offering real-time data storage and automatic synchronization across devices. But what about when you need to run backend processes on the data?
Firebase is a platform for building Android, iOS and web-based mobile apps, offering real-time data storage and automatic synchronization across devices. But what about when you need to run backend processes on the data?



By connecting an App Engine application to your Firebase database, you can perform complex logic on the data without having to manage synchronization and updates; Firebase handles that for you.



Updates in the Android client release of Firebase 2.4.0 make it easy to access a Firebase database from an App Engine application.









The tutorial, Use Firebase and Google App Engine in an Android App, walks you through the steps to create an Android app that stores a to-do list in Firebase, and uses backend logic running on App Engine to send daily reminder emails.



In the process of working through the tutorial, you’ll learn how to use the following technologies:




  • Firebase — a platform for building mobile apps, offering realtime data storage and synchronization, user authentication, and more.

  • Android Studio — an Android development environment based on IntelliJ IDEA.

  • Cloud Tools for Android Studio — a set of tools included with Android Studio, that integrate with Google Cloud Platform services.

  • Google App Engine — an environment for running application code in the cloud; Platform as a service (PaaS).




- Posted by Benjamin Wulfe, Firebase

In this blog post, you'll learn how to use Google Cloud Deployment Manager to simplify the deployment and configuration of your Puppet nodes. Deployment Manager and Puppet cover similar, complementary ground. Deployment Manager lets you provision, configure and manage your Google Cloud Platform resources, and Puppet lets you do the same for your servers and software. By combining these powerful tools, you can automate just about every aspect of your cloud-based application.
In this blog post, you'll learn how to use Google Cloud Deployment Manager to simplify the deployment and configuration of your Puppet nodes. Deployment Manager and Puppet cover similar, complementary ground. Deployment Manager lets you provision, configure and manage your Google Cloud Platform resources, and Puppet lets you do the same for your servers and software. By combining these powerful tools, you can automate just about every aspect of your cloud-based application.



The examples we’ll outline here use Google Compute Engine instances, which are billable resources. If you're new to Cloud Platform, you can work through the examples for free by signing up a free trial.




Install and configure the Google Cloud SDK


Before you jump in, install and configure the Google Cloud SDK. This tutorial uses the Cloud SDK's gcloud tool to run Deployment Manager deployments.




Set up a Puppet master


Start by creating a Puppet master instance. Compute Engine's Click-to-Deploy service makes this step easy. Just open Click-to-Deploy Puppet in the Developers Console, choose your project, and click the Deploy Puppet button. In a few minutes, your Puppet master instance will be ready.




Create a Deployment Manager configuration file


Now that your Puppet master instance has been deployed, you'll want to start connecting instances to it. To do so, you'll define a configuration file that Deployment Manager can use to automate the provisioning and configuration of new instances.



On your local machine, create a new Deployment Manager configuration file named web-server.yaml and populate it as follows. Replace (your_project) with your Developers Console project name, and replace (puppet_master_instance_name) with the name of your Puppet master instance (puppet1-puppet-master if you used the Click to Deploy default name):




resources:


- name: managed-by-puppet


 type: compute.v1.instance


 properties:


   zone: us-central1-f


   machineType: https://www.googleapis.com/compute/v1/projects/<your_project>/zones/us-central1-f/machineTypes/f1-micro


   disks:


   - deviceName: boot


     type: PERSISTENT


     boot: true


     autoDelete: true


     initializeParams:


       sourceImage: https://www.googleapis.com/compute/v1/projects/debian-cloud/global/images/debian-8-jessie-v20150818


   networkInterfaces:


   - network: https://www.googleapis.com/compute/v1/projects/<your_project>/global/networks/default


     accessConfigs:


     - name: External NAT


       type: ONE_TO_ONE_NAT


   tags:


     items:


       - http-server


   metadata:


     items:


     - key: startup-script


       value: |


         #!/bin/bash


         apt-get install -y puppet






         cat <<EOF >> /etc/puppet/puppet.conf


         


         [agent]


         server = <puppet_master_instance_name>


         EOF






         systemctl enable puppet

         systemctl restart puppet



When you run Deployment Manager using this template, Deployment Manager will create a new Debian-based f1-micro instance, then run the startup script defined by the startup-script attribute in the metadata section of the template. Here, the startup script is configured to perform the following actions:






  • Install Puppet

  • Edit the Puppet configuration file to point at your Puppet master instance

  • Connect your instance to the Puppet master instance as a Puppet node





Create and connect a new instance


Run the following command to create a deployment based on your Deployment Manager template:



$ gcloud deployment-manager deployments create managed-by-puppet --config web-server.yaml



You now have a new f1-micro instance that’s configured as a Puppet node. To create additional, identical deployments, simply rerun the above command, replacing managed-by-puppet with a new deployment name.




Approve the pending certificate request


Each Puppet node instance attempts to connect to the Puppet master instance by creating and sending a certificate request. Unfortunately, for security reasons, you cannot automate the approval of this certificate request; to register your Puppet node instance, you must approve its pending certificate request manually.



To approve a certificate request:


  1. Navigate to the VM Instances page in your Developers Console.

  2. Click the SSH button next to your Puppet master instance to connect to your instance via a browser-based SSH terminal.

  3. In the SSH terminal, run the following command to see a list of outstanding Puppet certificate requests:

    $ sudo puppet cert list                                             

    The output should be similar to the following, with only one request listed: [evan@puppet1-puppet-master c2d]# puppet cert list "managed-by-puppet.c..internal" (SHA256) 4D:B3:C2:33:38:

  4. Sign that request by running the following command, replacing (your_project) with your project name:

    $ sudo puppet cert sign                                                managed-by-puppet.c.(your_project).internal




Congratulations! You now have a running Puppet master instance and a Deployment Manager configuration that automatically connects newly deployed instances to the Puppet master.




Delete your deployment and Puppet master


Be sure to delete the deployment and Puppet master instances so you don’t continue to pay for the instances you're not using.



To delete your deployment:


  1. Navigate to the Deployments page in your Developers Console:



  2. Click the trash can icon next to the deployment.




To delete your Puppet master instance:


  1. Navigate to the VM Instances page in your Developers Console.

  2. Check the box next to your Puppet master instance.

  3. Click the Delete button at the top of the page.


-Posted by Evan Brown (@evandbrown), Solutions Architect

Today’s guest post comes from Mandhir Gidda, CTO UK at POSSIBLE London, a global digital agency that brings results-driven campaigns to some of the world’s most dynamic brands. In this post, Mandhir describes how POSSIBLE London, in partnership with Heineken, built the Heineken Rugby Studio as a go-to destination for content related to the Rugby World Cup in London, which runs September 18 to October 31. ...
Today’s guest post comes from Mandhir Gidda, CTO UK at POSSIBLE London, a global digital agency that brings results-driven campaigns to some of the world’s most dynamic brands. In this post, Mandhir describes how POSSIBLE London, in partnership with Heineken, built the Heineken Rugby Studio as a go-to destination for content related to the Rugby World Cup in London, which runs September 18 to October 31.



Over the last month, more than one and a half million people gathered at Somerset House, a sports center in the heart of London, with their faces painted in their national colors to cheer on their team in the Rugby World Cup. For those who can’t see the action in person, or who want to be part of an online experience too, Heineken created the Rugby Studio, a website that features live game broadcasts, exclusive interviews and interactive content.



On the site, people can respond to polls about things like which player they’d like to have a beer with or who they think is going to win the match. Former England captain Will Carling is hosting discussions about the games featuring Rugby World Cup Legends such as South Africa’s Rugby World Cup winning captain John Smit and former Australian captain Rocky Elsom.







Earlier this year, Heineken started planning the building and hosting of the website with my team at POSSIBLE London. The tournament was right around the corner, and we needed an efficient solution that scaled based on the load. In just eight weeks, a two-person team — a full-stack developer and one designer — built the Rugby Studio using Google App Engine and Firebase. App Engine acts as our centralized platform that automates content from multiple sources, while Firebase acts as our real-time content distribution platform for international markets, allowing us to target specific content based on the demographic.



App Engine’s ease of use allowed our developer and designer to work in close collaboration and truly mesh their ideas. For example, the designer brought a simple concept to the table, and the developer expanded that idea into something more elaborate since Google Cloud Platform gave them the speed and agility to do so. We did this with the tweet feature. We only wanted to publish tweets about the World Cup (#ItsYourCall) on the website, excluding all of the other posts published by the Heineken handle. Google Cloud Platform helped us provide relevant social content at scale. The content on Heineken’s social channels has received more than 24.4 million impressions.



It’s hard to predict what the traffic for the Rugby Studio would be at any one time, so we needed to prepare for large volumes and fluctuations. We can handle the fluctuating and demanding computing workload with App Engine and are confident that our thousands of users receive tweets, images, videos and other updates in real time – because when the score changes, fans want to know that instantly.



To date, more than 165,000 people have visited the Rugby Studio, and that number continues to grow as we get closer to the finals. We wouldn’t have been able to build, configure and host an application — and have the confidence that it could scale — without Google Cloud Platform.



- Posted by Mandhir Gidda, CTO UK, POSSIBLE London

Today’s guest bloggers are Lynn Langit – Independent Cloud and Big Data Architect named the Google Cloud Developer Expert for the past three years and recognized as an AWS Community Hero, Microsoft MVP (SQL Server), MongoDB Master and ACM Distinguished speaker – and David Haley, startup engineer and former Google Cloud team member who was the first engineer on the Google Cloud Platform Americas sales team. ...
Today’s guest bloggers are Lynn Langit – Independent Cloud and Big Data Architect named the Google Cloud Developer Expert for the past three years and recognized as an AWS Community Hero, Microsoft MVP (SQL Server), MongoDB Master and ACM Distinguished speaker – and David Haley, startup engineer and former Google Cloud team member who was the first engineer on the Google Cloud Platform Americas sales team.




Validating 4 Million TPS using AerospikeDB with only 20 GCE nodes




In this post I’ll summarize what I learned from running benchmark tests with the Aerospike team using Google Cloud Platform (GCP) virtual machines. In doing this work, I independently validated their latest benchmark test results of up to 4 Million Transactions Per Second (TPS) on a single Aerospike cluster. These results are significantly faster than the previous December 2014 benchmark, which showed 1 million write transactions per second with 50 servers and 1 million reads per second with 10 servers.



Aerospike is a powerful open source NoSQL database. It’s known for both speed and scale, and is often used for session storage, advertising profiles, recent financial transactions, caching and other fast key value uses. Aerospike is built to be extremely fast by leveraging SSDs for persistence and includes automatic scalability. It’s also multi-threaded and written in C.



In the December 2014 benchmark, a 1 million read per second configuration was quoted as $11.40 per hour (about $8300/month). With the configurations used in this updated performance test, 4 million reads per second required 20 n1-standard-8 instances at $0.304 per hour each ($4499.20/month). An improvement of four times the performance at half the price was measured.



I reached out to Google and learned they profile their products and optimize their software regularly. The changes impacting Aerospike were a drastic reduction in network latency, achieved through a new interrupt handler, and huge pages support on the host OS. Changes to the host OS are not possible for customers, so having Google doing this regularly is a good thing.



For the benchmark tests, I tested the most common use case – using Aerospike as a simple key-value store, using in-memory (DRAM) data storage with synchronous replication. Individual key-value requests are individual network transactions, and neither batching nor pipelining are used. I used Compute Engine VM’s for this test run and the steps to reproduce these results are included.




New Benchmark Validated – TL; DR – 6 Simple Steps to Speed




In validating results, I found ease of implementation to be a key differentiator between Aerospike and other NoSQL databases for large-scale loads. This matched nicely with the speed, ease and scale of Compute Engine. For example, I was able to use default settings on Compute Engine instances – no manual tuning or special setup in GCP was required. Combine a blazingly fast cloud with a blindingly fast NoSQL database for powerful results.




About Aerospike Scaling:







  • Aerospike handles the equivalent of sharding automatically.

  • There’s no downtime. You can add new capacity (data volume and throughput) dynamically. Simply add additional nodes and Aerospike will automatically rebalance the data and traffic.

  • You set the replication factor to 2 or more and configure Aerospike to operate with synchronous replication for immediate consistency and durability.

  • If a server goes down, Aerospike handles failover transparently; the Aerospike client makes sure that your application can read or write replicated data automatically.

  • You can run purely in RAM, or take advantage of Flash/SSDs for storage. Using Flash/SSDs results in a slight penalty on latency (~0.1ms longer on average), but allows you to scale with significantly smaller clusters and at a fraction of the cost.







Benchmark Testing on GCE – TL; DR – look ma’ it’s fast




One of the reasons I’ve been doing more and more Big Data project work on Compute Engine is due to its raw performance. As mentioned, I was pleasantly surprised at the lack of manual configuration I had to do to validate this benchmark. It was basically, ‘plug it in, turn it on…and go.’ I’ll cover details about the instance types and sizes in subsequent sections, but this lack of need to twist and turn obscure (cloud) knobs, is significant. This is because simplicity results not only in reproducibility, but also more importantly, general productivity. Your team can get started quickly and can then move on to other work, such as adding features to your solution, without having to spend time tweaking Compute Engine instance settings.



That being said, I find that reproducing vendor benchmarks on any public cloud requires some attention to detail. The environment is obviously different than on premises. Also beyond basic setup, performance-tuning techniques vary from those I’ve used for on-premise and also from cloud-to-cloud solutions. In addition to covering the steps to do this, I’ve also included a list of technical links at the end of this blog post. These links include the Github repository with the complete script and config files that I used to run this series of tests.




Setup to Test Aerospike on Compute Engine





Step One


SETUP Compute Engine Environment. Best practice when testing is to properly setup a dedicated test environment. To do this on Compute Engine, sign in or create a user account (https://cloud.google.com/). Next access the GCP console and create a new GCP project. Note the project name. Then download and install the GCP SDK (https://cloud.google.com/sdk/); this will give you access to the gcloud command-line tool.



















Note: To replicate the 4 million TPS benchmark, you’ll need to enable project billing and then request an increase in the default quota limits for a GCP project, as you’ll need to increase the default CPUs/project limit from 24 to 160.





To do this, from within your new project in the GCP console > Compute > Compute Engine > Quotas and then click on the "Change Request" link at the top of the page. Fill out the form and click send. It generally takes around 24 hours for this type of request to be processed.




















Step Two








SETUP Compute Engine instances for the Aerospike server cluster. We’ll start by setting up an Aerospike cluster that can handle 4 million TPS. You can, of course, reproduce this testing with the level of benchmark that is appropriate to your projected workload value.



To reproduce the Aerospike team’s results, I used 20 GCE Linux instances for the server cluster. I used n1-standard-8 instances types. Each instance has 8 CPUs and 30 GB of memory.



For each instance I used Google’s standard GCE Debian GNU/Linux boot disk version 7.8 (shown left). I selected this number of this type of instances because this configuration uses common instance types.





Additionally, I used the GCE image that the Aerospike team prepared as the base image for each node in my cluster, which is based on Google’s Debian image. This image contained a default installation of Aerospike server, Aerospike AMC (Aerospike Management Console) and the Aerospike Java client.



The Aerospike Java client includes the Aerospike benchmark-testing tool. I’ve included instructions on how to create this base image in the text box below.











LOGIN to your Google Cloud account. Open a terminal window; create a working directory and cd into that directory. Set your account value and then use the gcloud auth login command to connect.



SETUP variable values as for your test. Be sure to replace the (your-project-name) value with the name of your particular project instance. I set the value of "USE_PERSISTANT_DISK" to 0 to perform an in-memory only test. You could set it to "1" if you wished to test using persistent disks.



CREATE 20 GCE instances for your Aerospike server cluster using the gcloud compute instances create command. I used a custom Aerospike image as a basis for creating each node. The full script can also create persistent disks if you choose to run your benchmark test with persistence. Note the use of the "tag" flag to identify these instances as the Aerospike server nodes.










Step Three


UPDATE the Aerospike config files. To create the cluster, update the Aerospike config files to use the correct IP address for the mesh address. (See the references section at the end of this post for a link to Aerospike configuration file that I used). You can use the default configuration file settings so long as your cluster uses 32 or fewer nodes.




Step Four


SETUP Compute Engine instances for the Aerospike client VMs. To perform the test at the scale for benchmark validation, I created 20 client GCE VMs. For the benchmark work, we chose machine types of n1-highcpu-8 because the benchmark tool workload uses 256 threads in order to appropriately saturate the server nodes. I used the same custom image with Aerospike pre-installed to create the clients as I used when creating Aerospike server nodes and identified these nodes via the tag value “benchmark-client.”




Step Five


CREATE AEROSPIKE CLUSTER by booting the servers: Start the asd daemon on each server using the aerospike.config file. You run lines 64-74 to complete this task, also shown below.










Step Six


Start the AMC (GUI) Console: Although the Aerospike benchmark tool does generate text-based (log) output, I find that "seeing" the power via the Aerospike Management Console (GUI) is a fun part of testing. A portion of a sample AMC console is shown above.



To connect to the AMC console, you’ll need to find the public IP of "as-server-1" and then open a browser using http://(public_IP_of_server-1):8081. Next you’ll enter the private (internal) IP in the dialog box that opens on top of the AMC as follows: http://(internal_IP_of_server-1):3000
You may need to create firewall rules to open these ports. To do so, on the GCP console for your project, click on COMPUTE > Firewalls and then create the rules to open ports 3000 and 8081.




Run Tests using the Benchmark Tools


The Java client for Aerospike includes the Aerospike benchmark testing tools. Because we installed the Java client on our base image, all client instances include the benchmark tools – we simply need to “turn on the tool” to perform a load test. There are a number of parameters that you can use with the benchmark tool (detailed at the end of this section). To perform the test, I set the load parameters to 1 Million Keys and 256 client threads. Run the test. First l generated the load for the insert benchmark, and then I ran the test with a different load type.



Shown below is the first result in the AMC – it’s actually considerably MORE than previous 1 Million TPS – it’s 4 Million! Of note is that only 50 GB (of the total available 350 GB) of RAM available to the cluster is being used for this workload. This first test uses 100% reads for the workload.










For this next test, I ran the benchmark tool with the configuration set to 100% WRITES. This test resulted in a 1 Million TPS as shown in the AMC console image below. Again, of interest, is that only 50 GB (of the total 350 GB) or RAM is being used to run this workload. 







Benchmark Tool Script Details




The host in the “-h” option of the benchmark tool must be used to test against the Aerospike host node. Benchmark options used in the current tests were:



  • 10 million keys (-k 10000000)

  • 50 byte string values for each key (-o S: 50) – 150 byte into 3 bins + key -> 200 byte objects

  • 3 bins or columns each of size 50 and insert key size of 20 bytes (-b 3 -l 20)

  • Two different loads:


    • 100% write (-w I)

    • 100% read (-w RU, 100)


  • Before every test run, data was populated using the insert workload option (-w I

  • For each client instance, 256 threads give the maximum throughput in the in-memory database case (-z 256). 

  • For more about benchmark flags, use benchmarks -help







Clean Up


When you’ve completed your testing, you’ll want to stop the test. You may also want to stop the Aerospike servers, delete disks and shutdown all VM instances. Run the referenced script from line 130 to the end (line 165) to stop the benchmark tests, stop all of the servers, delete all disks and shutdown all instances.




Conclusions and Next Steps




I found the combination of Aerospike and GCP to be a winner for these reasons:



  1. Powerful, scalable NoSQL Database – I was able to set up and test with ease

  2. Quick setup and low cost to test – for this configuration the cost looks to be around 4k/month – this is for up to 4 million reads per SECOND, many customers won’t need this much power, so running fewer servers would reduce costs

  3. Flexibility of cloud platform – scaling up or down is trivial given the sharding of Aerospike and the speed of working with Compute Engine VMs




In further work, I can see myself testing with different quantities of Compute Engine instances of different sizes. The key is to understand requirement and then test to validate, for example “can I run a workload of (n) speed with (n) number of servers, to further simplify management and thereby reduce overall cost?" Also, I could alter the test parameters to match whatever type(s) of real-world workloads I need. For example, I may test a common 80% read, 20% write mixed workload as client requests dictate in the future.



Note: On Compute Engine Machine Types. I chose the n1-standard-8 series of instances, as these are “middle-of-the-road” instance types and provide a good instance-to-value ratio. Of course, Compute Engine offers a variety of instance sizes and types – a grid summarizing choices is shown below.





Additionally, I'm curious about comparing the ease-of-setup between Compute and Container Engine for Aerospike. I’ll continue to work with the team to report on subsequent test results.




References