Durability is the capacity of software to remain understandable, useful, resilient, and dependable as requirements, technologies, runtime conditions, and users change. It begins with a sound design rather than accumulated quick fixes, then extends through resilience, testing, and stable public contracts. section 1.1.7 section 9.0
Build durability in reinforcing layers:
- Separate concerns so architecture, modules, and domain rules can change without collapsing into one another. section 9.1
- Keep cohesion high and coupling low to limit the ripple effect of change. section 9.5
- Use resilience to withstand traffic spikes, misuse, attacks, and transient failures. section 9.0
- Use automated tests and continuous integration to preserve behavior while the system evolves. section 9.5
- Protect users with minimal, stable public interfaces, clear response models, documentation, deprecation notices, and semantic versioning. section 9.4 section 9.5
String city = null;
if (user != null && user.getAddress() != null
&& user.getAddress().getCity() != null) {
city = user.getAddress().getCity();
} else {
city = "Unknown";
}
Nested null checks make defensive plumbing dominate the business intent and increase fragility. section 1.3
String city = Optional.ofNullable(user)
.map(User::getAddress)
.map(Address::getCity)
.orElse("Unknown");
Explicitly modeling absence expresses the same lookup more clearly and supports safer evolution. section 1.3
Figure 9.1 Layers of durability
The layers model connects implementation, operability, testing, and external stability as a unified durability strategy. section 9.0





