Argus.Analyses.Supervision (Panoptes v0.13.0)

Copy Markdown View Source

Supervision tree analysis.

Detects anti-patterns in supervision tree structure: permanent processes depending on transient or temporary siblings (which their restart policy can leave permanently dead), and children started in the wrong order relative to their dependencies. Cross-branch coupling under one_for_one is the one_for_one_coupling analysis's job — the two do not overlap.

Requires the supervision and OTP domain extractors for layer 2 facts about supervisor children, restart strategies, and behaviour implementations.

Output relations

  • suspect_nonpermanent_dependency(sup, permanent, sibling, restart, sup_site, witness) — permanent child depends on a transient or temporary sibling.
  • permanent_child_stops_normally(sup, child, reason, site, sup_site) — a permanent child returns {:stop, :normal | :shutdown, ...} and is restarted by its supervisor.
  • rest_for_one_orphaned_children(sup, owner, holder, owner_pos, holder_pos, site, confidence) — under rest_for_one a later child starts processes inside an earlier one, which survives the owner's restart.
  • wrong_start_order(sup, child, dep, child_pos, dep_pos, sup_site, witness) — child starts before its dependency.

Finding severities

Both relations are :warning: each is a structural hazard that bites during crash/restart windows rather than a guaranteed failure in steady state.