Skip to content

Cross-cutting concerns

Concept · Chapter 9

A concern is a grouping of logic or functionality the application provides; concerns map back to the system’s requirements. Architects should apply the Separation of Concerns (SoC) principle to keep concerns apart and reduce complexity.

TypeWhat it isWhere the logic lives
Core concernFunctionality fundamental to why the software exists (e.g. salary/bonus calculation in an HR system)Localized to specific components
Cross-cutting concernAn aspect that relies on and affects other concerns; used in many areas, often across layers (security, logging, caching, error handling)Needed across multiple components
  • Core concerns are localized; cross-cutting concerns intersect many core concerns.
  • Because cross-cutting logic is needed in many places, naive implementations tend to be duplicated across modules — the problem the rest of the chapter addresses.
  • Good design keeps cross-cutting concerns separate from core logic while still making them available wherever needed.
  • Software Architect’s Handbook (Packt, 2018), Ch.9 “Cross-cutting concerns”, pp. 691-692.