In this lecture, we're going to talk about the AWS Serverless Architecture.
Of course, we have covered it all already.
By now, you know all the foundation services that make up the AWS Serverless Architecture...
AWS Lambda, API Gateway and DynamoDB.
And there are additional services like S3, SNS, SQS and so on.
In this lecture however, we're going to make an attempt to look at the big picture.
We'll discuss how these different services can be used together to build different serverless
architecture patterns.
Before we dive into serverless architecture patterns, why don't we discuss the most common
architecture pattern that we find almost everywhere, irrespective of whether we are using servers
or going serverless.
It is the multi-tier architecture.
The most common form of multi-tier architecture is the three-tier Architecture.
The three-tier architecture, as the name suggests, has 3 tiers.
These are the Database or data tier, Application or Logic tier and the Frontend or the Presentation
tier.
Talking about the serverless applications, the serverless 3-tier applications will have the
same three tiers.
The data tier would contain the databases, like DynamoDB for example.
And you could also use other data stores as well.
The data stores fall into two categories, IAM enabled Data stores and VPC hosted Data
stores.
IAM enabled data stores allow you to connect to them directly using the AWS APIs.
These services include Amazon DynamoDB, S3, and Amazon ElasticSearch.
On the other hand, VPC hosted data stores allow you to connect to different databases
using database credentials.
These services run on hosted instances within a VPC.
These include Amazon RDS, Redshift, and ElastiCache.
And of course, you can install and run any database of your choice on EC2 and use it
here.
For example, you could run a MongoDB instance on EC2 if you wanted to, and then connect
to it through your Serverless Lambda functions.
The next tier is the Serverless Application Tier or the Serverless Logic Tier.
This is where the core business logic of your serverless application would run.
This is where the core serverless services like AWS Lambda and API Gateway come into play.
Finally, we have the Presentation Tier or the Frontend.
The frontend would interact with the backend through the Logic tier.
For example, frontend could use API Gateway endpoints to call Lambda functions, which
in turn interact with the data stores available in the Data Tier.
API endpoints can be consumed by variety of frontend applications.
These could be Web applications like static websites hosted on S3, for example.
We could also have mobile apps as the frontend.
Even voice-enabled devices like Alexa, or different IoT devices can also be used as
the frontend applications.
And all these services can connect to Lambda functions either through API Gateway endpoints,
or through any other event trigger.
And we are going to implement each of these applications later in the course as course projects.
So, you'll have a solid practical grasp on building different types of serverless application,
yourself.
Before we do that though, let's quickly discuss different architecture patterns in the next
few lectures.
So, let's continue to the next lecture.