1
Docker NYC Meetup
Docker native Functions-as-a-Service and Microservices
From payroll and benefits to performance management and career growth, our products work seamlessly with your company’s unique needs
and culture.
HR Operating System
Global | Scalable | Secure | Compliant | Single-DB | Pre-Integrated
Lifion Apps
Pre-Integrated | Flexible & Customizable | Consumer-grade UX
EMPLOYEE APPS
My Pay My Benefits
HR APPS
NOTE: this is a representative sample of available apps
My Performance and more Time & Attendance BenefitsOrg Management Payroll and more
We’re building a global, scalable platform with
a comprehensive set of HR applications.
LIFION
Who am I?
Srdjan Strbanovic
Principal Architect
twitter: @djidja8
Lets talk… Lifion has great open positions for great engineers!
Plan
Why Docker
Why Microservices
Why Functions-as-a-Service
How
5
Docker native Functions-as-a-Service and Microservices
Why Docker?
we are at the Docker NYC MeetUp
enough said,
let’s get going….
6
Docker native Functions-as-a-Service and Microservices
Why Microservices?
organized around common business capabilities
smaller and focused compared to SOA
Enables the following capabilities at the service level:
- development
- deployment, updates
- runtime tuning
- isolation
- auto-scaling
Monolith
Microservices
7
Docker native Functions-as-a-Service and Microservices
How to decompose an application into services?
Important strategies to consider:
- Bounded Context
- Value Streams
- Failure Domains
- Anti-corruption Layers
- Single Responsibility Principle
* No Directly Shared Data - only via APIs
Monolith
Microservices
?
—->
8
Docker native Functions-as-a-Service and Microservices
Product 

Catalog
Order 

Management
Customer DB
Ext APIAPI GatewayWeb App
Decomposing to Bounded Context
9
Docker native Functions-as-a-Service and Microservices
Customer
Prospect
Customer
Lead
Defector
Decomposing to Bounded Context
10
Docker native Functions-as-a-Service and Microservices
Why Functions-as-a-Service?
organized around behaviors
smaller and even more focused compared to Microservices
Same benefits as Microservices, but at the function level:
- deployment, updates, replacements
- runtime tuning
- isolation
- auto-scaling
Monolith
Microservices Functions
11
Docker native Functions-as-a-Service and Microservices
Product

Catalog
Order

Management
Customer DB
Ext APIAPI GatewayWeb App
12
Docker native Functions-as-a-Service and Microservices
Summary: FaaS & Microservices have similar benefits but at different granularity level
FaaS reduces cost and provides a more granular level of isolation at runtime
Downside: more complicated at development time?
read more
13
Docker native Functions-as-a-Service and Microservices
Challenge: How do we organize FaaS development?
Possible solution:
- decompose to microservices first, utilizing Bounded Context,
- expose all Aggregate Roots as resources
- each HTTP method for each resource becomes independent function-as-a-service
- use “monorepo” to keep development in one place but enable independent deployment
- select tools that hide the complexity and de-risk vendor lock-in
14
Docker native Functions-as-a-Service and Microservices
Tooling support
Amazon, Azure, Google all have offers in this space, but Open Source options can prevent lock-in:
- Serverless Framework
- Apex
- (Open) Faas
- CloudiaJS
- … many more: https://github.com/anaibol/awesome-serverless
15
Docker native Functions-as-a-Service and Microservices
Demo time: (Open)FaaS - an open-source framework for building serverless functions with Docker
Author:
• Ease of use, CLI available (as a separate project)
• Use any language and deploy standard Docker/OCI image
• No lock-in - runs anywhere Docker does
• Built in Auto-scaling
16
Docker native Functions-as-a-Service and Microservices
Demo time: App Store for a SaaS platform using (Open) FaaS
Domain model:
App:						{	id:	string,	name:	string,	categoryId:	string,	platformRelease:	string,	version:	string,	status:	string	}	
Category:	{	id:	string,	name:	string,	Description:	string	}	
API: GetAll, GetById, Publish, Upgrade, Retire
Repo organization, build & deploy
Auto-scaling, UI
17
Docker native Functions-as-a-Service and Microservices

