Skip to content

Common Sequence Diagram Mistake

A sequence diagram shows how parts of a system exchange messages over time (see UML Sequence Diagram). Most mistakes come from mixing up arrow styles.

Lifelines. Each object sits on a vertical dashed line. The object’s rectangle plus that line form the lifeline.

Synchronous calls and replies.

  • A synchronous call uses a filled arrowhead. The caller waits.
  • The reply is a dashed line with an open arrowhead.
  • Each filled call arrow has a matching dashed reply before the caller continues.

Asynchronous messages.

  • An asynchronous caller does not wait. It continues right away.
  • So an asynchronous message has no reply arrow. Drawing one is a mistake.
  • The open arrowhead marks a message as asynchronous. The dashed stroke does not.
  • Some informal diagrams use dashes to mean “delayed” or “background”. In UML, dashes mean a reply, so a dashed “async” arrow is wrong.

Found and lost messages.

  • A found message starts at a filled circle. Its sender is unknown or external.
  • A lost message points to a filled circle. Its sender is known, but its recipient is not.

Parallel fragments. In a par fragment, events in different operands may happen in any interleaved order. This shows concurrency. Do not read the operands as a fixed sequence.

For message types in more depth, see Message Types in Sequence Diagrams.

A web shop diagram shows an order service calling a payment service. The call “charge card” is a filled arrow, so the order service waits. The payment service answers with a dashed arrow with an open head. Later, the order service sends “notify warehouse” as an asynchronous message with an open arrowhead. It does not wait, so the diagram draws no reply. A reviewer who sees a dashed arrow back from the warehouse should flag it.

A synchronous call with a dashed reply, and an asynchronous message with no reply.

Diagram source
@startuml
participant "order:OrderService" as O
participant "pay:PaymentService" as P
participant "wh:Warehouse" as W
O -> P : chargeCard
P --> O : chargeCard
O ->> W : notifyWarehouse
@enduml
  • Every synchronous call (filled arrowhead) has a dashed reply arrow with an open arrowhead.
  • Asynchronous messages have no reply arrow.
  • Asynchronous messages are marked by an open arrowhead, not by a dashed line.
  • Found messages start at a filled circle, and lost messages end at one.