UML Deployment Diagram Tutorial

UML Deployment Diagram depicts deployment of artifacts on nodes. It is used for showing the placements of artifacts (software, system, module, etc.) on physical nodes (hardware, server, database, etc.) and the relationships between particular parts of the solution.

Deployment Diagram in UML

A deployment diagram is a structure UML diagram. It shows the solution architecture using nodes, components, artifacts, and their dependencies.
Deployment Diagram in UML
Deployment Diagram in UML

Desiging UML Deployment Diagrams

When creating a UML Deployment Diagram, it's important to accurately represent the physical environment and the relationships between Nodes. This can involve taking into account the hardware and software configurations, the network connections between Nodes, and any other relevant factors that may impact the deployment of the software system. To ensure the accuracy of the deployment diagram, it's recommended to work closely with system administrators, network engineers, and other experts who have knowledge of the deployment environment.

Deployment Diagram Symbols

Software Ideas Modeler offers tools for the following elements of a deployment diagram:

  • Node - is depicted as a 3d block. It represents a computational unit - either a hardware resource (device) or a software container (e.g. operating system, server). A node provides an execution environment for software modules and components.
  • Artifact - is an integrated piece of information that can be generated or used by a process or a module. An artifact can be a file, a document, a card, etc.
  • Component - it represents a module, a system part, or an application. It includes one or more classifiers that form a replaceable unit.
  • Association - is a relationship between two elements. For example, a component and an artifact may be associated to show that the artifact is part of the component.
  • Dependency - is a relationship between two elements in which changes to one element may affect the other. For example, a component may depend on another component.
  • Generalization- is a relationship between two elements in which one element inherits the properties from another.
  • Deploy - is used to indicate the deployment of an artifact on a node.
  • Manifest - is a relationship between an artifact and a component that shows which components are manifested in the given artifact. The manifest dependency connector points from an artifact to a component.

Node

A Node is a physical element that represents a unit of deployment. It can be either a hardware device (such as a server, computer, or another device) or a software component. A Node can be a single machine, a cluster of machines, a virtual machine, or a cloud instance. Nodes can be connected to form a network, and are typically used to model the deployment of software systems in the physical environment.

The role of Nodes in UML Deployment Diagrams is to represent the physical environment in which software components are deployed and executed. They are used to model the physical distribution of software systems and their components, including the relationships between hardware devices and the software components that run on them. By modeling the deployment environment, Nodes provide a clear and concise view of the physical structure of the system, helping to understand the distribution of software components and the relationships between hardware and software elements.

Artifact

An Artifact is a physical element in a deployment diagram that represents a piece of software or a configuration file that is part of the deployment. An artifact can be thought of as a unit of software that is built and deployed.

In a deployment diagram, artifacts are depicted as boxes with a file symbol in the header. The artifact allows you to define an associated file name and any other relevant metadata such as the version number as tagged values. The artifact may be associated with a node in the deployment diagram, which represents the environment where the artifact is deployed.

Artifacts can be associated with other artifacts through dependencies, which represent relationships between the artifacts. A dependency between artifacts can indicate that one artifact is required to run another artifact, or that one artifact is dependent on another for its configuration or data.

Component

A Component represents a modular part of a system that provides a particular set of services. Components can be thought of as black boxes, where the internal workings are hidden from the outside world. In the deployment diagram, components are represented in a rectangular shape with the name. They are marked with the component icon in the header.

The role of the Component element in a deployment diagram is to represent the physical implementation of a system's functions. This includes both the code and data that implement a system's services. By showing the deployment of components, the deployment diagram provides a detailed view of the physical deployment of a system's functions.

Components can be further decomposed into subcomponents, or they can be composed of other components. Components can also be associated with nodes, which represent the physical devices on which the components are deployed.

Deployment Diagram Overview

UML Deployment Diagram Overview
UML Deployment Diagram Overview

How to Draw a Deployment Diagram?

You can create a new deployment diagram in multiple ways:

  • Click on a Plus button in the tab switch bar, navigate to the UML group and click on the UML Deployment Diagram item
  • Press CTRL+SHIFT+D, choose Deployment Diagram from the UML group, enter the name and click on the OK button.
  • Switch to the Project tab in the ribbon and click on the Deployment Diagram item in the Content gallery.
  • Open the Project sidebar, right-click on a project (or a folder) node, and in the Add Diagram submenu, choose UML Deployment Diagram.
Create a new UML deployment diagram
Create a new UML deployment diagram

How to Draw Deployment Diagram Elements?

How to Draw a Node?

  • Click on the Node button in the Deployment Diagram group in the toolbox.
  • Specify the bounds of the new node by dragging on the diagram canvas. A node may be nested in another node.
  • If you want to add a node with the default size, just click on a diagram canvas and the node will be inserted into the specified position. You can also drag the Node tool button from the toolbox and drop it over the diagram canvas, also over another node to create a nested hierarchy.
  • If you want to insert multiple nodes in a row, double click (or click twice) on the Node button in the toolbox and draw as many nodes as you want in the diagram editor. If you do not want to add others, press the ESC key, or click on the Selection tool button.

How to Draw a Component?

  • Click on the Component button in the Deployment Diagram group in the toolbox.
  • Specify the bounds of the new component by dragging on the diagram canvas. A component may be nested in a node.
  • If you want to add a component with the default size, just click on a diagram canvas and the component will be inserted into the specified position. You can also drag the Component tool button from the toolbox and drop it over the diagram canvas, also over a node, if you want to nest it there.
  • If you want to insert multiple components in a row, double click (or click twice) on the Component button in the toolbox and draw as many components as you want in the diagram editor. If you do not want to add others, press the ESC key, or click on the Selection tool button.

How to Draw an Artifact?

  • Click on the Artifact button in the Deployment Diagram group in the toolbox.
  • Specify the bounds of the new artifact by dragging it on the diagram canvas. An artifact may be nested in a node.
  • If you want to add an artifact with the default size, just click on a diagram canvas and the artifact will be inserted into the specified position. You can also drag the Artifact tool button from the toolbox and drop it over the diagram canvas, also over a node, if you want to nest it there.
  • If you want to insert multiple artifacts in a row, double click (or click twice) on the Artifact button in the toolbox and draw any number of artifacts in the diagram editor. If you do not want to add others, press the ESC key, or click on the Selection tool button.

How to Draw an Association?

  • Click on the Association button in the Deployment Diagram group in the toolbox.
  • Drag from one element to another element. The inserted association is undirected.
  • Another way you can insert an association between two elements is to click on the Association button in the toolbox and drag it in between two elements. The diagram editor shows you which two elements will be connected when you release the button.
  • If you want to insert multiple associations in a row, double click (or click twice) on the Association button in the toolbox and draw the desired number of associations in the diagram editor.

New Comment

Comment