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.8k
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
5
620
Bottom-Up Architecture – Bridging the Achitecture Code Gap
olivergierke
4
870
Spring Modulith – A Deep Dive
olivergierke
7
4.2k
Spring Boot 3 & Spring Framework 6
olivergierke
4
2k
Architecturally-evident Java Applications with jMolecules
olivergierke
8
2.8k
A Deep Dive into Spring Application Events
olivergierke
12
3.2k
Building Better Monoliths – Modulithic Applications with Spring Boot
olivergierke
4
940
Spring HATEOAS – Hypermedia APIs with Spring
olivergierke
1
720
Building Better Monoliths – Modulithic Applications with Spring Boot
olivergierke
6
4.2k
Other Decks in Programming
See All in Programming
趣味全開のAITuber開発
kokushin
0
200
PHP で学ぶ OAuth 入門
azuki
1
190
AHC045_解説
shun_pi
0
530
Unlock the Potential of Swift Code Generation
rockname
0
250
Vibe Coding の話をしよう
schroneko
2
370
スモールスタートで始めるためのLambda×モノリス(Lambdalith)
akihisaikeda
2
280
Agentic Applications with Symfony
el_stoffel
2
300
Kamal 2 – Get Out of the Cloud
aleksandrov
1
190
ComposeでWebアプリを作る技術
tbsten
0
110
SwiftUI API Design Lessons
niw
1
290
PHPで書いたAPIをGoに書き換えてみた 〜パフォーマンス改善の可能性を探る実験レポート〜
koguuum
0
160
Defying Front-End Inertia: Inertia.js on Rails
skryukov
0
480
Featured
See All Featured
Reflections from 52 weeks, 52 projects
jeffersonlam
349
20k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
120k
Product Roadmaps are Hard
iamctodd
PRO
52
11k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
1.6k
A better future with KSS
kneath
239
17k
The Pragmatic Product Professional
lauravandoore
33
6.5k
Fontdeck: Realign not Redesign
paulrobertlloyd
83
5.5k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
31
1.1k
VelocityConf: Rendering Performance Case Studies
addyosmani
328
24k
Building Better People: How to give real-time feedback that sticks.
wjessup
367
19k
4 Signs Your Business is Dying
shpigford
183
22k
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