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
Re-Architecting Applications (Without a Rewrite!)
Search
Daniel Lew
February 10, 2018
Programming
2.9k
8
Share
Re-Architecting Applications (Without a Rewrite!)
Talk given at DevFestMN 2018 & MinneBar 13.
Recording here:
https://youtu.be/dKm7MKoxVIg
Daniel Lew
February 10, 2018
More Decks by Daniel Lew
See All by Daniel Lew
How to Use Computers (Privately!)
dlew
0
83
Finding Meaningful, Mission-Driven Work
dlew
0
180
Things Maybe You Don't Know as a Newer Developer
dlew
1
140
Maintaining Software Correctness
dlew
4
1k
Grokking Coroutines (MinneBar)
dlew
5
670
ClimateChangeTech.pdf
dlew
0
160
What Tech Can Do About Climate Change
dlew
0
660
Grokking Coroutines
dlew
5
1.4k
Automated Tests Aren't Enough
dlew
0
540
Other Decks in Programming
See All in Programming
iOS機能開発のAI環境と起きた変化
ryunakayama
0
180
ルールルルルルRubyの中身の予備知識 ── RubyKaigiの前に予習しなイカ?
ydah
1
170
The Monolith Strikes Back: Why AI Agents ❤️ Rails Monoliths
serradura
0
320
의존성 주입과 모듈화
fornewid
0
130
ふりがな Deep Dive try! Swift Tokyo 2026
watura
0
210
GNU Makeの使い方 / How to use GNU Make
kaityo256
PRO
16
5.6k
Coding at the Speed of Thought: The New Era of Symfony Docker
dunglas
0
4.9k
mruby on C#: From VM Implementation to Game Scripting (RubyKaigi 2026)
hadashia
1
210
Don't Prompt Harder, Structure Better
kitasuke
0
740
飯MCP
yusukebe
0
500
PHPのバージョンアップ時にも役立ったAST(2026年版)
matsuo_atsushi
0
310
Kubernetes上でAgentを動かすための最新動向と押さえるべき概念まとめ
sotamaki0421
3
490
Featured
See All Featured
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
220
Joys of Absence: A Defence of Solitary Play
codingconduct
1
350
The Limits of Empathy - UXLibs8
cassininazir
1
300
Discover your Explorer Soul
emna__ayadi
2
1.1k
How to Think Like a Performance Engineer
csswizardry
28
2.5k
Into the Great Unknown - MozCon
thekraken
40
2.3k
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
2
1.4k
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
740
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
How to build a perfect <img>
jonoalderson
1
5.4k
Building the Perfect Custom Keyboard
takai
2
730
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
118
110k
Transcript
Re-architecting Applications (Without a Rewrite!) @danlew42
architecture: the structure and design of a system or product
None
None
None
None
None
“Model-View- Controller is the best thing since sliced bread.” ~Evil
Dan Lew
“OMG, I’m switching to MVC ASAP!” ~You Stability Some New
Architecture
Danger • Pure architectures require fresh code • Rewrites always
take longer than expected • Old code == battle tested • Expectations may not match reality
Goals • Introduce new architectures to existing codebase • Push
releases while re-architecting codebase
None
</Housing Metaphors>
Goal #1: Introduce new architectures to existing codebase
Re-Architecting Safely • Prevent overly ambitious rewrites • Prevent regrettable
architecture choices • Steps • Explore • Experiment • Expand • Embrace
Explore • What is the problem? • Define goals •
Define constraints • What are the solutions? • Brainstorm • Research
Experiment • Pick a project • Minimize work • Small
project • Simplified implementations • Minimize damage • Self-contained project • Unimportant project
Expand • Run more experiments • Pick projects wisely •
Use architecture in new ways • Pick hardest problems • Stretch architecture to limits
Embrace • Write all new code with new architecture •
Deprecate old architecture • Delete old code (optional)
Disclaimer Not an exact science
Goal #2: Push releases while re-architecting codebase
Can’t simultaneously use old and new architecture Can’t keep releasing
Old New Old + New
Parallel Development
Decouple Code BAD GOOD
Feature Flags
Shims
Shims
Offline Mode A parallel development success story
Online Only Offline Enabled
Decoupling Services Before After
Feature Flags
Shims Before After
Offline Mode • Project length: 1.5 years • Never stopped
releasing • Minimal UI changes • Gradual experimentation via flags • Switched over without anyone noticing • https://tech.trello.com/sync-architecture/
Failures With real life examples!
Explore Failures • Architecting with no purpose • Navi •
Choosing new and shiny without understanding • RxJava
Experiment Failures • Making the experiment too large • JavaScript:
The Good Parts • Not recognizing a failed experiment • Operations
Expand Failures • Choosing only easy problems • Identifiers •
Not recognizing a failed corner case • RxLifecycle
Embrace Failures • Continuing to expend effort on old architecture
• Fresh boards
Pet Peeve Telling everyone about an architecture before proving it
out!
Current Architecture Thoughts
Omni Models • Single model • Deserialized from JSON •
Written to ORM • Used by UI • Problems • Which fields are present? • How do we avoid mutability issues?
Domain-specific models • ApiModel • Only used when talking to
server • DbModel • Mutable, flexible • UiModel • Immutable, guarantees values • ApiModel <-> DbModel <-> UiModel
Unidirectional Architecture
Thanks for listening! @danlew42