-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathagent.proto
143 lines (114 loc) · 2.42 KB
/
agent.proto
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
syntax = "proto3";
import "google/protobuf/struct.proto";
option go_package = "github.com/formancehq/membership/internal/grpc/generated";
package server;
service Server {
rpc Join(stream Message) returns (stream Order) {}
}
message ConnectRequest {
string id = 1;
map<string, string> tags = 2;
string baseUrl = 3;
bool production = 4;
}
message Order {
reserved 5;
oneof message {
Connected connected = 1;
Stack existingStack = 2;
DeletedStack deletedStack = 3;
Ping ping = 4;
DisabledStack disabledStack = 6;
EnabledStack enabledStack = 7;
}
}
message Message {
oneof message {
StatusChanged statusChanged = 1;
Pong pong = 2;
AddedVersion addedVersion = 3;
DeletedVersion deletedVersion = 4;
UpdatedVersion updatedVersion = 5;
ModuleStatusChanged moduleStatusChanged = 6;
ModuleDeleted moduleDeleted = 7;
DeletedStack stackDeleted = 8;
}
}
message Connected {}
message Ping {}
message Pong {}
message Stack {
string clusterName = 1;
string seed = 2;
AuthConfig authConfig = 3;
repeated AuthClient staticClients = 4;
StargateConfig stargateConfig = 5;
bool disabled = 6;
reserved 7;
string versions = 8;
bool enableAudit = 9;
map<string, string> additionalLabels = 10;
map<string, string> additionalAnnotations = 11;
repeated Module modules = 12;
}
message Module {
string name = 1;
}
enum StackStatus {
Progressing = 0;
Ready = 1;
Deleted = 2;
Disabled = 3;
}
message VersionKind {
string version = 1;
string kind = 2;
}
message ModuleStatusChanged {
string clusterName = 1;
google.protobuf.Struct status = 2;
VersionKind vk = 3;
}
message ModuleDeleted {
string clusterName = 1;
VersionKind vk = 2;
}
message StatusChanged {
string clusterName = 1;
StackStatus status = 2;
google.protobuf.Struct statuses = 3;
VersionKind vk = 4;
}
message StargateConfig {
bool enabled = 1;
string url = 2;
}
message DeletedStack {
string clusterName = 1;
}
message DisabledStack {
string clusterName = 1;
}
message EnabledStack {
string clusterName = 1;
}
message AuthConfig {
string clientId = 1;
string clientSecret = 2;
string issuer = 3;
}
message AuthClient {
bool public = 1;
string id = 2;
}
message AddedVersion {
string name = 1;
map<string, string> versions = 2;
}
message UpdatedVersion {
string name = 1;
map<string, string> versions = 2;
}
message DeletedVersion {
string name = 1;
}