Guide Refactorings With Behavioral Code Analysis
summary
Uses version‑control history to find high‑impact refactor targets: hotspots where large modules change often (Android’s activity manager service is 20k LOC touched by 74 contributors), method‑level X‑rays that flag a 500‑line handleMessage with 97 changes/year, and copy‑paste + change‑coupling to find true duplication in Linux drivers. Recommends lightweight measures like count indentations for language‑neutral complexity, and a splinter pattern (copy, delegate, extract) to refactor safely under heavy parallel contributions.
AI-written summary · about
chapters (15)
- 0:00Start
- 12:12What's Code Complexity Anyway?
- 15:18Case Study: Android
- 20:43Splinter: Resulting Context
- 21:28Cut The Middle Man
- 24:44Tooling: Try it on your own Code
- 26:17Code Duplication and DRY Violations
- 31:46Case Study: Code Clones in Linux
- 33:54Function Comparison
- 36:02Case Study: Refactoring Entity Framework Core
- 36:31Code Clones in Entity Framework - Refactor?
- 39:50The Proximity Refactoring
- 40:29Reducing Complex Inter-Dependencies
- 43:04X-Ray of the Coevolving Unit Tests
- 43:59Refactoring jUnit: Express Our Domain
related talks
39mArch. App: Prioritizing Technical Debt as if Time and Money Matters
32mPrioritizing Technical Debt as if Time and Money Matters
40mTreat Your Code as a Crime Scene
38mRefactoring in Android Studio
20mPrioritizing Technical Debt as if Time and Money Matters
30mPrioritizing Technical Debt as if Time and Money Matters
39m7 Secrets of Maintainable Codebases
49mTreat Your Code as a Crime Scene
