Dapr 101:
start building
distributed apps
with ease
Slide 2
Slide 2 text
2
Azure MVP
Dapr Community
Manager
❤️ pixel art
Marc Duiker
Sr Dev Advocate
marc@diagrid.io
Slide 3
Slide 3 text
3
Slide 4
Slide 4 text
4
Demos!
What is
Dapr?
When to
use Dapr?
Why use
Dapr?
Q&A +
swag
Slide 5
Slide 5 text
What is Dapr?
5
Slide 6
Slide 6 text
6
E-commerce system
State
Management
Email Payment
Front-end
Shipping
Checkout
Inventory
Cart
Internet
Queue
I just want to
trace my calls
end-to-end.
How do I encrypt
calls with ongoing
cert rotation?
How do applications
discover and call
each other?
How do I handle
failed calls and
perform retries?
How do I secure
access to my
data layer?
How do I handle
state conflicts
from multiple
apps?
How do I
measure latency
on my database?
How do I
orchestrate
business logic
transactions?
How do I send
messages to many
applications?
Developer
challenges
Slide 7
Slide 7 text
7
Distributed
application
runtime
Slide 8
Slide 8 text
Dapr is a portable, event-
driven, runtime for building
distributed applications across
cloud and edge.
8
Slide 9
Slide 9 text
9
virtual or
physical machines
Slide 10
Slide 10 text
10
Why use Dapr?
Slide 11
Slide 11 text
Speeds up microservice
development by providing
a common set of building
block APIs.
11
Slide 12
Slide 12 text
12
Service
invocation
State
Management
Publish &
subscribe
Bindings
(input & output)
Actors Secret
Stores
Configuration
Observability
Workflows
Distributed Lock
Building block APIs
Slide 13
Slide 13 text
13
HTTP/gRPC
Dapr API
Dapr sidecar
Application
App
Slide 14
Slide 14 text
14
POST http://localhost:3500/v1.0/invoke/cart/method/order
GET http://localhost:3500/v1.0/state/inventory/item67
POST http://localhost:3500/v1.0/publish/order
GET http://localhost:3500/v1.0/secrets/vault/password42
POST http://localhost:3500/v1.0-alpha1/workflows/dapr/businessprocess/1234/start
HTTP/gRPC
Dapr API
App
Slide 15
Slide 15 text
15
Python
Java
Script
Java
Go
Client
SDKs
C#
Slide 16
Slide 16 text
16
10th largest
CNCF project
Submitted
to CNCF
Nov 2021
Incubation
maturity
level
www.cncf.io/projects/dapr/
Dapr project
30
Unified API with flexibility
at the component level.
Slide 31
Slide 31 text
31
Is Dapr a service mesh?
Slide 32
Slide 32 text
32
No.
Slide 33
Slide 33 text
33
Dapr & service mesh similarities:
Distributed
Tracing
Secure
Communication
Metric
Collection
Slide 34
Slide 34 text
34
Developer centric
docs.dapr.io/concepts/service-mesh/
Building block APIs & components
Infrastructure centric
Service
mesh
≠
Network traffic & Routing
Slide 35
Slide 35 text
When to use Dapr?
35
Slide 36
Slide 36 text
36
You are in a large organisation
with many different teams or
tech stacks.
Slide 37
Slide 37 text
Greenfield projects: postpone
your architecture decisions.
37
Slide 38
Slide 38 text
When not to use Dapr?
38
Slide 39
Slide 39 text
39
If your team is allergic to
containers & Kubernetes ;)
Slide 40
Slide 40 text
Building block demos
40
github.com/dapr/quickstarts
Slide 41
Slide 41 text
41
Service
invocation
Checkout
Order
processor
POST
Slide 42
Slide 42 text
42
Publish &
subscribe
Checkout
Order
processor
Slide 43
Slide 43 text
43
State
Management
Redis
Order
processor
Slide 44
Slide 44 text
44
The workflow engine
Slide 45
Slide 45 text
45
Your
Workflow
App
Workflow
engine
Append-only
state store
Slide 46
Slide 46 text
46
Your
Workflow
App
Contains definition of
a sequence of
activities
Schedules and manages
activity executions
(incl resiliency)
Contains workflow
state, input and
outputs of activities