Pages

Monday, May 21, 2012

The thin line between IaaS and PaaS

Over the years Cloud Computing has been distinguished by three models of offering namely Software as a Service (SaaS), Platform as a Service (PaaS) and Infrastructure as a Service (IaaS). The level of abstraction is in the same order where SaaS simply offers the software you can subscribe and start consuming it. SaaS is more for the end consumers. PaaS is more for developers where it abstracts the underlying infrastructure and you simply write code for the platform and rest is taken care by the platform service provider. In Facebook terms, you stay focused and keep shipping your code. Of course, platforms are tied to programming languages since the provider cannot provide the same level of abstraction for all languages. IaaS is further down the stack where the provider abstracts the underlying hardware but still provides the infrastructure components (such as compute, storage) as fundamental building blocks. You can then assemble them as per your needs. You need not worry about maintaining the infrastructure but still need to manage it actively.

The two main players in this space are Amazon Web Services (AWS) providing IaaS and Microsoft Azure providing .NET PaaS. OpenStack is also an emerging IaaS player but has a long way to catch up with AWS. You also have Google App Engine providing python and Java PaaS. Customers choose which way to go depending upon their needs. And when it comes to Cloud Computing AWS and Azure are the options that most of the customers evaluate. Though AWS and Azure are fundamentally different in their offerings, the line between IaaS and PaaS, off late, is shrinking. If you look at AWS, it primarily offers compute and storage as a service. But some of their other services is what makes this space very interesting.

Amazon RDS - this is the relational database service from AWS. You can provision MySQL, SQL Server and Oracle RDS Instances and start using them on a pay-as-you-go model. The entire database service is completely managed by Amazon. You don't need to worry about patching the OS or database; it is taken care by Amazon themselves. It also comes up with high availability and automated backups. And to use them, you don't need to change any single line of your existing code base. Just provision the database, import your data and change the database connection string in your app.

Amazon DynamoDB/SimpleDB - these are non relational or NoSQL database service from AWS. These are primarily key value stores offering read and write scalability. To use them, one needs to have an API level integration which means writing specific code to start using them.

AWS Elastic Beanstalk - Now this is a PaaS like offering from AWS. You write your code and generate the final deployment artifact. You then use Elastic Beanstalk to build the infrastructure that is required to host your application. You can do so from your IDE and using the toolkit (AWS Toolkit for Visual Studio or AWS Toolkit for Eclipse) you can manage your application deployment. This is very similar to a PaaS offering but with Elastic Beanstalk you still have control over the underlying infrastructure. You can modify or remove or add the elements that are powering up the infrastructure and still enjoy the benefits of abstraction that Elastic Beanstalk provides.

AWS Elastic Cache - this is a caching service available from AWS. A fully managed cache service built on top of EhCache. All you do is to provision and change the cache provider URL in your application to EhCache's. Rest is taken care by AWS.

Flip over to Azure

Now all of these services in addition to many others are available in Azure as well. But your choice of programming language has to be .NET. I haven't extensively worked with Azure but my understanding of Azure is that you would create an "Azure Project" in Visual Studio or convert an existing .NET project into an Azure Project. You will then have all the components - such as database (SQL Server), caching service, ESB within the project in Visual Studio itself. You will go ahead and build your application on top of these components and when you are ready to go live you will deploy them from Visual Studio itself. The rest of it is completely managed by Microsoft in terms of provisioning the required resources, managing them and maintaining them.

Some of the AWS services that we saw above reflects the same. Specifically Elastic Beanstalk. Beanstalk is very similar to Azure. But on closer look it actually is a wrapper around the fundamental blocks that AWS offers. Since AWS started its offering through Infrastructure components, it is fairly simple for them to build Beanstalk. They have come up with support for Java, .NET and PHP by simply wrapping over the necessary components. For example, Beanstalk for Java would be a wrapper over EC2 running Tomcat plus MySQL on RDS which are available to you as a normal service as well. Similarly, Beanstalk for .NET means Windows EC2 running IIS and SQL Server on RDS. Again available as a normal service from AWS. Like this, AWS can go ahead and build support for other languages such as RoR, python, etc...

And other services like DynamoDB, RDS, Elastic Cache, Simple Email Service (SES) can be called as services. But they already abstract more than what you expect from them. RDS is not a pure infrastructure building block by definition. It is one level up where an entire database is offered as a service, managed by AWS with automated backups and restoration points.

AWS continues to offer infrastructure components that it originally started off with. You will probably have more and more infrastructure components coming out of AWS and you can continue to build your infrastructure the way you wish to. It also offers pure play PaaS like solutions such as Elastic Beanstalk. It might continue to add support for more and more programming languages in coming days. In between these, you have services like RDS, Elastic Cache which are not raw infrastructure service and also not a PaaS like service. They are somewhere in between where certain overheads are taken away from you and you will still have some element of control. On the other hand, Azure, in addition to .NET, now offers support for Java, PHP and node.js. It might continue to evolve as a pure play PaaS solution but offering support for more languages in coming days.

Both AWS and Microsoft see a change in the way their services are consumed. What they started off with is not what their customers really wanted. And the line between their two different models of offering is slowly narrowing down. Both of them might evolve into a hybrid solution providers but might continue to remain as an IaaS and PaaS provider respectively. Again, it all depends on what the customers need end of the day and where majority of the customers are willing to place their bet. Whatever form they continue to offer, Cloud Computing is here to stay.

No comments: