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
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Oliver Drotbohm
September 04, 2014
Programming
360
0
Share
Whoops! Where did my architecture go?
Slides of the talk I held at 50th meeting of Java User Group Saxony. @springcentral
Oliver Drotbohm
September 04, 2014
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
810
Bottom-Up Architecture – Bridging the Achitecture Code Gap
olivergierke
4
1.1k
Spring Modulith – A Deep Dive
olivergierke
9
5.4k
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
書き換えて学ぶTemporal #fukts
pirosikick
2
380
エラー処理の温故知新 / history of error handling technic
ryotanakaya
7
1.9k
Skillは並べた。動かなかった。契約で繋いだ。— 65個のSkillから、自走する開発サイクルへ
junholee
0
680
「OSSがあるなら自作するな」は AI時代も正しいか ── Build vs Adopt の新しい判断基準
kumorn5s
7
2.9k
AIチームを指揮するOSS「TAKT」活用術 / How to Use “TAKT,” an OSS Tool for Orchestrating AI Teams
nrslib
2
400
20260514 - build with ai 2026 - build LINE Bot with Gemini CLI
line_developers_tw
PRO
0
460
権限チェックの一貫性を型で守る TypeScript による多層防御
mnch
3
340
Spec-Driven Development with AI-Agents: From High-Level Requirements to Working Software
antonarhipov
2
250
色即是空、空即是色、データサイエンス
kamoneggi
1
140
【ディップ|26年新卒研修資料】OpenAPI/Swagger REST API研修
dip_tech
PRO
0
270
要はバランスからの卒業 #yumemi_grow
kajitack
0
180
サーバーレスで作る、動画データ管理基盤
oyasumipants
0
230
Featured
See All Featured
Marketing to machines
jonoalderson
1
5.3k
Embracing the Ebb and Flow
colly
88
5k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
Why Our Code Smells
bkeepers
PRO
340
58k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.3k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.4k
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
End of SEO as We Know It (SMX Advanced Version)
ipullrank
3
4.2k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
Information Architects: The Missing Link in Design Systems
soysaucechin
0
930
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.2k
Transcript
Whoops! Where did my architecture go? Architecture management for Java
applications ! Oliver Gierke
None
None
None
Background 5 years of consulting Lots of code reviews Eoin
Woods‘ talk on InfoQ Lot of input from fellows
"If you think architecture is expensive, try no architecture.
Macro VS. Micro Architecture
Macro VS. Micro Architecture
None
Orders Inventory Billing
Orders Inventory Billing
Orders Inventory Billing Macro-Architecture JMS REST AMQP
Orders Inventory Billing Macro-Architecture Micro-Architecture JMS REST AMQP
JRuby Java Scala Macro-Architecture Micro-Architecture AMQP JMS REST
Neo4j RDBMS MongoDB Macro-Architecture Micro-Architecture from Stefan Tilkov - Breaking
the Monolith JMS REST AMQP
Roadmap Divide and conquer Of layers and slices A plain
Java based approach
Architecture 101
Know your dependencies
Explicit / Visible dependencies
Granularity Modules Layers Vertical slices Subsystems
Granularity Java ARchive Package Class
Divide and conquer
Component
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
"Meanwhile, in my friend’s project…
How do I add a feature?
How do I add a feature? New Feature © Eberhard
Wolff
Of layers and slices…
Presentation Service Data Access
Presentation Service Data Access Account Customer Core
Layers Well understood Known to developers Less important to business
Slices Hardly understood New to developers Key for business requirements
Presentation Service Data Access Account Customer Core
"How to implement an architecture inside a codebase?
Architecture VS. Codebase
"How to implement an architecture inside a codebase?
"How to implement an architecture inside a codebase?
"How to maintain an architecture inside a codebase?
Code analysis JDepend Sonar
Sonargraph Formerly known as SonarJ
Demo
jQAssistant http://github.com/buschmais/jqassistant
A plain Java based approach
"How far can we get with plain Java means only?
Presentation Service Data Access Account Customer Core
Packages
….layer.slice ….slice.layer ….slice
….web.core ….service.core ….repository.core
….core.web ….core.service ….core.repository
….core ….customer ….account
"Why the f#$k should I even care?
"Does it make a difference?
Dependency management
"You only need to manage, what you can refer to…
Layers first Leaks slice internals Lower layers visible to everyone
Slices first/only Start with package per slice Expose interfaces and
domain types Keep implementations private
Slices first/only Encapsulates business module Internals understood anyway
"Start with less packages and the least visibility possible…
Presentation Service Data Access Account Customer Core
Presentation Service Data Access Account Customer Core
Demo
Take-aways Know your dependencies On every granularity Start as strict
as possible Get lenient where necessary
Resources Spring Data JPA @ GitHub Sonargraph jQAssistant Blogpost
Sample Code http://github.com/olivergierke/ whoops-architecture
Oliver Gierke Spring Data Project Lead !
[email protected]
olivergierke www.olivergierke.de
Thanks & Credits Eoin Woods - Talk @ InfoQ Stefan
Tilkov - Talk @ InfoQ Eberhard Wolff - Slides @ Slideshare