mirror of
https://github.com/openziti/ziti.git
synced 2026-10-13 15:51:21 +00:00
77bce93e85
Previously we often had two sets of events, one in the network package, and then another in the events package. We now only have one, in the events package. Events now have a public API, with minimal deps. There's an implementation package which has the dependencies. This allows the network package to generate events, without have a circular dependency on the events implementation package.
213 lines
4.1 KiB
Protocol Buffer
213 lines
4.1 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package ziti.ctrl.pb;
|
|
option go_package = "github.com/openziti/fabric/pb/ctrl_pb";
|
|
|
|
enum ContentType {
|
|
Zero = 0;
|
|
|
|
CircuitRequestType = 1000;
|
|
// defined in ctrl_msg/messages.go now
|
|
// CircuitSuccessType = 1001;
|
|
DialType = 1002;
|
|
LinkConnectedType = 1003;
|
|
FaultType = 1004;
|
|
RouteType = 1005;
|
|
UnrouteType = 1006;
|
|
MetricsType = 1007;
|
|
TogglePipeTracesRequestType = 1008;
|
|
TraceEventType = 1010;
|
|
CreateTerminatorRequestType = 1011;
|
|
RemoveTerminatorRequestType = 1012;
|
|
InspectRequestType = 1013;
|
|
InspectResponseType = 1014;
|
|
// defined in ctrl_msg/messages.go now
|
|
// CircuitFailedType = 1016;
|
|
ValidateTerminatorsRequestType = 1017;
|
|
UpdateTerminatorRequestType = 1018;
|
|
VerifyLinkType = 1019;
|
|
SettingsType = 1020;
|
|
CircuitConfirmationType = 1034;
|
|
RouterLinksType = 1035;
|
|
VerifyRouterType = 1036;
|
|
|
|
ListenersHeader = 10;
|
|
TerminatorLocalAddressHeader = 1100;
|
|
}
|
|
|
|
// SettingTypes are used with the Settings message send arbitrary settings to routers.
|
|
// SettingTypes default to int32 which can be used seamlessly for keys in the Settings.data field
|
|
enum SettingTypes {
|
|
//unused, consume to avoid zero value accidents
|
|
UnusedSetting = 0;
|
|
//Sent to routers to notify them of a controller IP/hostname move
|
|
NewCtrlAddress = 1;
|
|
}
|
|
|
|
// Settings are sent to to routers to configure arbitrary runtime settings.
|
|
message Settings {
|
|
map<int32, bytes> data = 1;
|
|
}
|
|
|
|
message CircuitRequest {
|
|
string ingressId = 1;
|
|
string service = 2;
|
|
map<uint32, bytes> peerData = 3;
|
|
}
|
|
|
|
message CircuitConfirmation {
|
|
repeated string circuitIds = 1;
|
|
}
|
|
|
|
enum TerminatorPrecedence {
|
|
Default = 0;
|
|
Required = 1;
|
|
Failed = 2;
|
|
}
|
|
|
|
message CreateTerminatorRequest {
|
|
string serviceId = 2;
|
|
string binding = 3;
|
|
string address = 4;
|
|
map<uint32, bytes> peerData = 5;
|
|
uint32 cost = 6;
|
|
TerminatorPrecedence precedence = 7;
|
|
string instanceId = 8;
|
|
bytes instanceSecret = 9;
|
|
}
|
|
|
|
message RemoveTerminatorRequest {
|
|
string terminatorId = 1;
|
|
}
|
|
|
|
message Terminator {
|
|
string id = 1;
|
|
string binding = 2;
|
|
string address = 3;
|
|
}
|
|
|
|
message ValidateTerminatorsRequest {
|
|
repeated Terminator terminators = 1;
|
|
}
|
|
|
|
message UpdateTerminatorRequest {
|
|
string terminatorId = 1;
|
|
bool updatePrecedence = 2;
|
|
bool updateCost = 3;
|
|
TerminatorPrecedence precedence = 4;
|
|
uint32 cost = 5;
|
|
}
|
|
|
|
message Dial {
|
|
string linkId = 1;
|
|
string address = 2;
|
|
string routerId = 3;
|
|
string linkProtocol = 4;
|
|
string routerVersion = 5;
|
|
}
|
|
|
|
message LinkConn {
|
|
string id = 1;
|
|
string localAddr = 2;
|
|
string remoteAddr = 3;
|
|
}
|
|
|
|
message LinkConnected {
|
|
string id = 1;
|
|
repeated LinkConn conns = 2;
|
|
}
|
|
|
|
message RouterLinks {
|
|
message RouterLink {
|
|
string id = 1;
|
|
string destRouterId = 2;
|
|
string linkProtocol = 3;
|
|
repeated string linkCostTags = 4;
|
|
string dialAddress = 5;
|
|
}
|
|
|
|
repeated RouterLink links = 1;
|
|
}
|
|
|
|
enum FaultSubject {
|
|
IngressFault = 0;
|
|
EgressFault = 1;
|
|
LinkFault = 2;
|
|
ForwardFault = 3;
|
|
}
|
|
|
|
message Fault {
|
|
FaultSubject subject = 1;
|
|
string id = 2;
|
|
}
|
|
|
|
message Context {
|
|
map<string, string> fields = 1;
|
|
uint32 channelMask = 2;
|
|
}
|
|
|
|
enum DestType {
|
|
Start = 0;
|
|
End = 1;
|
|
Link = 2;
|
|
}
|
|
|
|
message Route {
|
|
string circuitId = 1;
|
|
uint32 attempt = 2;
|
|
message Egress {
|
|
string binding = 1;
|
|
string address = 2;
|
|
string destination = 3;
|
|
map<uint32, bytes> peerData = 4;
|
|
}
|
|
Egress egress = 3;
|
|
message Forward {
|
|
string srcAddress = 1;
|
|
string dstAddress = 2;
|
|
DestType dstType = 3;
|
|
}
|
|
repeated Forward forwards = 4;
|
|
Context context = 5;
|
|
uint64 timeout = 6;
|
|
}
|
|
|
|
message Unroute {
|
|
string circuitId = 1;
|
|
bool now = 2;
|
|
}
|
|
|
|
message InspectRequest {
|
|
repeated string requestedValues = 1;
|
|
}
|
|
|
|
message InspectResponse {
|
|
bool success = 1;
|
|
repeated string errors = 2;
|
|
repeated InspectValue values = 3;
|
|
|
|
message InspectValue {
|
|
string name = 1;
|
|
string value = 2;
|
|
}
|
|
}
|
|
|
|
message VerifyLink {
|
|
string linkId = 1;
|
|
repeated string fingerprints = 2;
|
|
}
|
|
|
|
message VerifyRouter {
|
|
string routerId = 1;
|
|
repeated string fingerprints = 2;
|
|
}
|
|
|
|
message Listener {
|
|
string address = 1;
|
|
string protocol = 2;
|
|
repeated string costTags = 3;
|
|
}
|
|
|
|
message Listeners {
|
|
repeated Listener listeners = 1;
|
|
} |