-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsystem.dot
55 lines (46 loc) · 1.9 KB
/
system.dot
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
// Copyright 2023 Lexi Robinson
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
digraph QueueSystem {
subgraph cluster_microservice {
graph [label = "Microservice";];
ms_main [label = "Main Thread(s)";];
ms_service [label = "Service Thread(s)";];
}
subgraph cluster_redis {
graph [label = "Redis";];
q_broker [label = "q:broker";];
q_list [label = "q:list";];
q_ms [label = "q:microservice_name";];
q_executing [label = "q:microservice_name:executing:uuid:thread_id";];
// no, really
}
subgraph cluster_broker {
graph [label = "Broker";];
br_main [label = "Broker Main Thread";];
br_recover [label = "Broker Recovery Thread";];
}
// SETUP SEGMENT
ms_service -> q_list [label = "announces availability";];
// MESSAGE SEND SEGMENT
ms_main -> q_broker [label = "writes new message";];
q_broker -> br_main [label = "constantly polls";];
br_main -> q_list [dir = "both"; label = "checks registered handlers";];
br_main -> q_ms [label = "pushes a copy of the message";];
// MESSAGE RECIEVE SEGMENT
q_ms -> ms_service [label = "constantly polls";];
ms_service -> q_executing [label = "writes every message";];
// RECOVERY
q_executing -> br_recover [label = "constantly trawls redis looking for keys";];
br_recover -> q_ms [label = "pushes lost messages";];
}