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
Whoops! Where did my architecture go?
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Oliver Drotbohm
October 13, 2016
Programming
790
2
Share
Whoops! Where did my architecture go?
Slides of the talk I gave at GOTO London, 2016.
Oliver Drotbohm
October 13, 2016
More Decks by Oliver Drotbohm
See All by Oliver Drotbohm
What's new in Spring Modulith?
olivergierke
1
300
Domain-centric? Why Hexagonal and Onion Architecture Are Answers to the Wrong Question
olivergierke
4
2k
It Takes Two to Tango – Designing Module Interactions in Modulithic Spring Applications
olivergierke
5
820
Bottom-Up Architecture – Bridging the Achitecture Code Gap
olivergierke
4
1.1k
Spring Modulith – A Deep Dive
olivergierke
9
5.5k
Spring for the Architecturally Curious Developer
olivergierke
5
1.9k
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
Other Decks in Programming
See All in Programming
ECR拡張スキャンでSBOMを収集して サプライチェーン攻撃の影響調査を 爆速で終わらせてみた
akihisaikeda
2
200
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
230
Hive Metastoreを通して学ぶIceberg REST Catalog ― 仕様から実装まで
okumin
0
280
Claspは野良GASの夢をみるか
takter00
0
120
Migrations : C'est une question d'hygiène !
vinceamstoutz
0
2.2k
ふつうのFeature Flag実践入門
irof
6
2.9k
Composerを使ったサプライチェーン攻撃の様子を眺めてみる #phpstudy
o0h
PRO
2
160
Swiftのレキシカルスコープ管理
kntkymt
0
190
AI時代だからこそ「Bloc」を採用する価値があるのかもしれない
takuroabe
0
240
Transactional Change Stream Processing With Debezium and Apache Flink
gunnarmorling
1
130
脅威をエンジニアリングの糧にして――現場編 / Turning Threats into Engineering Fuel — Field Edition
nrslib
0
180
ユニットテストの先へ:テスト技法で要求・仕様を整理するJava開発実践 / Beyond_Unit_Testing_Practical_Java_Development_Techniques_for_Organizing_Requirements_and_Specifications
shimashima35
0
220
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
225
10k
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.5k
The Pragmatic Product Professional
lauravandoore
37
7.3k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.5k
Unsuck your backbone
ammeep
672
58k
Marketing to machines
jonoalderson
1
5.3k
How to Ace a Technical Interview
jacobian
281
24k
The Curse of the Amulet
leimatthew05
1
12k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2.3k
The Cult of Friendly URLs
andyhume
79
6.9k
GraphQLとの向き合い方2022年版
quramy
50
15k
Transcript
Whoops! Where did my architecture go? In between a monolith
and a system of systems mess… / @olivergierke
None
None
Background Consulting & engineering @ Pivotal Lots of code reviews
Eoin Woods‘ talk on InfoQ
Roadmap Divide and conquer Of layers and slices The modular
monolith
Divide and conquer
Component Single unit to understand
Component Single unit to change
Component Scope of risk of change
B Smaller unit to understand A
B Reduced risk of change A
B Cost of separation A
B Definition and maintenance of dependencies A
Of layers and slices…
Presentation Service Data Access Billing Inventory Order
Layers Well understood Known to developers Less important to business
Slices Hardly understood New to developers Key for business requirements
Presentation Service Data Access Billing Inventory Order
Monolith VS. System of Systems
Monolith VS. System of Systems Order Inventory Billing Order Inventory
Billing
In-process calls VS. Inter-process calls Order Inventory Billing Order Inventory
Billing
Performance? Overhead? Error scenarios? Order Inventory Billing Order Inventory Billing
" If you can’t build a modular monolith, why do
you think microservices are the answer? — Simon Brown
How to manage modularity in different architectural contexts?
Means to enforce context boundaries? Order Inventory Billing Order Inventory
Billing
The modular monolith
How to implement a modular monolith?
How to maintain a modular monolith?
Bounded Context all the things! Domain-Driven Design is a great
idea! Surprise! In a monolith, too!
Architecturally- evident code
Code analysis jDepend Sonarcube Structure 101 / Sonargraph jQAssistant
A plain Java based approach
How to write code that’s less likely to deteoriate?
Presentation Service Data Access Billing Inventory Orders
Packages
….layer.slice ….slice.layer ….slice
….web.core ….service.core ….repository.core
….core.web ….core.service ….core.repository
….core ….customer ….account
Does it make a difference?
Dependency management
Orders Inventory Billing Orders Inventory Billing
A rule violation is just an @Inject away! Orders Inventory
Billing
You only need to manage what you can refer to…
Layers first Leaks slice internals Lower layers visible to everyone
Needs to be public :( Allows other code to circumvent
business logic
Slices only Keeps technical division private Encapsulates business module Internals
understood anyway
All package protected Compiler induced dependency control
Presentation Service Data Access Billing Inventory Order
Presentation Service Data Access Billing Inventory Order
Resources Blogpost Sonargraph jQAssistant Spring Data JPA @ GitHub
Sample Code http://github.com/olivergierke/ whoops-architecture
Thanks & Credits Eoin Woods — Talk @ InfoQ Stefan
Tilkov — Talk @ InfoQ