Kirk Rader  1.0-SNAPSHOT
Cruft-Free Sofware Quality Metric


Let the cruft-free quotient, $\mathbb{C}_f$, be

\[ \mathbb{C}_f = { 1 \over { F + P_i + P_c } } \]

where $F$ is the number of dependencies on third-party frameworks and libraries at run time, $P_i$ is the number of IDE plugins in use and $P_c$ the number of build-time plugins in your CI pipeline.

The lower the value of $\mathbb{C}_f$, the lower the quality of your code while noting that

\[ { \lim_{n \to 0} { 1 \over n } } = \infty \]

(as embodied, for example, by the IEEE 754 specification for floating-point arithmetic in digital computation since the preceding is simply the inverse of ${ \lim_{n \to \infty} { 1 \over n } } = 0$).

Note that only IDE and build-time plugins that affect the output of the build process without any explicit changes to the source code count toward $\mathbb{C}_f$. E.g. plugins that support interactive refactoring or that invoke automated unit and integration tests do not count toward $\mathbb{C}_f$ while Lombok does.


The rationale behind the definition of $\mathbb{C}_f$ is simple: frameworks and plugins that "magically" alter code are only safe to use by highly experienced developers for whom they offer the least benefit and to whom they simply represent bloat and impediments to debugging by decoupling behavior from representation in the software's source code.

This includes wildly popular frameworks like Spring.