Reverse-engineering Architecture Diagrams
summary
A workflow that actually generates component-level C4 diagrams by scanning compiled Java classes and optionally the source produces clear, maintainable output: it uses Structurizr DSL with a component-finder powered by Apache BCEL, applies annotation/name-suffix/package rules to identify components (e.g. six controllers and matching repositories in the Spring PetClinic demo), requires binaries and can read javadoc for descriptions, emits links to GitHub, exports interactive graphs (igraph/D3) and slices per-controller, and demonstrably improves code structure when reversed.
AI-written summary · about
chapters (14)
- 0:00Introduction
- 3:53C4 model levels
- 7:03Challenges in component diagrams
- 9:53Model-code gap
- 11:20Architecturally evident coding
- 15:11Automating component diagrams
- 22:41Live demo: components
- 29:04Adding styling and descriptions
- 32:59Hyperlinking to source
- 34:25Large codebases with visualizations
- 38:00Exporting to Isograph
- 39:05Primary and supporting types
- 43:18Observations and implications
- 45:24Q&A
related talks
50mVisualise, Document & Explore Your Software Architecture
57mVisualise, document and explore your software architecture
42mSoftware Architecture vs Code
46mSoftware Architecture vs Code
51mDiagrams as code 2.0
01h 00mVisualise, document and explore your software architecture
15mC4 Model, the Solution to Standardize My Architecture Diagrams?
01h 00mC4 models as code
