DEPLOYMENT DIAGRAM NOT WORKING

0 votes
asked Dec 5, 2023 in Question / help by anonymous
@startuml

!define ICONURL https://www.plantuml.com/plantuml/img/
!define WEB [<<Web>>]
!define DB [<<Database>>]
!define SERVER [<<Server>>]
!define CLIENT [<<Client>>]
!define COMPONENT [<<Component>>]

!define COMPONENTSTYLE [componentstyle=<<COLOR_COMPONENT>>]
!define SERVERSTYLE [componentstyle=<<COLOR_SERVER>>]
!define DATABASESTYLE [componentstyle=<<COLOR_DATABASE>>]
!define CLIENTSTYLE [componentstyle=<<COLOR_CLIENT>>]

!define COLOR_COMPONENT #3498db
!define COLOR_SERVER #2ecc71
!define COLOR_DATABASE #e74c3c
!define COLOR_CLIENT #f39c12

!define ICONSIZE 40

!define SPRITE(sprite) ICONURL + sprite + ".png"

!define NODE_COMPONENT(node, component) [node] -- [component]

!define WEB_SERVER [Web Server] <<Server>> {
    [Nurse Management Application (Web)] <<Component>>
    [Application Server] <<Component>>
}

!define DB_SERVER [Database Server] <<Server>> {
    [Database Management System (DBMS)] <<Component>>
    [Nurse Management Database] <<Component>>
}

!define MOBILE_DEVICES [Mobile Devices] <<Client>> {
    [Nurse Mobile App] <<Component>>
}

!define CLIENT_DEVICES [Client Devices] <<Client>> {
    [Nurse Management Application (Desktop)] <<Component>>
}

!define INTEGRATION_SERVER [Integration Services] <<Server>> {
    [Integration Module] <<Component>>
    [External Systems Interface] <<Component>>
}

!define LOAD_BALANCER [Load Balancer] <<Server>> {
    [Load Balancing Module] <<Component>>
}

!define SECURITY_SERVER [Security Server] <<Server>> {
    [Authentication Module] <<Component>>
    [Access Control Module] <<Component>>
}

!define MESSAGING_SERVER [Messaging Server] <<Server>> {
    [Notification Module] <<Component>>
    [Communication Module] <<Component>>
}

!define BACKUP_SERVER [Backup Server] <<Server>> {
    [Backup and Recovery Module] <<Component>>
}

WEB_SERVER -- NODE_COMPONENT(WEB_SERVER, [Nurse Management Application (Web)])
WEB_SERVER -- NODE_COMPONENT(WEB_SERVER, [Application Server])

DB_SERVER -- NODE_COMPONENT(DB_SERVER, [Database Management System (DBMS)])
DB_SERVER -- NODE_COMPONENT(DB_SERVER, [Nurse Management Database])

MOBILE_DEVICES -- NODE_COMPONENT(MOBILE_DEVICES, [Nurse Mobile App])

CLIENT_DEVICES -- NODE_COMPONENT(CLIENT_DEVICES, [Nurse Management Application (Desktop)])

INTEGRATION_SERVER -- NODE_COMPONENT(INTEGRATION_SERVER, [Integration Module])
INTEGRATION_SERVER -- NODE_COMPONENT(INTEGRATION_SERVER, [External Systems Interface])

LOAD_BALANCER -- NODE_COMPONENT(LOAD_BALANCER, [Load Balancing Module])

SECURITY_SERVER -- NODE_COMPONENT(SECURITY_SERVER, [Authentication Module])
SECURITY_SERVER -- NODE_COMPONENT(SECURITY_SERVER, [Access Control Module])

MESSAGING_SERVER -- NODE_COMPONENT(MESSAGING_SERVER, [Notification Module])
MESSAGING_SERVER -- NODE_COMPONENT(MESSAGING_SERVER, [Communication Module])

BACKUP_SERVER -- NODE_COMPONENT(BACKUP_SERVER, [Backup and Recovery Module])

@enduml
commented Dec 5, 2023 by The-Lu (89,080 points)
Hi A., and all,

- Why so many '!define'?
- Where do your code come from?

Regards,
Th

1 Answer

0 votes
answered Dec 5, 2023 by albert (3,620 points)

Looks like the continuation characters are missing in the define statements.

So:

!define WEB_SERVER [Web Server] <<Server>> {
    [Nurse Management Application (Web)] <<Component>>
    [Application Server] <<Component>>
}

should be:

!define WEB_SERVER [Web Server] <<Server>> { \
    [Nurse Management Application (Web)] <<Component>> \
    [Application Server] <<Component>> \
}

Note see also the Migration notes in https://plantuml.com/preprocessing (regarding not using !define)

...