Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Serverless Architectures on AWS

DZone's Guide to

Serverless Architectures on AWS

Serverless is made for event-driven architectures. Dividing your app into functions and making use of microservices architecture are keys to success in the cloud.

· Cloud Zone
Free Resource

Production-proven Mesosphere DC/OS is now even better with GPU scheduling, pods, troubleshooting, enhanced security, and over 100+ integrated services deployed in one-click.

This article is featured in the new DZone Guide to the Cloud: Native Development and Deployment. Get your free copy for more insightful articles, industry statistics, and more!

A serverless platform allows you to run your application—including computing, storing, and networking —without the need for spinning up and managing a single (virtual) machine. This article focuses on serverless architectures on AWS including Lambda, API Gateway, DynamoDB, S3, and more. The architecture patterns can be transferred to other cloud platforms as well.

Being able to focus on software development instead of operating a fleet of servers is the primary driver behind serverless. Alternatively, as Werner Vogels, CTO of Amazon.com, says: “No server is easier to manage than no server.” Another important aspect of serverless infrastructure is finely granular billing and extreme scalability. To give you an impression of typical use cases, here are some serverless applications I have been working on recently:

  • Collecting metrics from web application with a REST API in a high load scenario.
  • Extracting and storing data from incoming emails containing order and status information.
  • Creating a REST API providing a standard CRUD backend.
  • Collecting and transforming data within an ETL process in a big data scenario.
  • Analyzing log messages from a real-time data stream.
  • Building a chatbot that is interacting with multiple APIs in the background.

Limitations

The ability to execute source code on a highly available and scalable infrastructure is the heart of every serverless platform. AWS Lambda, for example, allows you to run your source code in response to events. AWS provides the computing infrastructure and a runtime environment for JavaScript (Node.js), Java, Python, or .NET Core (C#). A typical serverless application consists of multiple functions. On AWS Lambda, there is an execution timeout of 5 minutes for every function execution. Nevertheless, you can execute the same or different functions in a highly parallel manner.

Dividing your application into small functions is necessary when following a serverless approach. Making use of microservice architectures helps you to achieve that goal. Serverless is made for event-driven architectures. An event is a source for triggering a serverless function and the glue when orchestrating multiple serverless functions forming a system.

Triggering a function with AWS Lambda is possible based on the following events:

  • Incoming HTTPS request.
  • Changing data stored in a database or object storage.
  • Incoming message (e.g. email).
  • Publishing a task to a topic or real-time data stream.
  • Scheduled event (comparable with a cronjob).

Read the rest of this article and a lot more in:Cloud Guide

DZone's Guide to the Cloud: Native Development and Deployment

Including:

  • Industry Research Data
  • Articles Written by Industry Experts
  • Cloud Architecture Infographic
  • Directory of the Best Tools & Solutions

Simply build, test, and deploy. Mesosphere DC/OS is the best way to run containers and big data anywhere offering production-proven flexibility and reliability.

Topics:
cloud ,serverless architecture ,aws lambda ,scalability

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}