Docker meetup-nyc-v1

  • 1.
    1 Docker NYC Meetup Dockernative Functions-as-a-Service and Microservices
  • 2.
    From payroll andbenefits to performance management and career growth, our products work seamlessly with your company’s unique needs and culture. HR Operating System Global | Scalable | Secure | Compliant | Single-DB | Pre-Integrated Lifion Apps Pre-Integrated | Flexible & Customizable | Consumer-grade UX EMPLOYEE APPS My Pay My Benefits HR APPS NOTE: this is a representative sample of available apps My Performance and more Time & Attendance BenefitsOrg Management Payroll and more We’re building a global, scalable platform with a comprehensive set of HR applications. LIFION
  • 3.
    Who am I? SrdjanStrbanovic Principal Architect twitter: @djidja8 Lets talk… Lifion has great open positions for great engineers!
  • 4.
    Plan Why Docker Why Microservices WhyFunctions-as-a-Service How
  • 5.
    5 Docker native Functions-as-a-Serviceand Microservices Why Docker? we are at the Docker NYC MeetUp enough said, let’s get going….
  • 6.
    6 Docker native Functions-as-a-Serviceand Microservices Why Microservices? organized around common business capabilities smaller and focused compared to SOA Enables the following capabilities at the service level: - development - deployment, updates - runtime tuning - isolation - auto-scaling Monolith Microservices
  • 7.
    7 Docker native Functions-as-a-Serviceand Microservices How to decompose an application into services? Important strategies to consider: - Bounded Context - Value Streams - Failure Domains - Anti-corruption Layers - Single Responsibility Principle * No Directly Shared Data - only via APIs Monolith Microservices ? —->
  • 8.
    8 Docker native Functions-as-a-Serviceand Microservices Product Catalog Order Management Customer DB Ext APIAPI GatewayWeb App Decomposing to Bounded Context
  • 9.
    9 Docker native Functions-as-a-Serviceand Microservices Customer Prospect Customer Lead Defector Decomposing to Bounded Context
  • 10.
    10 Docker native Functions-as-a-Serviceand Microservices Why Functions-as-a-Service? organized around behaviors smaller and even more focused compared to Microservices Same benefits as Microservices, but at the function level: - deployment, updates, replacements - runtime tuning - isolation - auto-scaling Monolith Microservices Functions
  • 11.
    11 Docker native Functions-as-a-Serviceand Microservices Product Catalog Order Management Customer DB Ext APIAPI GatewayWeb App
  • 12.
    12 Docker native Functions-as-a-Serviceand Microservices Summary: FaaS & Microservices have similar benefits but at different granularity level FaaS reduces cost and provides a more granular level of isolation at runtime Downside: more complicated at development time? read more
  • 13.
    13 Docker native Functions-as-a-Serviceand Microservices Challenge: How do we organize FaaS development? Possible solution: - decompose to microservices first, utilizing Bounded Context, - expose all Aggregate Roots as resources - each HTTP method for each resource becomes independent function-as-a-service - use “monorepo” to keep development in one place but enable independent deployment - select tools that hide the complexity and de-risk vendor lock-in
  • 14.
    14 Docker native Functions-as-a-Serviceand Microservices Tooling support Amazon, Azure, Google all have offers in this space, but Open Source options can prevent lock-in: - Serverless Framework - Apex - (Open) Faas - CloudiaJS - … many more: https://github.com/anaibol/awesome-serverless
  • 15.
    15 Docker native Functions-as-a-Serviceand Microservices Demo time: (Open)FaaS - an open-source framework for building serverless functions with Docker Author: • Ease of use, CLI available (as a separate project) • Use any language and deploy standard Docker/OCI image • No lock-in - runs anywhere Docker does • Built in Auto-scaling
  • 16.
    16 Docker native Functions-as-a-Serviceand Microservices Demo time: App Store for a SaaS platform using (Open) FaaS Domain model: App: { id: string, name: string, categoryId: string, platformRelease: string, version: string, status: string } Category: { id: string, name: string, Description: string } API: GetAll, GetById, Publish, Upgrade, Retire Repo organization, build & deploy Auto-scaling, UI
  • 17.