+972-72-3425-723 Atrium Tower, Jabotinsky 2, 18th Floor, Ramat-Gan info@allstars-it.com

Technical Design of Software. Visual modeling. UML Sequence diagrams

My name is Andrii Vovk. I am an Android developer in AllStars-IT Ukraine. Let’s continue talking about technical design of software and visual modeling. This article is about UML Sequence diagrams.


If you design a new software project or if you transit an existing (“legacy”) system to another person or organization, it’s a good practice to document how entities in it currently interact. Dynamic modeling of software is widely used for this purpose.

Sequence diagram is the most popular Unified Modeling Language (UML) artifact for identifying behavior within a system. It represents interactions between different objects in order that they occur to carry out the required functionality of the scenario. This approach can also be useful if you want to describe interactions between a client software and a server software.

An important characteristic of a sequence diagram is that it depicts messages between objects arranged in time sequence. The time passes from top to bottom: the flow starts near the top of the diagram and ends at the bottom. The horizontal dimension shows the object instances to which the messages are sent.

Messages are written with horizontal arrows. Closed and filled arrowheads represent synchronous calls, open arrowheads represent asynchronous messages, and dashed lines represent reply messages. If a caller sends a synchronous message, it must wait until the message processing is done, such as invoking a subroutine. If a caller sends an asynchronous message, it can continue working without a need to wait for a response. If a message is sent from outside the diagram, it can be shown by an arrow originating from a filled-in circle (“found message” in UML) or from a border of the diagram (“gate” in UML).

The white rectangles on a lifeline are execution specifications, also called activation boxes. They indicate that a target is processing a message. It starts when the message is received and ends when an object’s internal logic is done handling the message.

UML diagrams are almost self-explanatory, but if you wish you can add comments to them using a rectangle with a folded-over corner.

As you can see, sequence diagrams can be used to represent interactions in different contexts and scopes, starting with a small local feature and up to a system or even business level (in order to describe how the business processes currently work by showing how various business objects interact).

I hope that this introduction to UML diagrams can be useful for your projects and wish you happy engineering!