 @startuml
scale 800*800
mainframe Получение списка регионов от Officer
actor Пользователь as user
participant ARM as ARM
participant gateway as gateway
collections redis as redis
participant workflow as workflow
participant officer as officer
autonumber

user -> ARM: Открывает форму\nзаказа
activate ARM
ARM -> gateway: REST API GET\n инфо о регионах
activate gateway
gateway -> redis: Запрашивает\nсписок\nрегионов

opt Данные о регионах есть в кэше
redis --> gateway: answer
else Данные необходимо обновить в кэше
gateway -> workflow: триггерит обновление
activate workflow
workflow -> officer: GraphQL method\noffices
activate officer
officer --> workflow: GraphQL answer
workflow -> officer: GraphQL method\nlocalities
officer --> workflow: GraphQL answer
deactivate officer
workflow -> workflow: Обработка\nданных
workflow -> redis: Записывает регионы\nи параметры в экш
workflow --> gateway: answer
deactivate workflow
end

gateway --> ARM: REST API GET\nanswer
deactivate gateway
ARM --> user: Рендерит данные
deactivate ARM
@enduml

 