serverless computing in the cloudWhat is serverless computing? The idea is growing in popularity, but the term honestly sounds like an oxymoron. How does it work, and why should you consider it for your IT organization?

Well, the name is a false promise–there are actually servers involved with serverless computing. They just aren’t managed by the organization. A serverless computing model means your cloud provider takes care of adding, removing, and/or adjusting your server resources based upon demand. You end up with a more accurate bill for your usage because it’s based literally on milliseconds, not hours. There are a couple of ideas behind this: One is to avoid prepaying for resources that might be unused, resulting in huge savings for your organization. The second is taking the burden of server management off of the developer’s hands, leaving them free to simply write code.

Serverless now

This sounds like something out of the future, but the truth is, the future is now. The big cloud providers (Amazon, Microsoft and Google) all offer serverless computing services, but Amazon’s Lambda is perhaps the most well-known. According to their website, “Lambda runs your code on high-availability compute infrastructure and performs all the administration of the compute resources, including server and operating system maintenance, capacity provisioning and automatic scaling, code and security patch deployment, and code monitoring and logging. All you need to do is supply the code.” This saves the developer time and effort in rewriting code to fit a specific infrastructure requirement, meaning applications can deploy faster and more accurately.

Serverless building blocks

The code that’s uploaded to AWS or Azure is known as a function. A function is an individual action or piece of logic. This tiny code unit is particularly useful for running jobs like these:

  • Scheduled, repeatable tasks
  • Web request processing
  • Processing queue messages

The entire function from beginning to end usually takes only milliseconds. It is these functions that form the building blocks of serverless architectures.

Where do containers fit in?

Containers are the latest “hot thing,” but is it possible that serverless computing will render containers obselete? As Michael Churchman of Rancher explains, probably not. “Serverless computing of the type represented by AWS Lambda can be an extremely valuable resource, … but it is far from being an all-around substitute for deploying and managing your own containers. Serverless computing is really designed to work with containers, rather than replacing them.”

What are some cases where containers might be a better fit? If your application is larger and more complex than AWS or Azure can handle, a container-based system can be as large and complex as you need. If you’re also looking for full control over the containers and the system on which they run, container-based deployment can do that. However, because serverless computing is run by a third party, you have no say in how it is run. For security and policy processes, serverless computing may not be a good fit. If you do decide to try your hand at serverless computing, a best practice is to start with new applications, rather than rewriting old ones to fit the model.

Serverless computing is a new developer-friendly offering that holds a lot of potential for cost savings and software deployment efficiency. It is not, however, a replacement for all infrastructure architectures, including containers or on-premise deployment. Again, as with all things IT, whether you use serverless computing or not depends on what your application and organizational needs are. If you want to work in a serverless environment, you will need to prepare for some changes.