Deployment Diagram - Single Component in Multiple Nodes

0 votes
asked Jan 25, 2023 in Question / help by rcd-araujo (120 points)
Hi, Everyone.
I'm using this great tool to mapping my infrasctructure and I would like to know if it's possible that a single component be present in multiple nodes representing my servers in front of my load balance.
As a workaround I'm adding some spaces in the end of the name of the component

https://www.plantuml.com/plantuml/png/XP1H2i8m38RVSufSOE0yWEmU8YDhyr1Ocv5c0ndUtGrPhOBus7uVFn_fif7Q74SmcT041p6JY3ueEmkI099ungpBgLtX6kzzPbs2uniyAdPUeORuffwC1igy4rRSlEEdeE8wINcEhEs-TZnwcgOnEDfhjjbV19lcWdNVNw-aVgI_X99Mcr-eu-Itopq1

Is there a better way to solve this situation?
Any help would be realy appreciate. Thanks in advance.

1 Answer

0 votes
answered Jan 26, 2023 by The-Lu (65,240 points)

Hello R., and all,

For that you can use alias, as:

@startuml
node srv01{
  component my_service as msrv01
}

node srv02{
  component my_service as msrv02
}

node databaseserver {
  database database
}

node consumer1{
  [consumer_application]
}

[consumer_application] --> msrv01
[consumer_application] --> msrv02

msrv01 --> database
msrv02 --> database
@enduml

Enjoy,
Regards.

...