ancestor-descendant-participants
An Element and its own ancestor are both participants of a Dynamic View.
Severity: error · Since: v1.0.0
What check reports
Section titled “What check reports”For the failing example below, archidocs check prints:
shop/services.yaml:29:28 error ancestor-descendant-participants Service "shop:cart" and its descendant "shop:cart-api" are both participantsThe same example also reports missing-step.
A Dynamic View tells its scenario with each Element at one level. With a Service and one of its own Components both taking part, the same software appears twice in the sequence chart, and a reader can’t tell which of the two a Step really reaches.
Failing example
Section titled “Failing example”shop/services.yaml:
services: web: name: Web relationships: - to: cart cart: name: Cart components: cart-api: name: Cart API orders: name: Orders events: name: Events type: broker mailer: name: Mailer relationships: - to: orders interaction: async via: events channel: order-placedviews: dynamic: purchase: title: Purchase participants: [cart] steps: - { from: web, to: cart-api }Tell the scenario at one level: use the ancestor throughout, or its descendants throughout.
shop/services.yaml:
services: web: name: Web relationships: - to: cart cart: name: Cart components: cart-api: name: Cart API orders: name: Orders events: name: Events type: broker mailer: name: Mailer relationships: - to: orders interaction: async via: events channel: order-placedviews: dynamic: purchase: title: Purchase participants: [cart] steps: - { from: web, to: cart }Related rules
Section titled “Related rules”ancestor-descendant-relationship: An Element is linked to its own ancestor or descendant.missing-step: A Dynamic View Step has no Relationship or derived edge betweenfromandto(nor aviasubscription oftotofrom), or the namedrelationshipdoesn’t connect them.
Documents the beta branch at cd98671, ahead of the latest release, v1.4.0.