时序图 - 语法
开始
@startuml 图表名
header <size:15><color:red> **.pu Ver.0.1 更新日:时间 更新者:某某

定义
'隐藏'
hide footbox
'自动编号'
autonumber
'顺序消息对齐'
skinparam sequenceMessageAlign center
box 触发器
queue DIS #white
end box
'定义一个盒子 命名,内容块'
box 机能 #white
'参与者 名称 as 别名 #颜色'
participant FG as FG别名 #white
'队列 名称 #颜色'
queue 更新DIS #white
'数据库 名称 #颜色'
database 数据库 as 数据库别名 #white
end box

流程设计
DIS -> FG: 触发
'使其活动'
activate FG
alt FG函数实例初始化(重新启动的时候)
FG -> FG: 日志MDC设定
'追回笔记'
note right
* 笔记1
* 笔记2
* 笔记3
end note
end alt
alt #White try
FG -> 更新DIS:正常处理
更新DIS --> FG:返回结果
activate 更新DIS
alt #White try
更新DIS -> 数据库:正常处理
else #LightBlue catch 想定外异常
更新DIS -> 更新DIS: 异常结束
note right
* 异常
end note
end alt
deactivate 更新DIS
else #LightBlue catch 想定外异常
FG -> FG: 异常结束
note right
* 异常
end note
end alt
'使其无效'
deactivate FG
@enduml
