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.7k
Spring for the Architecturally Curious Developer
Oliver Drotbohm
November 09, 2022
Tweet
Share
More Decks by Oliver Drotbohm
See All by Oliver Drotbohm
It Takes Two to Tango – Designing Module Interactions in Modulithic Spring Applications
olivergierke
4
450
Bottom-Up Architecture – Bridging the Achitecture Code Gap
olivergierke
4
730
Spring Modulith – A Deep Dive
olivergierke
7
3.8k
Spring Boot 3 & Spring Framework 6
olivergierke
4
1.9k
Architecturally-evident Java Applications with jMolecules
olivergierke
8
2.7k
A Deep Dive into Spring Application Events
olivergierke
12
3.1k
Building Better Monoliths – Modulithic Applications with Spring Boot
olivergierke
4
870
Spring HATEOAS – Hypermedia APIs with Spring
olivergierke
1
650
Building Better Monoliths – Modulithic Applications with Spring Boot
olivergierke
6
4.1k
Other Decks in Programming
See All in Programming
ECS Service Connectのこれまでのアップデートと今後のRoadmapを見てみる
tkikuc
2
250
Pinia Colada が実現するスマートな非同期処理
naokihaba
4
230
TypeScript Graph でコードレビューの心理的障壁を乗り越える
ysk8hori
3
1.2k
NSOutlineView何もわからん:( 前編 / I Don't Understand About NSOutlineView :( Pt. 1
usagimaru
0
340
レガシーシステムにどう立ち向かうか 複雑さと理想と現実/vs-legacy
suzukihoge
14
2.3k
Contemporary Test Cases
maaretp
0
140
Jakarta EE meets AI
ivargrimstad
0
630
카카오페이는 어떻게 수천만 결제를 처리할까? 우아한 결제 분산락 노하우
kakao
PRO
0
110
3rd party scriptでもReactを使いたい! Preact + Reactのハイブリッド開発
righttouch
PRO
1
610
C++でシェーダを書く
fadis
6
4.1k
Flutterを言い訳にしない!アプリの使い心地改善テクニック5選🔥
kno3a87
1
200
Generative AI Use Cases JP (略称:GenU)奮闘記
hideg
1
300
Featured
See All Featured
Product Roadmaps are Hard
iamctodd
PRO
49
11k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9.1k
Happy Clients
brianwarren
98
6.7k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Optimizing for Happiness
mojombo
376
70k
Designing Experiences People Love
moore
138
23k
The World Runs on Bad Software
bkeepers
PRO
65
11k
RailsConf 2023
tenderlove
29
900
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
191
16k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
246
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