Working to extend our cloud with Sonian

Within the last article, I detailed how cloud vendors continue to extend the value of a cloud with their applications.  However, the value of a cloud ecosystem goes well beyond the simplicity of “base cloud features” plus vendor X’s application; the value extends all the way into anything that a vendor creates.  In this article, we detail what happens when you combine three major forces against an enterprise class cloud:

The three forces that this article combines are:

  • Extremely agile web languages, re-invented for the 21st Century:  In this example, it’s the Ruby programming language.
  • Open-source licensing:  Enabling a larger base of users and opening the source to the community.
  • An agile ISV mentality applied against the former two points

The primary reason these three items are so powerful when applied together is the agility that they create.  Many times, vendors are reliant on their base of users to create something larger than what they had, but don’t have the ability to easily extend.  IBM would surely have difficulties in creating X different sets of APIs and SDKs to integration against its portal in every given language, so it fosters hotbeds of development within the communities in hopes that vendors will cross-collaborate and use the success and work of others as a catalyst to their own success.  The recent work of the data-archival SaaS works named Sonian is one piece of technology that I would like to highlight because it uses the three major forces and has already seen success in the Fog community by their work to extend the cross-cloud library.

It’s undeniable that a cloud vendor must embrace new languages and new ways to ingest.  In a recent RedMonk article from February 2012 (http://redmonk.com/sogrady/2012/02/08/language-rankings-2-2012/), Stephen O’Grady took a clever snapshot of the changing programming landscape by plotting the popularity of GitHub projects versus and Stack Overflow tags.  I believe this somewhat accurately depicted the usage and modern languages and reassured myself that these top languages (Java, PHP, JavaScript, Python, Ruby) were serious contenders to support in the cloud space.  While nothing more than a reassurance to many, the article does a good job depicting that indeed these languages are prevalent in programming and the open model should support them for innovation.  As enterprises have continued the focus on Java (J2EE), Perl and PHP, I do believe that python and Ruby will continue to progress as a new equal for enterprises hoping to become cloud agile. The reinvention of Ruby for cloud is prevalent and active in the minds of our ISVs, so the work done by Sonian will have good success toward enabling our vendors.

To further my point on cloud-vendor relationships with ISVs, as the success of major cloud vendors will continue to be pushed by the value through innovation of their ecosystems, this Sonian example of extending a multi-cloud library is a true sign of collaboration.  By extending a multi-cloud library (done in Ruby) to support numerous cloud vendors, Sonian facilitates healthy competition between vendors and reduces the cloud lock-in dynamic to produce truly open and healthy relationships with the vendors.  In the following article, I have once again spoken with Joe Kinsella of Sonian about Sonian’s movement to the IBM cloud and Sonian’s identification of a necessity within its ecosystem.  The collaboration, originally started by Sonian and based on the open API specification of IBM cloud, has occurred between two great IBM ecosystem members and produced two IBM cloud-ready vendors that have given back to the technical community.

Ruby in the SmartCloud
By Joe Kinsella

When Sonian first moved to the IBM SmartCloud, we were surprised to find there was no Ruby language binding for the REST API. Ruby, a dynamic object-oriented programming language commonly used in web applications, is heavily used today by development operations teams (DevOps) to automate and manage cloud infrastructure. Our DevOps team at Sonian has made heavy usage of Ruby and Chef to reliably and efficiently operate thousands of cores and petabytes of storage across multiple clouds.

Not surprisingly, our first project in porting to IBM was to implement IBM SmartCloud support for Ruby. We decided to implement our support in the open source library Fog, which is a popular gem in the Ruby and DevOps communities. In collaboration with SugarCRM, we completed the initial implementation in February, and our changes were released end of March 2012 with version 1.3.1.

With the Ruby Fog gem, you can programmatically provision and deprovision instances, volumes, and images, and perform a variety of the other administrative operations useful to managing cloud infrastructure. Although the current version is fairly comprehensive, it can always be extended and improved by the community through the Fog project on GitHub. The MIT license provides flexibility of use for all development and deployment needs.

The following simple example is of using Ruby and Fog to create a new 32-bit Copper instance in the Raleigh data center running SUSE Linux. To run this example, ensure you have installed Ruby and Fog.

Note: we have added to the verbosity of the code to demonstrate a few of the commonly used methods.

#!/usr/bin/env ruby

require ‘rubygems’
require ‘fog’

# These will be specific to your account
USER_NAME = ‘your-email’
PASSWORD = ‘your-password’
KEY_NAME = ‘your-keyname’

# Name for your new instance
instance_name = ‘your-fog-test-instance’

compute = Fog::Compute.new(
 :provider => ‘IBM’,
 :ibm_username => USER_NAME,
 :ibm_password => PASSWORD
)

# Find the Raleigh data center
location = compute.locations.select {|loc| loc.name == ‘Raleigh, U.S.A’}.first

# Use the image id for Suse Linux 32 bit from Asset Catalog
image = compute.images.get(’20010001′)

# Choose the 32-bit Copper image from the list of available instances for this image
instance_type = image.supported_instance_types.select {|img| img.label == ‘Copper 32 bit’}.first

# Retrieve the public key used to access this instance
key = compute.keys.get(KEY_NAME)

# Create the instance
instance = compute.servers.new(
 :name => instance_name,
 :image_id => image.id,
 :instance_type => instance_type.id,
 :location_id => location.id,
 :key_name => key.name
)

# Launch the instance
instance.save

# Wait for instance to be launched
instance.wait_for { ready? }

We hope others in the community take advantage of the power of Ruby in managing the IBM SmartCloud. In a world of “infrastructure as code,” Ruby and IBM SmartCloud can be an indispensible tool to your success in the cloud.
____________________________________________________________________

Author details
Joe Kinsella biography

Joe Kinsella is Vice President of Engineering for Sonian. He has 20+ years experience delivering commercial software for both startups and large enterprises. He joined Sonian from Dell, where he managed global engineering teams delivering SaaS solutions. Joe was also Vice President of Engineering at SilverBack Technologies, where he helped pioneer remote management software, which was acquired by Dell in 2007. You can also follow Joe on Twitter or his High Tech in the Hub blog.

Share
Comments: 1
Jeff Klink

About Jeff Klink

Jeff Klink is a senior technical staff member (STSM) with IBM Canada. For the past 10 years, Jeff has focused on large-scale solution design and practice with a primary focus on software as a service for solution vendors and managed service providers. Currently, Jeff serves as the worldwide lead for the IBM Global Cloud Ecosystem architecture team, which evangelizes and solutions on top of the SoftLayer and SCE+ infrastructure as a service platforms.
This entry was posted in Managing the Cloud, SaaS and tagged , , , , , , , , , , , . Bookmark the permalink.

One Response to Working to extend our cloud with Sonian

  1. Jeff Klink Jeff Klink says:

    The active # of users now looking at the Ruby Fog gem adaptation produced by Sonian is growing. Check out Github if you're consider integrating against Smart Cloud with Ruby!

Comments are closed.