-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapi.proto
More file actions
92 lines (77 loc) · 2.6 KB
/
api.proto
File metadata and controls
92 lines (77 loc) · 2.6 KB
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
syntax = "proto3";
package mizar;
// May need to return a code in the event of a temporary failure for retry.
service BuiltinsService {
// For Services/Service Endpoints, network controller may want to annotate the Endpoints.
// If Endpoints are not annotated, there will be many updates from unwanted endpoints.
rpc CreateService(BuiltinsServiceMessage) returns (ReturnCode) {}
rpc UpdateService(BuiltinsServiceMessage) returns (ReturnCode) {}
rpc ResumeService(BuiltinsServiceMessage) returns (ReturnCode) {}
rpc DeleteService(BuiltinsServiceMessage) returns (ReturnCode) {}
rpc UpdateServiceEndpoint(BuiltinsServiceEndpointMessage) returns (ReturnCode) {}
rpc ResumeServiceEndpoint(BuiltinsServiceEndpointMessage) returns (ReturnCode) {}
rpc CreateServiceEndpoint(BuiltinsServiceEndpointMessage) returns (ReturnCode) {}
rpc ResumePod(BuiltinsPodMessage) returns (ReturnCode) {}
rpc UpdatePod(BuiltinsPodMessage) returns (ReturnCode) {}
rpc CreatePod(BuiltinsPodMessage) returns (ReturnCode) {}
rpc DeletePod(BuiltinsPodMessage) returns (ReturnCode) {}
rpc CreateNode(BuiltinsNodeMessage) returns (ReturnCode) {}
rpc ResumeNode(BuiltinsNodeMessage) returns (ReturnCode) {}
rpc UpdateNode(BuiltinsNodeMessage) returns (ReturnCode) {}
rpc DeleteNode(BuiltinsNodeMessage) returns (ReturnCode) {}
rpc CreateArktosNetwork(BuiltinsArktosMessage) returns (ReturnCode) {}
rpc ResumeArktosNetwork(BuiltinsArktosMessage) returns (ReturnCode) {}
rpc UpdateArktosNetwork(BuiltinsArktosMessage) returns (ReturnCode) {}
}
message BuiltinsNodeMessage {
string name = 1;
string ip = 2;
}
message BuiltinsPodMessage {
string name = 1;
string host_ip = 2;
string namespace = 3;
string tenant = 4;
string arktos_network = 5;
string phase = 6;
repeated InterfacesMessage interfaces = 7;
}
message BuiltinsServiceMessage {
string name = 1;
string arktos_network = 2;
string namespace = 3;
string tenant = 4;
string ip = 5;
}
message BuiltinsServiceEndpointMessage {
string name = 1;
string namespace = 2;
string tenant = 3;
repeated string backend_ips = 4;
repeated PortsMessage ports = 5;
string backend_ips_json = 6;
string ports_json = 7;
}
message BuiltinsArktosMessage {
string name = 1;
string vpc = 2;
}
message PortsMessage {
string frontend_port = 1;
string backend_port = 2;
string protocol = 3;
}
message InterfacesMessage {
string name = 1;
string ip = 2;
string subnet = 3;
}
message ReturnCode {
CodeType code = 1;
string message = 2;
}
enum CodeType{
OK = 0;
TEMP_ERROR = 1;
PERM_ERROR = 2;
}