rpc: remove empty message types

Signed-off-by: Steffen Vogel <post@steffenvogel.de>
This commit is contained in:
Steffen Vogel
2022-08-25 23:43:03 +02:00
parent 0a61f41700
commit 4af8ba3591
8 changed files with 137 additions and 352 deletions

View File

@@ -21,7 +21,7 @@ func init() {
func stop(cmd *cobra.Command, args []string) error { func stop(cmd *cobra.Command, args []string) error {
// TODO: Ignore errors caused by closed connection or gracefully shutdown the server // TODO: Ignore errors caused by closed connection or gracefully shutdown the server
if _, err := rpcClient.Stop(context.Background(), &pb.StopParams{}); err != nil { if _, err := rpcClient.Stop(context.Background(), &pb.Empty{}); err != nil {
return fmt.Errorf("failed RPC request: %w", err) return fmt.Errorf("failed RPC request: %w", err)
} }

View File

@@ -23,7 +23,7 @@ func init() {
} }
func sync(cmd *cobra.Command, args []string) error { func sync(cmd *cobra.Command, args []string) error {
_, err := rpcClient.Sync(context.Background(), &pb.SyncParams{}) _, err := rpcClient.Sync(context.Background(), &pb.Empty{})
if err != nil { if err != nil {
return fmt.Errorf("failed RPC request: %w", err) return fmt.Errorf("failed RPC request: %w", err)
} }

View File

@@ -122,158 +122,6 @@ func (x *StatusParams) GetPeer() []byte {
return nil return nil
} }
type UnWaitParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *UnWaitParams) Reset() {
*x = UnWaitParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UnWaitParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UnWaitParams) ProtoMessage() {}
func (x *UnWaitParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UnWaitParams.ProtoReflect.Descriptor instead.
func (*UnWaitParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{2}
}
type StopParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *StopParams) Reset() {
*x = StopParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *StopParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*StopParams) ProtoMessage() {}
func (x *StopParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use StopParams.ProtoReflect.Descriptor instead.
func (*StopParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{3}
}
type StreamEventsParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *StreamEventsParams) Reset() {
*x = StreamEventsParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *StreamEventsParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*StreamEventsParams) ProtoMessage() {}
func (x *StreamEventsParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use StreamEventsParams.ProtoReflect.Descriptor instead.
func (*StreamEventsParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{4}
}
type SyncParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *SyncParams) Reset() {
*x = SyncParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *SyncParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SyncParams) ProtoMessage() {}
func (x *SyncParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SyncParams.ProtoReflect.Descriptor instead.
func (*SyncParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{5}
}
type RemoveInterfaceParams struct { type RemoveInterfaceParams struct {
state protoimpl.MessageState state protoimpl.MessageState
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
@@ -285,7 +133,7 @@ type RemoveInterfaceParams struct {
func (x *RemoveInterfaceParams) Reset() { func (x *RemoveInterfaceParams) Reset() {
*x = RemoveInterfaceParams{} *x = RemoveInterfaceParams{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[6] mi := &file_rpc_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -298,7 +146,7 @@ func (x *RemoveInterfaceParams) String() string {
func (*RemoveInterfaceParams) ProtoMessage() {} func (*RemoveInterfaceParams) ProtoMessage() {}
func (x *RemoveInterfaceParams) ProtoReflect() protoreflect.Message { func (x *RemoveInterfaceParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[6] mi := &file_rpc_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -311,7 +159,7 @@ func (x *RemoveInterfaceParams) ProtoReflect() protoreflect.Message {
// Deprecated: Use RemoveInterfaceParams.ProtoReflect.Descriptor instead. // Deprecated: Use RemoveInterfaceParams.ProtoReflect.Descriptor instead.
func (*RemoveInterfaceParams) Descriptor() ([]byte, []int) { func (*RemoveInterfaceParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{6} return file_rpc_proto_rawDescGZIP(), []int{2}
} }
func (x *RemoveInterfaceParams) GetIntf() string { func (x *RemoveInterfaceParams) GetIntf() string {
@@ -333,7 +181,7 @@ type RestartPeerParams struct {
func (x *RestartPeerParams) Reset() { func (x *RestartPeerParams) Reset() {
*x = RestartPeerParams{} *x = RestartPeerParams{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[7] mi := &file_rpc_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -346,7 +194,7 @@ func (x *RestartPeerParams) String() string {
func (*RestartPeerParams) ProtoMessage() {} func (*RestartPeerParams) ProtoMessage() {}
func (x *RestartPeerParams) ProtoReflect() protoreflect.Message { func (x *RestartPeerParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[7] mi := &file_rpc_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -359,7 +207,7 @@ func (x *RestartPeerParams) ProtoReflect() protoreflect.Message {
// Deprecated: Use RestartPeerParams.ProtoReflect.Descriptor instead. // Deprecated: Use RestartPeerParams.ProtoReflect.Descriptor instead.
func (*RestartPeerParams) Descriptor() ([]byte, []int) { func (*RestartPeerParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{7} return file_rpc_proto_rawDescGZIP(), []int{3}
} }
func (x *RestartPeerParams) GetIntf() string { func (x *RestartPeerParams) GetIntf() string {
@@ -388,7 +236,7 @@ type InterfaceConfigParams struct {
func (x *InterfaceConfigParams) Reset() { func (x *InterfaceConfigParams) Reset() {
*x = InterfaceConfigParams{} *x = InterfaceConfigParams{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[8] mi := &file_rpc_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -401,7 +249,7 @@ func (x *InterfaceConfigParams) String() string {
func (*InterfaceConfigParams) ProtoMessage() {} func (*InterfaceConfigParams) ProtoMessage() {}
func (x *InterfaceConfigParams) ProtoReflect() protoreflect.Message { func (x *InterfaceConfigParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[8] mi := &file_rpc_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -414,7 +262,7 @@ func (x *InterfaceConfigParams) ProtoReflect() protoreflect.Message {
// Deprecated: Use InterfaceConfigParams.ProtoReflect.Descriptor instead. // Deprecated: Use InterfaceConfigParams.ProtoReflect.Descriptor instead.
func (*InterfaceConfigParams) Descriptor() ([]byte, []int) { func (*InterfaceConfigParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{8} return file_rpc_proto_rawDescGZIP(), []int{4}
} }
func (x *InterfaceConfigParams) GetName() string { func (x *InterfaceConfigParams) GetName() string {
@@ -445,7 +293,7 @@ type GetSignalingMessageParams struct {
func (x *GetSignalingMessageParams) Reset() { func (x *GetSignalingMessageParams) Reset() {
*x = GetSignalingMessageParams{} *x = GetSignalingMessageParams{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[9] mi := &file_rpc_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -458,7 +306,7 @@ func (x *GetSignalingMessageParams) String() string {
func (*GetSignalingMessageParams) ProtoMessage() {} func (*GetSignalingMessageParams) ProtoMessage() {}
func (x *GetSignalingMessageParams) ProtoReflect() protoreflect.Message { func (x *GetSignalingMessageParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[9] mi := &file_rpc_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -471,7 +319,7 @@ func (x *GetSignalingMessageParams) ProtoReflect() protoreflect.Message {
// Deprecated: Use GetSignalingMessageParams.ProtoReflect.Descriptor instead. // Deprecated: Use GetSignalingMessageParams.ProtoReflect.Descriptor instead.
func (*GetSignalingMessageParams) Descriptor() ([]byte, []int) { func (*GetSignalingMessageParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{9} return file_rpc_proto_rawDescGZIP(), []int{5}
} }
func (x *GetSignalingMessageParams) GetIntf() string { func (x *GetSignalingMessageParams) GetIntf() string {
@@ -499,7 +347,7 @@ type GetSignalingMessageResp struct {
func (x *GetSignalingMessageResp) Reset() { func (x *GetSignalingMessageResp) Reset() {
*x = GetSignalingMessageResp{} *x = GetSignalingMessageResp{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[10] mi := &file_rpc_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -512,7 +360,7 @@ func (x *GetSignalingMessageResp) String() string {
func (*GetSignalingMessageResp) ProtoMessage() {} func (*GetSignalingMessageResp) ProtoMessage() {}
func (x *GetSignalingMessageResp) ProtoReflect() protoreflect.Message { func (x *GetSignalingMessageResp) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[10] mi := &file_rpc_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -525,7 +373,7 @@ func (x *GetSignalingMessageResp) ProtoReflect() protoreflect.Message {
// Deprecated: Use GetSignalingMessageResp.ProtoReflect.Descriptor instead. // Deprecated: Use GetSignalingMessageResp.ProtoReflect.Descriptor instead.
func (*GetSignalingMessageResp) Descriptor() ([]byte, []int) { func (*GetSignalingMessageResp) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{10} return file_rpc_proto_rawDescGZIP(), []int{6}
} }
func (x *GetSignalingMessageResp) GetEnvelope() *SignalingEnvelope { func (x *GetSignalingMessageResp) GetEnvelope() *SignalingEnvelope {
@@ -546,7 +394,7 @@ type PutSignalingMessageParams struct {
func (x *PutSignalingMessageParams) Reset() { func (x *PutSignalingMessageParams) Reset() {
*x = PutSignalingMessageParams{} *x = PutSignalingMessageParams{}
if protoimpl.UnsafeEnabled { if protoimpl.UnsafeEnabled {
mi := &file_rpc_proto_msgTypes[11] mi := &file_rpc_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi) ms.StoreMessageInfo(mi)
} }
@@ -559,7 +407,7 @@ func (x *PutSignalingMessageParams) String() string {
func (*PutSignalingMessageParams) ProtoMessage() {} func (*PutSignalingMessageParams) ProtoMessage() {}
func (x *PutSignalingMessageParams) ProtoReflect() protoreflect.Message { func (x *PutSignalingMessageParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_proto_msgTypes[11] mi := &file_rpc_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil { if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil { if ms.LoadMessageInfo() == nil {
@@ -572,7 +420,7 @@ func (x *PutSignalingMessageParams) ProtoReflect() protoreflect.Message {
// Deprecated: Use PutSignalingMessageParams.ProtoReflect.Descriptor instead. // Deprecated: Use PutSignalingMessageParams.ProtoReflect.Descriptor instead.
func (*PutSignalingMessageParams) Descriptor() ([]byte, []int) { func (*PutSignalingMessageParams) Descriptor() ([]byte, []int) {
return file_rpc_proto_rawDescGZIP(), []int{11} return file_rpc_proto_rawDescGZIP(), []int{7}
} }
func (x *PutSignalingMessageParams) GetEnvelope() *SignalingEnvelope { func (x *PutSignalingMessageParams) GetEnvelope() *SignalingEnvelope {
@@ -598,50 +446,44 @@ var file_rpc_proto_rawDesc = []byte{
0x74, 0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x74, 0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x69,
0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x12, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x12,
0x12, 0x0a, 0x04, 0x70, 0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70, 0x12, 0x0a, 0x04, 0x70, 0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70,
0x65, 0x65, 0x72, 0x22, 0x0e, 0x0a, 0x0c, 0x55, 0x6e, 0x57, 0x61, 0x69, 0x74, 0x50, 0x61, 0x72, 0x65, 0x65, 0x72, 0x22, 0x2b, 0x0a, 0x15, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x49, 0x6e, 0x74,
0x61, 0x6d, 0x73, 0x22, 0x0c, 0x0a, 0x0a, 0x53, 0x74, 0x6f, 0x70, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04,
0x73, 0x22, 0x14, 0x0a, 0x12, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66,
0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x0c, 0x0a, 0x0a, 0x53, 0x79, 0x6e, 0x63, 0x50, 0x22, 0x3b, 0x0a, 0x11, 0x52, 0x65, 0x73, 0x74, 0x61, 0x72, 0x74, 0x50, 0x65, 0x65, 0x72, 0x50,
0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x2b, 0x0a, 0x15, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x49, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20,
0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x65, 0x65,
0x0a, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70, 0x65, 0x65, 0x72, 0x22, 0x60, 0x0a,
0x74, 0x66, 0x22, 0x3b, 0x0a, 0x11, 0x52, 0x65, 0x73, 0x74, 0x61, 0x72, 0x74, 0x50, 0x65, 0x65, 0x15, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
0x72, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x33, 0x0a, 0x09, 0x69, 0x6e,
0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70, 0x65, 0x65, 0x72, 0x22, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e,
0x60, 0x0a, 0x15, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x43, 0x6f,
0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x22,
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x33, 0x0a, 0x09, 0x43, 0x0a, 0x19, 0x47, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x69, 0x6e, 0x67, 0x4d,
0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04,
0x15, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04,
0x65, 0x22, 0x43, 0x0a, 0x19, 0x47, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x69, 0x6e, 0x70, 0x65, 0x65, 0x72, 0x22, 0x4e, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61,
0x67, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x6c, 0x69, 0x6e, 0x67, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x12,
0x0a, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x33, 0x0a, 0x08, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
0x74, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x6c, 0x69,
0x52, 0x04, 0x70, 0x65, 0x65, 0x72, 0x22, 0x4e, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x67, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x08, 0x65, 0x6e, 0x76, 0x65,
0x6e, 0x61, 0x6c, 0x69, 0x6e, 0x67, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x52, 0x65, 0x73, 0x6c, 0x6f, 0x70, 0x65, 0x22, 0x50, 0x0a, 0x19, 0x50, 0x75, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61,
0x70, 0x12, 0x33, 0x0a, 0x08, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x18, 0x01, 0x20, 0x6c, 0x69, 0x6e, 0x67, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d,
0x73, 0x12, 0x33, 0x0a, 0x08, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x18, 0x01, 0x20,
0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x61,
0x6c, 0x69, 0x6e, 0x67, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x08, 0x65, 0x6e, 0x6c, 0x69, 0x6e, 0x67, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x08, 0x65, 0x6e,
0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x22, 0x50, 0x0a, 0x19, 0x50, 0x75, 0x74, 0x53, 0x69, 0x67, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x32, 0x80, 0x01, 0x0a, 0x06, 0x53, 0x6f, 0x63, 0x6b, 0x65,
0x6e, 0x61, 0x6c, 0x69, 0x6e, 0x67, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x61, 0x72, 0x74, 0x12, 0x2c, 0x0a, 0x0c, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x45, 0x76, 0x65, 0x6e, 0x74,
0x61, 0x6d, 0x73, 0x12, 0x33, 0x0a, 0x08, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x18, 0x73, 0x12, 0x0b, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0b,
0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x69, 0x67, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12,
0x6e, 0x61, 0x6c, 0x69, 0x6e, 0x67, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x08, 0x24, 0x0a, 0x06, 0x55, 0x6e, 0x57, 0x61, 0x69, 0x74, 0x12, 0x0b, 0x2e, 0x77, 0x69, 0x63, 0x65,
0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x32, 0x99, 0x01, 0x0a, 0x06, 0x53, 0x6f, 0x63, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0b, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d,
0x6b, 0x65, 0x74, 0x12, 0x39, 0x0a, 0x0c, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x45, 0x76, 0x65, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x22, 0x0a, 0x04, 0x53, 0x74, 0x6f, 0x70, 0x12, 0x0b, 0x2e,
0x6e, 0x74, 0x73, 0x12, 0x18, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x74, 0x72, 0x65, 0x61, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0b, 0x2e, 0x77, 0x69, 0x63,
0x6d, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x0b, 0x2e, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x32, 0x88, 0x04, 0x0a, 0x07, 0x57, 0x61,
0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x2b, 0x74, 0x63, 0x68, 0x65, 0x72, 0x12, 0x22, 0x0a, 0x04, 0x53, 0x79, 0x6e, 0x63, 0x12, 0x0b, 0x2e,
0x0a, 0x06, 0x55, 0x6e, 0x57, 0x61, 0x69, 0x74, 0x12, 0x12, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0b, 0x2e, 0x77, 0x69, 0x63,
0x55, 0x6e, 0x57, 0x61, 0x69, 0x74, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x0b, 0x2e, 0x77,
0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x27, 0x0a, 0x04, 0x53,
0x74, 0x6f, 0x70, 0x12, 0x10, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x74, 0x6f, 0x70, 0x50,
0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x0b, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x45, 0x6d, 0x70,
0x74, 0x79, 0x22, 0x00, 0x32, 0x8d, 0x04, 0x0a, 0x07, 0x57, 0x61, 0x74, 0x63, 0x68, 0x65, 0x72,
0x12, 0x27, 0x0a, 0x04, 0x53, 0x79, 0x6e, 0x63, 0x12, 0x10, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e,
0x53, 0x79, 0x6e, 0x63, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x0b, 0x2e, 0x77, 0x69, 0x63,
0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x33, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x33, 0x0a, 0x09, 0x47, 0x65, 0x74,
0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x2e, 0x77, 0x69, 0x63, 0x65, 0x2e, 0x53, 0x74,
0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x10, 0x2e, 0x77, 0x69, 0x63, 0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x10, 0x2e, 0x77, 0x69, 0x63,
@@ -705,59 +547,55 @@ func file_rpc_proto_rawDescGZIP() []byte {
return file_rpc_proto_rawDescData return file_rpc_proto_rawDescData
} }
var file_rpc_proto_msgTypes = make([]protoimpl.MessageInfo, 12) var file_rpc_proto_msgTypes = make([]protoimpl.MessageInfo, 8)
var file_rpc_proto_goTypes = []interface{}{ var file_rpc_proto_goTypes = []interface{}{
(*StatusResp)(nil), // 0: wice.StatusResp (*StatusResp)(nil), // 0: wice.StatusResp
(*StatusParams)(nil), // 1: wice.StatusParams (*StatusParams)(nil), // 1: wice.StatusParams
(*UnWaitParams)(nil), // 2: wice.UnWaitParams (*RemoveInterfaceParams)(nil), // 2: wice.RemoveInterfaceParams
(*StopParams)(nil), // 3: wice.StopParams (*RestartPeerParams)(nil), // 3: wice.RestartPeerParams
(*StreamEventsParams)(nil), // 4: wice.StreamEventsParams (*InterfaceConfigParams)(nil), // 4: wice.InterfaceConfigParams
(*SyncParams)(nil), // 5: wice.SyncParams (*GetSignalingMessageParams)(nil), // 5: wice.GetSignalingMessageParams
(*RemoveInterfaceParams)(nil), // 6: wice.RemoveInterfaceParams (*GetSignalingMessageResp)(nil), // 6: wice.GetSignalingMessageResp
(*RestartPeerParams)(nil), // 7: wice.RestartPeerParams (*PutSignalingMessageParams)(nil), // 7: wice.PutSignalingMessageParams
(*InterfaceConfigParams)(nil), // 8: wice.InterfaceConfigParams (*Interface)(nil), // 8: wice.Interface
(*GetSignalingMessageParams)(nil), // 9: wice.GetSignalingMessageParams (*InterfaceConfig)(nil), // 9: wice.InterfaceConfig
(*GetSignalingMessageResp)(nil), // 10: wice.GetSignalingMessageResp (*SignalingEnvelope)(nil), // 10: wice.SignalingEnvelope
(*PutSignalingMessageParams)(nil), // 11: wice.PutSignalingMessageParams (*Empty)(nil), // 11: wice.Empty
(*Interface)(nil), // 12: wice.Interface (*Event)(nil), // 12: wice.Event
(*InterfaceConfig)(nil), // 13: wice.InterfaceConfig
(*SignalingEnvelope)(nil), // 14: wice.SignalingEnvelope
(*Event)(nil), // 15: wice.Event
(*Empty)(nil), // 16: wice.Empty
} }
var file_rpc_proto_depIdxs = []int32{ var file_rpc_proto_depIdxs = []int32{
12, // 0: wice.StatusResp.interfaces:type_name -> wice.Interface 8, // 0: wice.StatusResp.interfaces:type_name -> wice.Interface
13, // 1: wice.InterfaceConfigParams.interface:type_name -> wice.InterfaceConfig 9, // 1: wice.InterfaceConfigParams.interface:type_name -> wice.InterfaceConfig
14, // 2: wice.GetSignalingMessageResp.envelope:type_name -> wice.SignalingEnvelope 10, // 2: wice.GetSignalingMessageResp.envelope:type_name -> wice.SignalingEnvelope
14, // 3: wice.PutSignalingMessageParams.envelope:type_name -> wice.SignalingEnvelope 10, // 3: wice.PutSignalingMessageParams.envelope:type_name -> wice.SignalingEnvelope
4, // 4: wice.Socket.StreamEvents:input_type -> wice.StreamEventsParams 11, // 4: wice.Socket.StreamEvents:input_type -> wice.Empty
2, // 5: wice.Socket.UnWait:input_type -> wice.UnWaitParams 11, // 5: wice.Socket.UnWait:input_type -> wice.Empty
3, // 6: wice.Socket.Stop:input_type -> wice.StopParams 11, // 6: wice.Socket.Stop:input_type -> wice.Empty
5, // 7: wice.Watcher.Sync:input_type -> wice.SyncParams 11, // 7: wice.Watcher.Sync:input_type -> wice.Empty
1, // 8: wice.Watcher.GetStatus:input_type -> wice.StatusParams 1, // 8: wice.Watcher.GetStatus:input_type -> wice.StatusParams
6, // 9: wice.Watcher.RemoveInterface:input_type -> wice.RemoveInterfaceParams 2, // 9: wice.Watcher.RemoveInterface:input_type -> wice.RemoveInterfaceParams
8, // 10: wice.Watcher.SyncInterfaceConfig:input_type -> wice.InterfaceConfigParams 4, // 10: wice.Watcher.SyncInterfaceConfig:input_type -> wice.InterfaceConfigParams
8, // 11: wice.Watcher.AddInterfaceConfig:input_type -> wice.InterfaceConfigParams 4, // 11: wice.Watcher.AddInterfaceConfig:input_type -> wice.InterfaceConfigParams
8, // 12: wice.Watcher.SetInterfaceConfig:input_type -> wice.InterfaceConfigParams 4, // 12: wice.Watcher.SetInterfaceConfig:input_type -> wice.InterfaceConfigParams
9, // 13: wice.Watcher.GetSignalingMessage:input_type -> wice.GetSignalingMessageParams 5, // 13: wice.Watcher.GetSignalingMessage:input_type -> wice.GetSignalingMessageParams
11, // 14: wice.Watcher.PutSignalingMessage:input_type -> wice.PutSignalingMessageParams 7, // 14: wice.Watcher.PutSignalingMessage:input_type -> wice.PutSignalingMessageParams
7, // 15: wice.EndpointDiscoverySocket.RestartPeer:input_type -> wice.RestartPeerParams 3, // 15: wice.EndpointDiscoverySocket.RestartPeer:input_type -> wice.RestartPeerParams
9, // 16: wice.SignalingSocket.GetSignalingMessage:input_type -> wice.GetSignalingMessageParams 5, // 16: wice.SignalingSocket.GetSignalingMessage:input_type -> wice.GetSignalingMessageParams
11, // 17: wice.SignalingSocket.PutSignalingMessage:input_type -> wice.PutSignalingMessageParams 7, // 17: wice.SignalingSocket.PutSignalingMessage:input_type -> wice.PutSignalingMessageParams
15, // 18: wice.Socket.StreamEvents:output_type -> wice.Event 12, // 18: wice.Socket.StreamEvents:output_type -> wice.Event
16, // 19: wice.Socket.UnWait:output_type -> wice.Empty 11, // 19: wice.Socket.UnWait:output_type -> wice.Empty
16, // 20: wice.Socket.Stop:output_type -> wice.Empty 11, // 20: wice.Socket.Stop:output_type -> wice.Empty
16, // 21: wice.Watcher.Sync:output_type -> wice.Empty 11, // 21: wice.Watcher.Sync:output_type -> wice.Empty
0, // 22: wice.Watcher.GetStatus:output_type -> wice.StatusResp 0, // 22: wice.Watcher.GetStatus:output_type -> wice.StatusResp
16, // 23: wice.Watcher.RemoveInterface:output_type -> wice.Empty 11, // 23: wice.Watcher.RemoveInterface:output_type -> wice.Empty
16, // 24: wice.Watcher.SyncInterfaceConfig:output_type -> wice.Empty 11, // 24: wice.Watcher.SyncInterfaceConfig:output_type -> wice.Empty
16, // 25: wice.Watcher.AddInterfaceConfig:output_type -> wice.Empty 11, // 25: wice.Watcher.AddInterfaceConfig:output_type -> wice.Empty
16, // 26: wice.Watcher.SetInterfaceConfig:output_type -> wice.Empty 11, // 26: wice.Watcher.SetInterfaceConfig:output_type -> wice.Empty
10, // 27: wice.Watcher.GetSignalingMessage:output_type -> wice.GetSignalingMessageResp 6, // 27: wice.Watcher.GetSignalingMessage:output_type -> wice.GetSignalingMessageResp
16, // 28: wice.Watcher.PutSignalingMessage:output_type -> wice.Empty 11, // 28: wice.Watcher.PutSignalingMessage:output_type -> wice.Empty
16, // 29: wice.EndpointDiscoverySocket.RestartPeer:output_type -> wice.Empty 11, // 29: wice.EndpointDiscoverySocket.RestartPeer:output_type -> wice.Empty
10, // 30: wice.SignalingSocket.GetSignalingMessage:output_type -> wice.GetSignalingMessageResp 6, // 30: wice.SignalingSocket.GetSignalingMessage:output_type -> wice.GetSignalingMessageResp
16, // 31: wice.SignalingSocket.PutSignalingMessage:output_type -> wice.Empty 11, // 31: wice.SignalingSocket.PutSignalingMessage:output_type -> wice.Empty
18, // [18:32] is the sub-list for method output_type 18, // [18:32] is the sub-list for method output_type
4, // [4:18] is the sub-list for method input_type 4, // [4:18] is the sub-list for method input_type
4, // [4:4] is the sub-list for extension type_name 4, // [4:4] is the sub-list for extension type_name
@@ -801,54 +639,6 @@ func file_rpc_proto_init() {
} }
} }
file_rpc_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UnWaitParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_rpc_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*StopParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_rpc_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*StreamEventsParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_rpc_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*SyncParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_rpc_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RemoveInterfaceParams); i { switch v := v.(*RemoveInterfaceParams); i {
case 0: case 0:
return &v.state return &v.state
@@ -860,7 +650,7 @@ func file_rpc_proto_init() {
return nil return nil
} }
} }
file_rpc_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*RestartPeerParams); i { switch v := v.(*RestartPeerParams); i {
case 0: case 0:
return &v.state return &v.state
@@ -872,7 +662,7 @@ func file_rpc_proto_init() {
return nil return nil
} }
} }
file_rpc_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*InterfaceConfigParams); i { switch v := v.(*InterfaceConfigParams); i {
case 0: case 0:
return &v.state return &v.state
@@ -884,7 +674,7 @@ func file_rpc_proto_init() {
return nil return nil
} }
} }
file_rpc_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetSignalingMessageParams); i { switch v := v.(*GetSignalingMessageParams); i {
case 0: case 0:
return &v.state return &v.state
@@ -896,7 +686,7 @@ func file_rpc_proto_init() {
return nil return nil
} }
} }
file_rpc_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetSignalingMessageResp); i { switch v := v.(*GetSignalingMessageResp); i {
case 0: case 0:
return &v.state return &v.state
@@ -908,7 +698,7 @@ func file_rpc_proto_init() {
return nil return nil
} }
} }
file_rpc_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { file_rpc_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*PutSignalingMessageParams); i { switch v := v.(*PutSignalingMessageParams); i {
case 0: case 0:
return &v.state return &v.state
@@ -927,7 +717,7 @@ func file_rpc_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(), GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_rpc_proto_rawDesc, RawDescriptor: file_rpc_proto_rawDesc,
NumEnums: 0, NumEnums: 0,
NumMessages: 12, NumMessages: 8,
NumExtensions: 0, NumExtensions: 0,
NumServices: 4, NumServices: 4,
}, },

View File

@@ -18,11 +18,6 @@ message StatusParams {
bytes peer = 2; bytes peer = 2;
} }
message UnWaitParams {}
message StopParams {}
message StreamEventsParams {}
message SyncParams {}
message RemoveInterfaceParams { message RemoveInterfaceParams {
string intf = 1; string intf = 1;
} }
@@ -56,13 +51,13 @@ message PutSignalingMessageParams {
// Control socket services // Control socket services
service Socket { service Socket {
rpc StreamEvents(StreamEventsParams) returns (stream Event) {} rpc StreamEvents(Empty) returns (stream Event) {}
rpc UnWait(UnWaitParams) returns (Empty) {} rpc UnWait(Empty) returns (Empty) {}
rpc Stop(StopParams) returns (Empty) {} rpc Stop(Empty) returns (Empty) {}
} }
service Watcher { service Watcher {
rpc Sync(SyncParams) returns (Empty) {} rpc Sync(Empty) returns (Empty) {}
rpc GetStatus(StatusParams) returns (StatusResp) {} rpc GetStatus(StatusParams) returns (StatusResp) {}

View File

@@ -22,9 +22,9 @@ const _ = grpc.SupportPackageIsVersion7
// //
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type SocketClient interface { type SocketClient interface {
StreamEvents(ctx context.Context, in *StreamEventsParams, opts ...grpc.CallOption) (Socket_StreamEventsClient, error) StreamEvents(ctx context.Context, in *Empty, opts ...grpc.CallOption) (Socket_StreamEventsClient, error)
UnWait(ctx context.Context, in *UnWaitParams, opts ...grpc.CallOption) (*Empty, error) UnWait(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error)
Stop(ctx context.Context, in *StopParams, opts ...grpc.CallOption) (*Empty, error) Stop(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error)
} }
type socketClient struct { type socketClient struct {
@@ -35,7 +35,7 @@ func NewSocketClient(cc grpc.ClientConnInterface) SocketClient {
return &socketClient{cc} return &socketClient{cc}
} }
func (c *socketClient) StreamEvents(ctx context.Context, in *StreamEventsParams, opts ...grpc.CallOption) (Socket_StreamEventsClient, error) { func (c *socketClient) StreamEvents(ctx context.Context, in *Empty, opts ...grpc.CallOption) (Socket_StreamEventsClient, error) {
stream, err := c.cc.NewStream(ctx, &Socket_ServiceDesc.Streams[0], "/wice.Socket/StreamEvents", opts...) stream, err := c.cc.NewStream(ctx, &Socket_ServiceDesc.Streams[0], "/wice.Socket/StreamEvents", opts...)
if err != nil { if err != nil {
return nil, err return nil, err
@@ -67,7 +67,7 @@ func (x *socketStreamEventsClient) Recv() (*Event, error) {
return m, nil return m, nil
} }
func (c *socketClient) UnWait(ctx context.Context, in *UnWaitParams, opts ...grpc.CallOption) (*Empty, error) { func (c *socketClient) UnWait(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) {
out := new(Empty) out := new(Empty)
err := c.cc.Invoke(ctx, "/wice.Socket/UnWait", in, out, opts...) err := c.cc.Invoke(ctx, "/wice.Socket/UnWait", in, out, opts...)
if err != nil { if err != nil {
@@ -76,7 +76,7 @@ func (c *socketClient) UnWait(ctx context.Context, in *UnWaitParams, opts ...grp
return out, nil return out, nil
} }
func (c *socketClient) Stop(ctx context.Context, in *StopParams, opts ...grpc.CallOption) (*Empty, error) { func (c *socketClient) Stop(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) {
out := new(Empty) out := new(Empty)
err := c.cc.Invoke(ctx, "/wice.Socket/Stop", in, out, opts...) err := c.cc.Invoke(ctx, "/wice.Socket/Stop", in, out, opts...)
if err != nil { if err != nil {
@@ -89,9 +89,9 @@ func (c *socketClient) Stop(ctx context.Context, in *StopParams, opts ...grpc.Ca
// All implementations must embed UnimplementedSocketServer // All implementations must embed UnimplementedSocketServer
// for forward compatibility // for forward compatibility
type SocketServer interface { type SocketServer interface {
StreamEvents(*StreamEventsParams, Socket_StreamEventsServer) error StreamEvents(*Empty, Socket_StreamEventsServer) error
UnWait(context.Context, *UnWaitParams) (*Empty, error) UnWait(context.Context, *Empty) (*Empty, error)
Stop(context.Context, *StopParams) (*Empty, error) Stop(context.Context, *Empty) (*Empty, error)
mustEmbedUnimplementedSocketServer() mustEmbedUnimplementedSocketServer()
} }
@@ -99,13 +99,13 @@ type SocketServer interface {
type UnimplementedSocketServer struct { type UnimplementedSocketServer struct {
} }
func (UnimplementedSocketServer) StreamEvents(*StreamEventsParams, Socket_StreamEventsServer) error { func (UnimplementedSocketServer) StreamEvents(*Empty, Socket_StreamEventsServer) error {
return status.Errorf(codes.Unimplemented, "method StreamEvents not implemented") return status.Errorf(codes.Unimplemented, "method StreamEvents not implemented")
} }
func (UnimplementedSocketServer) UnWait(context.Context, *UnWaitParams) (*Empty, error) { func (UnimplementedSocketServer) UnWait(context.Context, *Empty) (*Empty, error) {
return nil, status.Errorf(codes.Unimplemented, "method UnWait not implemented") return nil, status.Errorf(codes.Unimplemented, "method UnWait not implemented")
} }
func (UnimplementedSocketServer) Stop(context.Context, *StopParams) (*Empty, error) { func (UnimplementedSocketServer) Stop(context.Context, *Empty) (*Empty, error) {
return nil, status.Errorf(codes.Unimplemented, "method Stop not implemented") return nil, status.Errorf(codes.Unimplemented, "method Stop not implemented")
} }
func (UnimplementedSocketServer) mustEmbedUnimplementedSocketServer() {} func (UnimplementedSocketServer) mustEmbedUnimplementedSocketServer() {}
@@ -122,7 +122,7 @@ func RegisterSocketServer(s grpc.ServiceRegistrar, srv SocketServer) {
} }
func _Socket_StreamEvents_Handler(srv interface{}, stream grpc.ServerStream) error { func _Socket_StreamEvents_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(StreamEventsParams) m := new(Empty)
if err := stream.RecvMsg(m); err != nil { if err := stream.RecvMsg(m); err != nil {
return err return err
} }
@@ -143,7 +143,7 @@ func (x *socketStreamEventsServer) Send(m *Event) error {
} }
func _Socket_UnWait_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { func _Socket_UnWait_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UnWaitParams) in := new(Empty)
if err := dec(in); err != nil { if err := dec(in); err != nil {
return nil, err return nil, err
} }
@@ -155,13 +155,13 @@ func _Socket_UnWait_Handler(srv interface{}, ctx context.Context, dec func(inter
FullMethod: "/wice.Socket/UnWait", FullMethod: "/wice.Socket/UnWait",
} }
handler := func(ctx context.Context, req interface{}) (interface{}, error) { handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(SocketServer).UnWait(ctx, req.(*UnWaitParams)) return srv.(SocketServer).UnWait(ctx, req.(*Empty))
} }
return interceptor(ctx, in, info, handler) return interceptor(ctx, in, info, handler)
} }
func _Socket_Stop_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { func _Socket_Stop_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(StopParams) in := new(Empty)
if err := dec(in); err != nil { if err := dec(in); err != nil {
return nil, err return nil, err
} }
@@ -173,7 +173,7 @@ func _Socket_Stop_Handler(srv interface{}, ctx context.Context, dec func(interfa
FullMethod: "/wice.Socket/Stop", FullMethod: "/wice.Socket/Stop",
} }
handler := func(ctx context.Context, req interface{}) (interface{}, error) { handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(SocketServer).Stop(ctx, req.(*StopParams)) return srv.(SocketServer).Stop(ctx, req.(*Empty))
} }
return interceptor(ctx, in, info, handler) return interceptor(ctx, in, info, handler)
} }
@@ -208,7 +208,7 @@ var Socket_ServiceDesc = grpc.ServiceDesc{
// //
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
type WatcherClient interface { type WatcherClient interface {
Sync(ctx context.Context, in *SyncParams, opts ...grpc.CallOption) (*Empty, error) Sync(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error)
GetStatus(ctx context.Context, in *StatusParams, opts ...grpc.CallOption) (*StatusResp, error) GetStatus(ctx context.Context, in *StatusParams, opts ...grpc.CallOption) (*StatusResp, error)
RemoveInterface(ctx context.Context, in *RemoveInterfaceParams, opts ...grpc.CallOption) (*Empty, error) RemoveInterface(ctx context.Context, in *RemoveInterfaceParams, opts ...grpc.CallOption) (*Empty, error)
SyncInterfaceConfig(ctx context.Context, in *InterfaceConfigParams, opts ...grpc.CallOption) (*Empty, error) SyncInterfaceConfig(ctx context.Context, in *InterfaceConfigParams, opts ...grpc.CallOption) (*Empty, error)
@@ -227,7 +227,7 @@ func NewWatcherClient(cc grpc.ClientConnInterface) WatcherClient {
return &watcherClient{cc} return &watcherClient{cc}
} }
func (c *watcherClient) Sync(ctx context.Context, in *SyncParams, opts ...grpc.CallOption) (*Empty, error) { func (c *watcherClient) Sync(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) {
out := new(Empty) out := new(Empty)
err := c.cc.Invoke(ctx, "/wice.Watcher/Sync", in, out, opts...) err := c.cc.Invoke(ctx, "/wice.Watcher/Sync", in, out, opts...)
if err != nil { if err != nil {
@@ -303,7 +303,7 @@ func (c *watcherClient) PutSignalingMessage(ctx context.Context, in *PutSignalin
// All implementations must embed UnimplementedWatcherServer // All implementations must embed UnimplementedWatcherServer
// for forward compatibility // for forward compatibility
type WatcherServer interface { type WatcherServer interface {
Sync(context.Context, *SyncParams) (*Empty, error) Sync(context.Context, *Empty) (*Empty, error)
GetStatus(context.Context, *StatusParams) (*StatusResp, error) GetStatus(context.Context, *StatusParams) (*StatusResp, error)
RemoveInterface(context.Context, *RemoveInterfaceParams) (*Empty, error) RemoveInterface(context.Context, *RemoveInterfaceParams) (*Empty, error)
SyncInterfaceConfig(context.Context, *InterfaceConfigParams) (*Empty, error) SyncInterfaceConfig(context.Context, *InterfaceConfigParams) (*Empty, error)
@@ -319,7 +319,7 @@ type WatcherServer interface {
type UnimplementedWatcherServer struct { type UnimplementedWatcherServer struct {
} }
func (UnimplementedWatcherServer) Sync(context.Context, *SyncParams) (*Empty, error) { func (UnimplementedWatcherServer) Sync(context.Context, *Empty) (*Empty, error) {
return nil, status.Errorf(codes.Unimplemented, "method Sync not implemented") return nil, status.Errorf(codes.Unimplemented, "method Sync not implemented")
} }
func (UnimplementedWatcherServer) GetStatus(context.Context, *StatusParams) (*StatusResp, error) { func (UnimplementedWatcherServer) GetStatus(context.Context, *StatusParams) (*StatusResp, error) {
@@ -357,7 +357,7 @@ func RegisterWatcherServer(s grpc.ServiceRegistrar, srv WatcherServer) {
} }
func _Watcher_Sync_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { func _Watcher_Sync_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SyncParams) in := new(Empty)
if err := dec(in); err != nil { if err := dec(in); err != nil {
return nil, err return nil, err
} }
@@ -369,7 +369,7 @@ func _Watcher_Sync_Handler(srv interface{}, ctx context.Context, dec func(interf
FullMethod: "/wice.Watcher/Sync", FullMethod: "/wice.Watcher/Sync",
} }
handler := func(ctx context.Context, req interface{}) (interface{}, error) { handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(WatcherServer).Sync(ctx, req.(*SyncParams)) return srv.(WatcherServer).Sync(ctx, req.(*Empty))
} }
return interceptor(ctx, in, info, handler) return interceptor(ctx, in, info, handler)
} }

View File

@@ -79,7 +79,7 @@ func Connect(path string) (*Client, error) {
go client.streamEvents() go client.streamEvents()
_, err = client.UnWait(context.Background(), &pb.UnWaitParams{}) _, err = client.UnWait(context.Background(), &pb.Empty{})
if sts := status.Convert(err); sts != nil && sts.Code() != codes.AlreadyExists { if sts := status.Convert(err); sts != nil && sts.Code() != codes.AlreadyExists {
return nil, fmt.Errorf("failed RPC request: %w", err) return nil, fmt.Errorf("failed RPC request: %w", err)
} }
@@ -102,7 +102,7 @@ func (c *Client) streamEvents() {
c.Events = make(chan *pb.Event, 100) c.Events = make(chan *pb.Event, 100)
defer close(c.Events) defer close(c.Events)
stream, err := c.StreamEvents(context.Background(), &pb.StreamEventsParams{}) stream, err := c.StreamEvents(context.Background(), &pb.Empty{})
if err != nil { if err != nil {
c.logger.Error("Failed to stream events", zap.Error(err)) c.logger.Error("Failed to stream events", zap.Error(err))
return return

View File

@@ -29,7 +29,7 @@ func NewDaemonServer(s *Server, d *wice.Daemon) *DaemonServer {
return ds return ds
} }
func (s *DaemonServer) StreamEvents(params *pb.StreamEventsParams, stream pb.Socket_StreamEventsServer) error { func (s *DaemonServer) StreamEvents(params *pb.Empty, stream pb.Socket_StreamEventsServer) error {
// Send initial connection state of all peers // Send initial connection state of all peers
if s.epice != nil { if s.epice != nil {
@@ -57,7 +57,7 @@ out:
return nil return nil
} }
func (s *DaemonServer) UnWait(ctx context.Context, params *pb.UnWaitParams) (*pb.Empty, error) { func (s *DaemonServer) UnWait(ctx context.Context, params *pb.Empty) (*pb.Empty, error) {
err := status.Error(codes.AlreadyExists, "RPC socket has already been unwaited") err := status.Error(codes.AlreadyExists, "RPC socket has already been unwaited")
s.waitOnce.Do(func() { s.waitOnce.Do(func() {
@@ -68,7 +68,7 @@ func (s *DaemonServer) UnWait(ctx context.Context, params *pb.UnWaitParams) (*pb
return &pb.Empty{}, err return &pb.Empty{}, err
} }
func (s *DaemonServer) Stop(ctx context.Context, params *pb.StopParams) (*pb.Empty, error) { func (s *DaemonServer) Stop(ctx context.Context, params *pb.Empty) (*pb.Empty, error) {
s.Daemon.Stop() s.Daemon.Stop()
return &pb.Empty{}, nil return &pb.Empty{}, nil

View File

@@ -79,7 +79,7 @@ func (s *WatcherServer) GetStatus(ctx context.Context, p *pb.StatusParams) (*pb.
}, nil }, nil
} }
func (s *WatcherServer) Sync(ctx context.Context, params *pb.SyncParams) (*pb.Empty, error) { func (s *WatcherServer) Sync(ctx context.Context, params *pb.Empty) (*pb.Empty, error) {
if err := s.Watcher.Sync(); err != nil { if err := s.Watcher.Sync(); err != nil {
return &pb.Empty{}, status.Errorf(codes.Unknown, "failed to sync: %s", err) return &pb.Empty{}, status.Errorf(codes.Unknown, "failed to sync: %s", err)
} }