-
Notifications
You must be signed in to change notification settings - Fork 65
/
event.proto
110 lines (98 loc) · 3.44 KB
/
event.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
// Copyright 2023 Google LLC
//
// 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.
syntax = "proto3";
package event;
import "topo.proto";
import "google/protobuf/timestamp.proto";
option go_package = "github.com/openconfig/kne/proto/event";
// KNEEvent is a wrapper around a specific event with a unique ID and timestamp.
message KNEEvent {
string uuid = 1;
google.protobuf.Timestamp timestamp = 2;
oneof event {
DeployClusterStart deploy_cluster_start = 3;
DeployClusterEnd deploy_cluster_end = 4;
CreateTopologyStart create_topology_start = 5;
CreateTopologyEnd create_topology_end = 6;
}
}
// DeployClusterStart is an event indicating a cluster deployment was started.
message DeployClusterStart {
Cluster cluster = 1;
}
// DeployClusterEnd is an event indicating a cluster deployment was ended.
message DeployClusterEnd {
// error is a string containing the error message that caused the cluster
// deployment to end unsuccessfully. Empty string if no error.
string error = 1;
}
// CreateTopologyStart is an event indicating a topology creation was started.
message CreateTopologyStart {
Topology topology = 1;
}
// CreateTopologyEnd is an event indicating a topology creation was ended.
message CreateTopologyEnd {
// error is a string containing the error message that caused the topology
// creation to end unsuccessfully. Empty string if no error.
string error = 1;
}
// Cluster holds information about a cluster.
message Cluster {
enum ClusterType {
CLUSTER_TYPE_UNSPECIFIED = 0;
CLUSTER_TYPE_KIND = 1;
CLUSTER_TYPE_EXTERNAL = 2;
CLUSTER_TYPE_KUBEADM = 3;
}
ClusterType cluster = 1;
enum IngressType {
INGRESS_TYPE_UNSPECIFIED = 0;
INGRESS_TYPE_METALLB = 1;
}
IngressType ingress = 2;
enum CNIType {
CNI_TYPE_UNSPECIFIED = 0;
CNI_TYPE_MESHNET = 1;
}
CNIType cni = 3;
enum ControllerType {
CONTROLLER_TYPE_UNSPECIFIED = 0;
CONTROLLER_TYPE_IXIATG = 1;
CONTROLLER_TYPE_SRLINUX = 2;
CONTROLLER_TYPE_CEOSLAB = 3;
CONTROLLER_TYPE_LEMMING = 4;
CONTROLLER_TYPE_CDNOS = 5;
}
repeated ControllerType controllers = 4;
}
// Topology holds information about a topology.
message Topology {
// nodes in the topology.
repeated Node nodes = 1;
// number of links in the topology. A count is sufficient here as the link
// details are not needed in topology metrics, in an effort to include as
// little potentially identifying information as possible in the reporting.
int64 link_count = 2;
}
// Node holds information about a node in a topology. This is a simplified
// version of the topo.Node in an effort to include as little potentially
// identifying information as possible in reporting. The included fields
// will be used in aggregate to identify trends and determine reliability
// of certain node configurations.
message Node {
// vendor is an enum of the node vendor.
topo.Vendor vendor = 1;
// model is the name of the model of the node.
string model = 2;
}