The great thing about today’s PaaS offerings it is that they provide a great way to increase developer agility by allowing application teams to push out applications without having to be involved with the underlying infrastructure.
How this works is that the PaaS takes on the responsibility of deploying the application to a set of application nodes fronted by a web server and binding the application to a set of supporting services (Databases etc). Here a simple example for a Java application deployed within a PaaS:
If I write my application correctly and avoid state at the application server layer then I can simply get the PaaS to add more application server nodes dynamically.
There no real surprise here that at large scale the application will be bottlenecked at the database layer. Unfortunately many PaaS offerings consider the database as a supporting services and don’t offer a way of horizontally scale at the service layer. To be fair some PaaSs offer multiple databases instances for HA but this is not the same as horizontal consistent read and write scalability.
All is not lost, we are starting to see the raise of Database as a Service (DBaaS). It almost goes without saying that in order meet the requirements above you will need to use a database that scales horizontally. Examples of such services are MongoHQ and MongoLab.
Now instead of pointing my application to the embedded database within the PaaS, I simply point it to my DBaaS API.
The great thing about this is now I can dynamically horizontally scale both the application and database layer as required.
This is actually not that difficult to achieve as a PaaS will typically provide HTTP out and many DBaaS have a REST API.