Skip to content

Architecture drift: where the running system differs from the one you agreed.

Every team has an architecture it agreed on, in a diagram, an ADR or a Structurizr workspace. The running system diverges from it one pull request at a time: a service that reads another's database, a call that skips the gateway. Drift detection turns those into findings instead of surprises in review.

Updated

Two models: intended and observed

The observed model is the map drawn from traces. The intended model is what you meant: the components and the calls between them that are supposed to exist. Drift is the difference, computed again as the system changes.

Recording what you intended

There are two ways in. Accept the current map as intended, which records what runs today as the baseline you mean to keep. Or import a model you already have: Ritele reads a subset of Structurizr DSL (systems, containers and relationships), Mermaid flowcharts (A --> B, labelled edges and subgraph), and CSV rows of from,to,protocol.

What counts as drift

Six kinds of finding are reported against the intended model. Layers come from ritele.layer on the resource, in an order you set from outermost inward, so a call back outward becomes something the tool finds rather than something a reviewer has to notice.

  • Unexpected edge: a call the intended model does not have
  • Missing edge: a call the model has that has not been seen for a week
  • New component: one the model does not have, first seen in the last week
  • Disappeared component: one the model has that has not been seen for a week
  • Protocol change: a call made over a different protocol than the model says
  • Layer violation: a call from a deeper layer back out to an outer one, directly or through components with no layer

Working through findings

Each finding can be accepted, which writes it into the intended model, marked as a bug, snoozed, or left open until it resolves. A snooze lasts seven days; the drift check runs every 15 minutes, and the first run after the snooze ends reopens the finding if the difference still holds.

The map can be exported back out as Mermaid or Structurizr DSL, so the diagram in your repository can be regenerated from what runs.

Recording an intended model and triaging drift findings need a paid plan. The free plan covers the map, Health and tracing.