Sequence

The one picture the ordinary machinery could not hold. Everywhere else a connector attaches to a SHAPE; here the second axis is time, and a message attaches to a point partway down a lifeline - a place no mark exists at. So the geometry is computed, as <isometric>'s is. Note the third message: it runs from Browser straight to Postgres, THROUGH the API lifeline. That is correct here and is exactly what the obstacle-avoiding router would have refused to do. A <note> takes a row of its own, so it lands between the messages it was written between rather than beside them.

Diagrams 438 × 490 <actor><message><note><sequence>

Result

Source examples/sequence.svgn

<diagram padding="26">
  <!-- The one picture the ordinary machinery could not hold. Everywhere else a
       connector attaches to a SHAPE; here the second axis is time, and a
       message attaches to a point partway down a lifeline - a place no mark
       exists at. So the geometry is computed, as <isometric>'s is.

       Note the third message: it runs from Browser straight to Postgres,
       THROUGH the API lifeline. That is correct here and is exactly what the
       obstacle-avoiding router would have refused to do.

       A <note> takes a row of its own, so it lands between the messages
       it was written between rather than beside them. -->
  <sequence gap="76">
    <actor id="browser" label="Browser"/>
    <actor id="api"     label="API"/>
    <actor id="db"      label="Postgres"/>

    <note over="api db" label="both inside the VPC"/>
    <message from="browser" to="api" label="GET /orders" activate="true"/>
    <message from="api" to="db" label="SELECT ..." activate="true"/>
    <message from="db" to="api" label="rows" dash="4 3" deactivate="true"/>
    <note over="api" label="cache for 60s"/>
    <message from="api" to="api" label="serialise"/>
    <message from="api" to="browser" label="200 OK" dash="4 3" deactivate="true"/>
    <message from="browser" to="db" label="health check" head="open"/>
  </sequence>
</diagram>

Open the SVG →