Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Spring for the Architecturally Curious Developer
Search
Oliver Drotbohm
November 09, 2022
Programming
5
1.9k
Spring for the Architecturally Curious Developer
Oliver Drotbohm
November 09, 2022
Tweet
Share
More Decks by Oliver Drotbohm
See All by Oliver Drotbohm
What's new in Spring Modulith?
olivergierke
1
270
Domain-centric? Why Hexagonal and Onion Architecture Are Answers to the Wrong Question
olivergierke
4
1.9k
It Takes Two to Tango – Designing Module Interactions in Modulithic Spring Applications
olivergierke
5
790
Bottom-Up Architecture – Bridging the Achitecture Code Gap
olivergierke
4
1k
Spring Modulith – A Deep Dive
olivergierke
9
5.2k
Spring Boot 3 & Spring Framework 6
olivergierke
4
2.1k
Architecturally-evident Java Applications with jMolecules
olivergierke
9
3.1k
A Deep Dive into Spring Application Events
olivergierke
12
3.5k
Building Better Monoliths – Modulithic Applications with Spring Boot
olivergierke
4
1k
Other Decks in Programming
See All in Programming
LM Linkで(非力な!)ノートPCでローカルLLM
seosoft
0
220
Claude Codeログ基盤の構築
giginet
PRO
7
3.7k
モダンOBSプラグイン開発
umireon
0
180
The free-lunch guide to idea circularity
hollycummins
0
350
CS教育のDX AIによる育成の効率化
niftycorp
PRO
0
160
ファインチューニングせずメインコンペを解く方法
pokutuna
0
180
メッセージングを利用して時間的結合を分離しよう #phperkaigi
kajitack
3
330
S3ストレージクラスの「見える」「ある」「使える」は全部違う ─ 体験から見た、仕様の深淵を覗く
ya_ma23
0
1.1k
Codex CLIのSubagentsによる並列API実装 / Parallel API Implementation with Codex CLI Subagents
takatty
2
470
Nostalgia Meets Technology: Super Mario with TypeScript
manfredsteyer
PRO
0
110
AI活用のコスパを最大化する方法
ochtum
0
330
存在論的プログラミング: 時間と存在を記述する
koriym
5
500
Featured
See All Featured
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
75
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
150
Building Applications with DynamoDB
mza
96
7k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
Building Flexible Design Systems
yeseniaperezcruz
330
40k
Darren the Foodie - Storyboard
khoart
PRO
3
3k
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
1
1.5k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
52k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Transcript
SPRING FOR ARCHITECTURALLY CURIOUS DEVELOPERS Oliver Drotbohm
[email protected]
/ odrotbohm
None
Coming in 2023… Follow @mawspring on
The Domain
Orders Inventory Order Line items Stock Inventory items
Unfortunately, Post-its don't run in production…
Unfortunately, Post-its don't run in production… … except you work
at Miro.
None
None
Awesome! ! Now… what? "
Let's get started… src/main/java ….acme.myproject ….acme.myproject.domain ….acme.myproject.persistence ….acme.myproject.service ….acme.myproject.web
None
Let's get started… src/main/java ….acme.myproject ….acme.myproject.domain ….acme.myproject.persistence ….acme.myproject.service ….acme.myproject.web #$
via https://devopedia.org/cohesion-vs-coupling
Domain Based Structure Domain Based Boundaries via Dan North –
CUPID—for joyful coding Video cast episode @ Software Architektur im Stream (english)
src/main/java ….acme.myproject ….acme.myproject.customer ….acme.myproject.inventory ….acme.myproject.order Much better… %!
via https://devopedia.org/cohesion-vs-coupling
Web Business logic Data access @Repository Order Inventory … @Controller
@Service Verification? Testing? Documentation? Observation?
None
Sample code https://github.com/odrotbohm/arch-evident-spring
Demo time! &!
Error Scenarios Transactional Event Listeners
@EventListener @EventListener … @TransactionalEventListener @TransactionalEventListener … @Transactional Event Event Commit
Consistency boundary Spring bean Legend
Error scenarios
What if a transactional event listener fails? "
@EventListener @EventListener … @TransactionalEventListener @TransactionalEventListener … @Transactional Event Event Commit
Consistency boundary Spring bean Legend Publication lost! ) '(
Event Publication Registry
@TransactionalEventListener @TransactionalEventListener … Event @TransactionalEventListener … @TransactionalEventListener … Transaction Commit
Demo time! &!
Spring Modulith A convention to map modules to packages Simple
set of access rules and API to verify Test support to bootstrap modules Documentation support Observability support
Thank you! Questions? Oliver Drotbohm
[email protected]
odrotbohm Sample Code