Microservices
without Servers
Ashan Fernando
Why Managing Servers is Difficult?
• Provision & Manage
VM Instances
• Patching Operating
Systems
• Update Software
• Extra Effort to Handle Failures
Managing a Fleet of Microservices is Hard
What if you can build Microservice without
Servers?
• Fully Managed
• No provisioning
• Zero Administration
• High Availability
• Developer Productivity
• Focus on Code
• Innovate rapidly
• Reduce time to market
• Continuous Scaling
• Automatically
• Both Scale Up and Down
Credits: AWS Webniar Series
Lambda – Computation
API Gateway – API Management
S3 – File Storage & Delivery
CloudFront – CDN and Basic Routing
DynamoDB – NoSQL Database
Units of a Serverless Microservice in AWS
Serverless Microservice
Engine behind AWS Microservices
• Event-driven Compute Service
• Innovative cost model for
Execution Time
• Automatic scaling
• Currently supports
• Java, NodeJS & Python
AWS API Gateway Web Console
AWS Lambda Web Console
Using Serverless Framework
https://serverless.com/
Serverless Microservices
Case Study with Amazon Web Services
• Microservices written in NodeJS
• Web Application built with AngularJS
• Hybrid Mobile App built with Ionic Framework
• NoSQL Database using Amazon DynamoDB
Case Study with AWS
Simplified Architecture
Case Study with AWS
Serverless Microservices & Web App
1. Angular App
• Cloudfront
• S3
2. Microservices
• Cloudfront
• API Gateway
• Lambda
• DynamoDB
• SES
Case Study with AWS
Managed Microservices (Not Serverless)
• Lambda has its own limits
• Cold Start vs Hot Start
• Not fitting some use cases
• Services with dependencies
with large libraries
• Services with logic operated on
a single, medium to large
dataset
• Why Managed Docker?
Microservices without servers

Microservices without servers

  • 1.
  • 3.
    Why Managing Serversis Difficult? • Provision & Manage VM Instances • Patching Operating Systems • Update Software • Extra Effort to Handle Failures
  • 4.
    Managing a Fleetof Microservices is Hard
  • 5.
    What if youcan build Microservice without Servers? • Fully Managed • No provisioning • Zero Administration • High Availability • Developer Productivity • Focus on Code • Innovate rapidly • Reduce time to market • Continuous Scaling • Automatically • Both Scale Up and Down Credits: AWS Webniar Series
  • 6.
    Lambda – Computation APIGateway – API Management S3 – File Storage & Delivery CloudFront – CDN and Basic Routing DynamoDB – NoSQL Database Units of a Serverless Microservice in AWS Serverless Microservice
  • 7.
    Engine behind AWSMicroservices • Event-driven Compute Service • Innovative cost model for Execution Time • Automatic scaling • Currently supports • Java, NodeJS & Python
  • 8.
    AWS API GatewayWeb Console
  • 9.
  • 10.
  • 11.
    Serverless Microservices Case Studywith Amazon Web Services • Microservices written in NodeJS • Web Application built with AngularJS • Hybrid Mobile App built with Ionic Framework • NoSQL Database using Amazon DynamoDB
  • 12.
    Case Study withAWS Simplified Architecture
  • 13.
    Case Study withAWS Serverless Microservices & Web App 1. Angular App • Cloudfront • S3 2. Microservices • Cloudfront • API Gateway • Lambda • DynamoDB • SES
  • 14.
    Case Study withAWS Managed Microservices (Not Serverless) • Lambda has its own limits • Cold Start vs Hot Start • Not fitting some use cases • Services with dependencies with large libraries • Services with logic operated on a single, medium to large dataset • Why Managed Docker?

Editor's Notes

  • #3 As we all know and experienced, managing servers is a difficult task And when it comes to Microservice it can become even challenging
  • #4 So why managing servers is difficult? Even if we take a managed VM instance in Cloud there is an operational overhead We need to patch the operating systems and do Web Server, Database and other software updates time to time Even we need to do a certain level of capacity planning
  • #5 And when it comes to Microservices, it requires its own virtualized containers. Managing and Monitoring these containers becomes even challenging task because you can expect higher number of Microservices in a system And this creates friction when implementing Microservices with servers
  • #6 So you need to find infrastructure or platform where Microservices are fully managed with continuous scalling
  • #7 So we want to build Microservices without Servers and Lets see what are the Units of Serverless Its basically a set of Cloud Native Services, which we needs to wire up logically together to build a Microservice So I have listed couple of Cloud Native Services that we used to build our Microsrevices without Servers and of cause there are more
  • #8 Event-driven Compute Service Allows us to define amount of memory allocated to your code (Affects CPU & Network as well) Automatic scaling Currently supports Java, NodeJS, Python Pay only for the execution so you can keep multiple versions of lambda running
  • #13 This is the simplified architecture of a Web application we built with Angular and API with Microservices we built for a Norwegian Customer. It is Deployed in AWS Ireland Region. As you can see there is also and Mobile application developed with which consumes the Microservices.
  • #14 Section one is responsible to host the angular application and server it through CDN. Section two is the Microservices built with API Gateway and Lambda
  • #15 Apart from these you can use AWS Lambda for other usecases