Asynchronous Processing
with Outbox Pattern
in .NET Core 3.0
Baris Ceviz
Software Developer @ Trendyol
@PeaceCwz
https://barisceviz.com/
Slide 2
Slide 2 text
Agenda
•What’s the outbox pattern?
•Why we should implement Outbox
pattern?
•Implementation of outbox pattern in
.NET Core
•Lessons learned in Trendyol
Slide 3
Slide 3 text
What’s the
Outbox Pattern
Slide 4
Slide 4 text
Traditional Processing
Referer: Microsoft docus https://bit.ly/ove32r
Slide 5
Slide 5 text
Producing
message with
Outbox pattern
End Insert transaction of published
message
Publis
h
Publish event message to
Event bus
Begin Insert transaction of event
message
Slide 6
Slide 6 text
Outbox Pattern
Referer: Microsoft docus https://bit.ly/ove32r
Slide 7
Slide 7 text
Consuming
message with
Outbox pattern
End Update execution status of
consumed message
Execut
e
Execute event message with
your business logic
Begin Insert status of event message
Slide 8
Slide 8 text
Outbox Pattern
Referer: Microsoft docus https://bit.ly/ove32r
Slide 9
Slide 9 text
•Guaranteed Delivery
•Able to re-trigger failed
process
•At-least-once Delivery
Outbox Pattern
Slide 10
Slide 10 text
Outbox Pattern
with CAP
in .NET Core
Slide 11
Slide 11 text
CAP Library
Slide 12
Slide 12 text
CAP
Slide 13
Slide 13 text
CAP
Slide 14
Slide 14 text
CAP
Slide 15
Slide 15 text
CAP
Slide 16
Slide 16 text
CAP
Slide 17
Slide 17 text
CAP
Slide 18
Slide 18 text
CAP
Slide 19
Slide 19 text
CAP
Slide 20
Slide 20 text
Example Project: Minerva
Slide 21
Slide 21 text
Lessons Learned
in
Trendyol
Slide 22
Slide 22 text
•Latency
•Performance poor
•Implementation is clear
Slide 23
Slide 23 text
May the source
be with you
Baris Ceviz
Software Developer @ Trendyol
@PeaceCwz
https://barisceviz.com/
[email protected]