diff --git a/api/go/gosdn/plugin-registry/plugin-registry.pb.go b/api/go/gosdn/plugin-registry/plugin-registry.pb.go index 66ded0daf823c6a2fce376802e0b921e2e38ffd8..abedd4ee06c059ee532286919bb54ea80954a62c 100644 --- a/api/go/gosdn/plugin-registry/plugin-registry.pb.go +++ b/api/go/gosdn/plugin-registry/plugin-registry.pb.go @@ -8,7 +8,6 @@ package plugin_registry import ( _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" - _ "google.golang.org/genproto/googleapis/api/annotations" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" _ "google.golang.org/protobuf/types/known/timestamppb" @@ -566,102 +565,6 @@ func (x *Manifest) GetVersion() string { return "" } -type GetAvailablePluginsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. - Plugins []*Plugin `protobuf:"bytes,2,rep,name=plugins,proto3" json:"plugins,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetAvailablePluginsResponse) Reset() { - *x = GetAvailablePluginsResponse{} - mi := &file_gosdn_plugin_registry_plugin_registry_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetAvailablePluginsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAvailablePluginsResponse) ProtoMessage() {} - -func (x *GetAvailablePluginsResponse) ProtoReflect() protoreflect.Message { - mi := &file_gosdn_plugin_registry_plugin_registry_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAvailablePluginsResponse.ProtoReflect.Descriptor instead. -func (*GetAvailablePluginsResponse) Descriptor() ([]byte, []int) { - return file_gosdn_plugin_registry_plugin_registry_proto_rawDescGZIP(), []int{10} -} - -func (x *GetAvailablePluginsResponse) GetTimestamp() int64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *GetAvailablePluginsResponse) GetPlugins() []*Plugin { - if x != nil { - return x.Plugins - } - return nil -} - -type GetAvailablePluginsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetAvailablePluginsRequest) Reset() { - *x = GetAvailablePluginsRequest{} - mi := &file_gosdn_plugin_registry_plugin_registry_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetAvailablePluginsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAvailablePluginsRequest) ProtoMessage() {} - -func (x *GetAvailablePluginsRequest) ProtoReflect() protoreflect.Message { - mi := &file_gosdn_plugin_registry_plugin_registry_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAvailablePluginsRequest.ProtoReflect.Descriptor instead. -func (*GetAvailablePluginsRequest) Descriptor() ([]byte, []int) { - return file_gosdn_plugin_registry_plugin_registry_proto_rawDescGZIP(), []int{11} -} - -func (x *GetAvailablePluginsRequest) GetTimestamp() int64 { - if x != nil { - return x.Timestamp - } - return 0 -} - var File_gosdn_plugin_registry_plugin_registry_proto protoreflect.FileDescriptor var file_gosdn_plugin_registry_plugin_registry_proto_rawDesc = string([]byte{ @@ -673,68 +576,55 @@ var file_gosdn_plugin_registry_plugin_registry_proto_rawDesc = string([]byte{ 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, 0x62, 0x75, 0x66, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, - 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x22, 0x66, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, - 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x3a, 0x0a, 0x05, - 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x67, 0x6f, - 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, - 0x74, 0x72, 0x79, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, - 0x01, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x22, 0x2d, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x41, - 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, - 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x4d, 0x0a, 0x05, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x12, 0x18, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, - 0x03, 0xc8, 0x01, 0x01, 0x48, 0x00, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x04, 0x6e, 0x61, - 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, - 0x48, 0x00, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x42, 0x0c, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, - 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x22, 0x64, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x12, 0x37, 0x0a, 0x07, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x18, 0x02, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, - 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, 0x50, 0x6c, 0x75, - 0x67, 0x69, 0x6e, 0x52, 0x07, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x22, 0x4a, 0x0a, 0x12, - 0x47, 0x65, 0x74, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, - 0x12, 0x16, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, - 0x03, 0xc8, 0x01, 0x01, 0x52, 0x02, 0x69, 0x64, 0x22, 0x2a, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x44, - 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x14, - 0x0a, 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x63, - 0x68, 0x75, 0x6e, 0x6b, 0x22, 0x45, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x12, 0x16, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x42, - 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x02, 0x69, 0x64, 0x22, 0x2e, 0x0a, 0x0e, 0x44, - 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a, - 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x55, 0x0a, 0x06, 0x50, - 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x3b, 0x0a, 0x08, 0x6d, 0x61, 0x6e, 0x69, 0x66, 0x65, 0x73, - 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, - 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, - 0x4d, 0x61, 0x6e, 0x69, 0x66, 0x65, 0x73, 0x74, 0x52, 0x08, 0x6d, 0x61, 0x6e, 0x69, 0x66, 0x65, - 0x73, 0x74, 0x22, 0x6c, 0x0a, 0x08, 0x4d, 0x61, 0x6e, 0x69, 0x66, 0x65, 0x73, 0x74, 0x12, 0x12, - 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, - 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x72, 0x6d, 0x77, 0x61, 0x72, 0x65, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x72, 0x6d, 0x77, 0x61, 0x72, 0x65, 0x12, 0x16, - 0x0a, 0x06, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, - 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, - 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, - 0x22, 0x74, 0x0a, 0x1b, 0x47, 0x65, 0x74, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, - 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x37, 0x0a, - 0x07, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, - 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, - 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x52, 0x07, 0x70, - 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x22, 0x3a, 0x0a, 0x1a, 0x47, 0x65, 0x74, 0x41, 0x76, 0x61, - 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x52, 0x65, 0x71, + 0x74, 0x6f, 0x22, 0x66, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x3a, + 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, + 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, + 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x42, 0x06, 0xba, 0x48, 0x03, + 0xc8, 0x01, 0x01, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x22, 0x2d, 0x0a, 0x0d, 0x47, 0x65, + 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, + 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, + 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x4d, 0x0a, 0x05, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x12, 0x18, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, + 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x48, 0x00, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, + 0x01, 0x01, 0x48, 0x00, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x42, 0x0c, 0x0a, 0x0a, 0x69, 0x64, + 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x22, 0x64, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x37, 0x0a, 0x07, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, + 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, + 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, 0x50, + 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x52, 0x07, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x22, 0x4a, + 0x0a, 0x12, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x32, 0xf4, 0x02, 0x0a, 0x15, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x67, + 0x6d, 0x70, 0x12, 0x16, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, + 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x02, 0x69, 0x64, 0x22, 0x2a, 0x0a, 0x12, 0x47, 0x65, + 0x74, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, + 0x12, 0x14, 0x0a, 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, + 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x22, 0x45, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x16, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, + 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x02, 0x69, 0x64, 0x22, 0x2e, 0x0a, + 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0x55, 0x0a, + 0x06, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x3b, 0x0a, 0x08, 0x6d, 0x61, 0x6e, 0x69, 0x66, + 0x65, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x67, 0x6f, 0x73, 0x64, + 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, + 0x79, 0x2e, 0x4d, 0x61, 0x6e, 0x69, 0x66, 0x65, 0x73, 0x74, 0x52, 0x08, 0x6d, 0x61, 0x6e, 0x69, + 0x66, 0x65, 0x73, 0x74, 0x22, 0x6c, 0x0a, 0x08, 0x4d, 0x61, 0x6e, 0x69, 0x66, 0x65, 0x73, 0x74, + 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x72, 0x6d, 0x77, 0x61, 0x72, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x69, 0x72, 0x6d, 0x77, 0x61, 0x72, 0x65, + 0x12, 0x16, 0x0a, 0x06, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x06, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, + 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, + 0x6f, 0x6e, 0x32, 0xf4, 0x02, 0x0a, 0x15, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x4c, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x21, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x79, 0x2e, 0x47, 0x65, 0x74, 0x52, @@ -776,39 +666,36 @@ func file_gosdn_plugin_registry_plugin_registry_proto_rawDescGZIP() []byte { return file_gosdn_plugin_registry_plugin_registry_proto_rawDescData } -var file_gosdn_plugin_registry_plugin_registry_proto_msgTypes = make([]protoimpl.MessageInfo, 12) +var file_gosdn_plugin_registry_plugin_registry_proto_msgTypes = make([]protoimpl.MessageInfo, 10) var file_gosdn_plugin_registry_plugin_registry_proto_goTypes = []any{ - (*GetRequest)(nil), // 0: gosdn.plugin_registry.GetRequest - (*GetAllRequest)(nil), // 1: gosdn.plugin_registry.GetAllRequest - (*Query)(nil), // 2: gosdn.plugin_registry.Query - (*GetResponse)(nil), // 3: gosdn.plugin_registry.GetResponse - (*GetDownloadRequest)(nil), // 4: gosdn.plugin_registry.GetDownloadRequest - (*GetDownloadPayload)(nil), // 5: gosdn.plugin_registry.GetDownloadPayload - (*DeleteRequest)(nil), // 6: gosdn.plugin_registry.DeleteRequest - (*DeleteResponse)(nil), // 7: gosdn.plugin_registry.DeleteResponse - (*Plugin)(nil), // 8: gosdn.plugin_registry.Plugin - (*Manifest)(nil), // 9: gosdn.plugin_registry.Manifest - (*GetAvailablePluginsResponse)(nil), // 10: gosdn.plugin_registry.GetAvailablePluginsResponse - (*GetAvailablePluginsRequest)(nil), // 11: gosdn.plugin_registry.GetAvailablePluginsRequest + (*GetRequest)(nil), // 0: gosdn.plugin_registry.GetRequest + (*GetAllRequest)(nil), // 1: gosdn.plugin_registry.GetAllRequest + (*Query)(nil), // 2: gosdn.plugin_registry.Query + (*GetResponse)(nil), // 3: gosdn.plugin_registry.GetResponse + (*GetDownloadRequest)(nil), // 4: gosdn.plugin_registry.GetDownloadRequest + (*GetDownloadPayload)(nil), // 5: gosdn.plugin_registry.GetDownloadPayload + (*DeleteRequest)(nil), // 6: gosdn.plugin_registry.DeleteRequest + (*DeleteResponse)(nil), // 7: gosdn.plugin_registry.DeleteResponse + (*Plugin)(nil), // 8: gosdn.plugin_registry.Plugin + (*Manifest)(nil), // 9: gosdn.plugin_registry.Manifest } var file_gosdn_plugin_registry_plugin_registry_proto_depIdxs = []int32{ 2, // 0: gosdn.plugin_registry.GetRequest.query:type_name -> gosdn.plugin_registry.Query 8, // 1: gosdn.plugin_registry.GetResponse.plugins:type_name -> gosdn.plugin_registry.Plugin 9, // 2: gosdn.plugin_registry.Plugin.manifest:type_name -> gosdn.plugin_registry.Manifest - 8, // 3: gosdn.plugin_registry.GetAvailablePluginsResponse.plugins:type_name -> gosdn.plugin_registry.Plugin - 0, // 4: gosdn.plugin_registry.PluginRegistryService.Get:input_type -> gosdn.plugin_registry.GetRequest - 1, // 5: gosdn.plugin_registry.PluginRegistryService.GetAll:input_type -> gosdn.plugin_registry.GetAllRequest - 4, // 6: gosdn.plugin_registry.PluginRegistryService.Download:input_type -> gosdn.plugin_registry.GetDownloadRequest - 6, // 7: gosdn.plugin_registry.PluginRegistryService.Delete:input_type -> gosdn.plugin_registry.DeleteRequest - 3, // 8: gosdn.plugin_registry.PluginRegistryService.Get:output_type -> gosdn.plugin_registry.GetResponse - 3, // 9: gosdn.plugin_registry.PluginRegistryService.GetAll:output_type -> gosdn.plugin_registry.GetResponse - 5, // 10: gosdn.plugin_registry.PluginRegistryService.Download:output_type -> gosdn.plugin_registry.GetDownloadPayload - 7, // 11: gosdn.plugin_registry.PluginRegistryService.Delete:output_type -> gosdn.plugin_registry.DeleteResponse - 8, // [8:12] is the sub-list for method output_type - 4, // [4:8] 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 extendee - 0, // [0:4] is the sub-list for field type_name + 0, // 3: gosdn.plugin_registry.PluginRegistryService.Get:input_type -> gosdn.plugin_registry.GetRequest + 1, // 4: gosdn.plugin_registry.PluginRegistryService.GetAll:input_type -> gosdn.plugin_registry.GetAllRequest + 4, // 5: gosdn.plugin_registry.PluginRegistryService.Download:input_type -> gosdn.plugin_registry.GetDownloadRequest + 6, // 6: gosdn.plugin_registry.PluginRegistryService.Delete:input_type -> gosdn.plugin_registry.DeleteRequest + 3, // 7: gosdn.plugin_registry.PluginRegistryService.Get:output_type -> gosdn.plugin_registry.GetResponse + 3, // 8: gosdn.plugin_registry.PluginRegistryService.GetAll:output_type -> gosdn.plugin_registry.GetResponse + 5, // 9: gosdn.plugin_registry.PluginRegistryService.Download:output_type -> gosdn.plugin_registry.GetDownloadPayload + 7, // 10: gosdn.plugin_registry.PluginRegistryService.Delete:output_type -> gosdn.plugin_registry.DeleteResponse + 7, // [7:11] is the sub-list for method output_type + 3, // [3:7] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name } func init() { file_gosdn_plugin_registry_plugin_registry_proto_init() } @@ -826,7 +713,7 @@ func file_gosdn_plugin_registry_plugin_registry_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_gosdn_plugin_registry_plugin_registry_proto_rawDesc), len(file_gosdn_plugin_registry_plugin_registry_proto_rawDesc)), NumEnums: 0, - NumMessages: 12, + NumMessages: 10, NumExtensions: 0, NumServices: 1, }, diff --git a/api/go/gosdn/plugin/plugin.pb.go b/api/go/gosdn/plugin/plugin.pb.go index 9f4ca7edd51023d60ad2816b4a619ff24f1b9235..57f3307c370e29c1e36dbff443aec091cf9bf711 100644 --- a/api/go/gosdn/plugin/plugin.pb.go +++ b/api/go/gosdn/plugin/plugin.pb.go @@ -9,7 +9,7 @@ package plugin import ( _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" networkelement "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/networkelement" - plugin_registry "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/plugin-registry" + _ "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/plugin-registry" gnmi "github.com/openconfig/gnmi/proto/gnmi" _ "google.golang.org/genproto/googleapis/api/annotations" protoreflect "google.golang.org/protobuf/reflect/protoreflect" @@ -866,50 +866,6 @@ func (x *Payload) GetChunk() []byte { return nil } -type GetAvailablePluginsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetAvailablePluginsRequest) Reset() { - *x = GetAvailablePluginsRequest{} - mi := &file_gosdn_plugin_plugin_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetAvailablePluginsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAvailablePluginsRequest) ProtoMessage() {} - -func (x *GetAvailablePluginsRequest) ProtoReflect() protoreflect.Message { - mi := &file_gosdn_plugin_plugin_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAvailablePluginsRequest.ProtoReflect.Descriptor instead. -func (*GetAvailablePluginsRequest) Descriptor() ([]byte, []int) { - return file_gosdn_plugin_plugin_proto_rawDescGZIP(), []int{18} -} - -func (x *GetAvailablePluginsRequest) GetTimestamp() int64 { - if x != nil { - return x.Timestamp - } - return 0 -} - var File_gosdn_plugin_plugin_proto protoreflect.FileDescriptor var file_gosdn_plugin_plugin_proto_rawDesc = string([]byte{ @@ -1007,65 +963,55 @@ var file_gosdn_plugin_plugin_proto_rawDesc = string([]byte{ 0x65, 0x6d, 0x61, 0x54, 0x72, 0x65, 0x65, 0x47, 0x7a, 0x69, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x1f, 0x0a, 0x07, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x68, 0x75, 0x6e, 0x6b, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x63, 0x68, - 0x75, 0x6e, 0x6b, 0x22, 0x3a, 0x0a, 0x1a, 0x47, 0x65, 0x74, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, - 0x62, 0x6c, 0x65, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x32, - 0xad, 0x06, 0x0a, 0x06, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x4c, 0x0a, 0x09, 0x55, 0x6e, - 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x12, 0x1e, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, - 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, - 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x46, 0x0a, 0x07, 0x53, 0x65, 0x74, 0x4e, - 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, - 0x69, 0x6e, 0x2e, 0x53, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x1d, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, - 0x2e, 0x53, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x46, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x2e, 0x67, 0x6f, - 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x47, 0x65, 0x74, 0x4e, 0x6f, - 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x67, 0x6f, 0x73, 0x64, - 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x47, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4f, 0x0a, 0x0a, 0x44, 0x65, 0x6c, 0x65, - 0x74, 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, - 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x4e, 0x6f, 0x64, 0x65, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, - 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x4e, 0x6f, 0x64, - 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x05, 0x4d, 0x6f, 0x64, - 0x65, 0x6c, 0x12, 0x1a, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, - 0x6e, 0x2e, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, - 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x4d, 0x6f, - 0x64, 0x65, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3d, 0x0a, 0x04, 0x44, - 0x69, 0x66, 0x66, 0x12, 0x19, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, - 0x69, 0x6e, 0x2e, 0x44, 0x69, 0x66, 0x66, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, - 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x69, - 0x66, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4e, 0x0a, 0x0e, 0x53, 0x63, - 0x68, 0x65, 0x6d, 0x61, 0x54, 0x72, 0x65, 0x65, 0x47, 0x7a, 0x69, 0x70, 0x12, 0x23, 0x2e, 0x67, - 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x53, 0x63, 0x68, 0x65, - 0x6d, 0x61, 0x54, 0x72, 0x65, 0x65, 0x47, 0x7a, 0x69, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x15, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, - 0x2e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x30, 0x01, 0x12, 0x5b, 0x0a, 0x0e, 0x56, 0x61, - 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x23, 0x2e, 0x67, - 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x56, 0x61, 0x6c, 0x69, - 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x24, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, - 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x61, 0x0a, 0x10, 0x50, 0x72, 0x75, 0x6e, 0x65, - 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x12, 0x25, 0x2e, 0x67, 0x6f, - 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x50, 0x72, 0x75, 0x6e, 0x65, - 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, - 0x6e, 0x2e, 0x50, 0x72, 0x75, 0x6e, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x46, 0x61, 0x6c, - 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x63, 0x0a, 0x13, 0x47, 0x65, - 0x74, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, - 0x73, 0x12, 0x28, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, - 0x2e, 0x47, 0x65, 0x74, 0x41, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x6c, 0x75, - 0x67, 0x69, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x67, 0x6f, - 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x5f, 0x72, 0x65, 0x67, 0x69, 0x73, - 0x74, 0x72, 0x79, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, - 0x32, 0x5a, 0x30, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x66, 0x62, 0x69, 0x2e, 0x68, 0x2d, 0x64, 0x61, - 0x2e, 0x64, 0x65, 0x2f, 0x64, 0x61, 0x6e, 0x65, 0x74, 0x2f, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2f, - 0x61, 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2f, 0x70, 0x6c, 0x75, - 0x67, 0x69, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x75, 0x6e, 0x6b, 0x32, 0xc8, 0x05, 0x0a, 0x06, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x4c, + 0x0a, 0x09, 0x55, 0x6e, 0x6d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x12, 0x1e, 0x2e, 0x67, 0x6f, + 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x55, 0x6e, 0x6d, 0x61, 0x72, + 0x73, 0x68, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x67, 0x6f, + 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x55, 0x6e, 0x6d, 0x61, 0x72, + 0x73, 0x68, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x46, 0x0a, 0x07, + 0x53, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, + 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x53, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, + 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x53, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x46, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x12, + 0x1c, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x47, + 0x65, 0x74, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, + 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x47, 0x65, 0x74, + 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4f, 0x0a, 0x0a, + 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x1f, 0x2e, 0x67, 0x6f, 0x73, + 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, + 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x67, 0x6f, + 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, + 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, + 0x05, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x1a, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, + 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, + 0x6e, 0x2e, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x3d, 0x0a, 0x04, 0x44, 0x69, 0x66, 0x66, 0x12, 0x19, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, + 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x44, 0x69, 0x66, 0x66, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, + 0x6e, 0x2e, 0x44, 0x69, 0x66, 0x66, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4e, + 0x0a, 0x0e, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x54, 0x72, 0x65, 0x65, 0x47, 0x7a, 0x69, 0x70, + 0x12, 0x23, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, + 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x54, 0x72, 0x65, 0x65, 0x47, 0x7a, 0x69, 0x70, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, + 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x30, 0x01, 0x12, 0x5b, + 0x0a, 0x0e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, + 0x12, 0x23, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, + 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, + 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x61, 0x0a, 0x10, 0x50, + 0x72, 0x75, 0x6e, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x12, + 0x25, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x50, + 0x72, 0x75, 0x6e, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2e, 0x70, + 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x2e, 0x50, 0x72, 0x75, 0x6e, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, + 0x67, 0x46, 0x61, 0x6c, 0x73, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x32, + 0x5a, 0x30, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x66, 0x62, 0x69, 0x2e, 0x68, 0x2d, 0x64, 0x61, 0x2e, + 0x64, 0x65, 0x2f, 0x64, 0x61, 0x6e, 0x65, 0x74, 0x2f, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2f, 0x61, + 0x70, 0x69, 0x2f, 0x67, 0x6f, 0x2f, 0x67, 0x6f, 0x73, 0x64, 0x6e, 0x2f, 0x70, 0x6c, 0x75, 0x67, + 0x69, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, }) var ( @@ -1080,45 +1026,43 @@ func file_gosdn_plugin_plugin_proto_rawDescGZIP() []byte { return file_gosdn_plugin_plugin_proto_rawDescData } -var file_gosdn_plugin_plugin_proto_msgTypes = make([]protoimpl.MessageInfo, 19) +var file_gosdn_plugin_plugin_proto_msgTypes = make([]protoimpl.MessageInfo, 18) var file_gosdn_plugin_plugin_proto_goTypes = []any{ - (*UnmarshalRequest)(nil), // 0: gosdn.plugin.UnmarshalRequest - (*UnmarshalResponse)(nil), // 1: gosdn.plugin.UnmarshalResponse - (*SetNodeRequest)(nil), // 2: gosdn.plugin.SetNodeRequest - (*SetNodeResponse)(nil), // 3: gosdn.plugin.SetNodeResponse - (*GetNodeRequest)(nil), // 4: gosdn.plugin.GetNodeRequest - (*GetNodeResponse)(nil), // 5: gosdn.plugin.GetNodeResponse - (*DeleteNodeRequest)(nil), // 6: gosdn.plugin.DeleteNodeRequest - (*DeleteNodeResponse)(nil), // 7: gosdn.plugin.DeleteNodeResponse - (*ModelRequest)(nil), // 8: gosdn.plugin.ModelRequest - (*ModelResponse)(nil), // 9: gosdn.plugin.ModelResponse - (*DiffRequest)(nil), // 10: gosdn.plugin.DiffRequest - (*DiffResponse)(nil), // 11: gosdn.plugin.DiffResponse - (*ValidateChangeRequest)(nil), // 12: gosdn.plugin.ValidateChangeRequest - (*ValidateChangeResponse)(nil), // 13: gosdn.plugin.ValidateChangeResponse - (*PruneConfigFalseRequest)(nil), // 14: gosdn.plugin.PruneConfigFalseRequest - (*PruneConfigFalseResponse)(nil), // 15: gosdn.plugin.PruneConfigFalseResponse - (*SchemaTreeGzipRequest)(nil), // 16: gosdn.plugin.SchemaTreeGzipRequest - (*Payload)(nil), // 17: gosdn.plugin.Payload - (*GetAvailablePluginsRequest)(nil), // 18: gosdn.plugin.GetAvailablePluginsRequest - (*gnmi.Path)(nil), // 19: gnmi.Path - (*gnmi.TypedValue)(nil), // 20: gnmi.TypedValue - (*gnmi.Notification)(nil), // 21: gnmi.Notification - (networkelement.ApiOperation)(0), // 22: gosdn.networkelement.ApiOperation - (*plugin_registry.GetResponse)(nil), // 23: gosdn.plugin_registry.GetResponse + (*UnmarshalRequest)(nil), // 0: gosdn.plugin.UnmarshalRequest + (*UnmarshalResponse)(nil), // 1: gosdn.plugin.UnmarshalResponse + (*SetNodeRequest)(nil), // 2: gosdn.plugin.SetNodeRequest + (*SetNodeResponse)(nil), // 3: gosdn.plugin.SetNodeResponse + (*GetNodeRequest)(nil), // 4: gosdn.plugin.GetNodeRequest + (*GetNodeResponse)(nil), // 5: gosdn.plugin.GetNodeResponse + (*DeleteNodeRequest)(nil), // 6: gosdn.plugin.DeleteNodeRequest + (*DeleteNodeResponse)(nil), // 7: gosdn.plugin.DeleteNodeResponse + (*ModelRequest)(nil), // 8: gosdn.plugin.ModelRequest + (*ModelResponse)(nil), // 9: gosdn.plugin.ModelResponse + (*DiffRequest)(nil), // 10: gosdn.plugin.DiffRequest + (*DiffResponse)(nil), // 11: gosdn.plugin.DiffResponse + (*ValidateChangeRequest)(nil), // 12: gosdn.plugin.ValidateChangeRequest + (*ValidateChangeResponse)(nil), // 13: gosdn.plugin.ValidateChangeResponse + (*PruneConfigFalseRequest)(nil), // 14: gosdn.plugin.PruneConfigFalseRequest + (*PruneConfigFalseResponse)(nil), // 15: gosdn.plugin.PruneConfigFalseResponse + (*SchemaTreeGzipRequest)(nil), // 16: gosdn.plugin.SchemaTreeGzipRequest + (*Payload)(nil), // 17: gosdn.plugin.Payload + (*gnmi.Path)(nil), // 18: gnmi.Path + (*gnmi.TypedValue)(nil), // 19: gnmi.TypedValue + (*gnmi.Notification)(nil), // 20: gnmi.Notification + (networkelement.ApiOperation)(0), // 21: gosdn.networkelement.ApiOperation } var file_gosdn_plugin_plugin_proto_depIdxs = []int32{ - 19, // 0: gosdn.plugin.UnmarshalRequest.path:type_name -> gnmi.Path - 20, // 1: gosdn.plugin.UnmarshalRequest.value:type_name -> gnmi.TypedValue - 19, // 2: gosdn.plugin.SetNodeRequest.path:type_name -> gnmi.Path - 20, // 3: gosdn.plugin.SetNodeRequest.value:type_name -> gnmi.TypedValue - 19, // 4: gosdn.plugin.GetNodeRequest.path:type_name -> gnmi.Path - 21, // 5: gosdn.plugin.GetNodeResponse.nodes:type_name -> gnmi.Notification - 19, // 6: gosdn.plugin.DeleteNodeRequest.path:type_name -> gnmi.Path - 21, // 7: gosdn.plugin.DiffResponse.notification:type_name -> gnmi.Notification - 22, // 8: gosdn.plugin.ValidateChangeRequest.operation:type_name -> gosdn.networkelement.ApiOperation - 19, // 9: gosdn.plugin.ValidateChangeRequest.path:type_name -> gnmi.Path - 20, // 10: gosdn.plugin.ValidateChangeRequest.value:type_name -> gnmi.TypedValue + 18, // 0: gosdn.plugin.UnmarshalRequest.path:type_name -> gnmi.Path + 19, // 1: gosdn.plugin.UnmarshalRequest.value:type_name -> gnmi.TypedValue + 18, // 2: gosdn.plugin.SetNodeRequest.path:type_name -> gnmi.Path + 19, // 3: gosdn.plugin.SetNodeRequest.value:type_name -> gnmi.TypedValue + 18, // 4: gosdn.plugin.GetNodeRequest.path:type_name -> gnmi.Path + 20, // 5: gosdn.plugin.GetNodeResponse.nodes:type_name -> gnmi.Notification + 18, // 6: gosdn.plugin.DeleteNodeRequest.path:type_name -> gnmi.Path + 20, // 7: gosdn.plugin.DiffResponse.notification:type_name -> gnmi.Notification + 21, // 8: gosdn.plugin.ValidateChangeRequest.operation:type_name -> gosdn.networkelement.ApiOperation + 18, // 9: gosdn.plugin.ValidateChangeRequest.path:type_name -> gnmi.Path + 19, // 10: gosdn.plugin.ValidateChangeRequest.value:type_name -> gnmi.TypedValue 0, // 11: gosdn.plugin.Plugin.Unmarshal:input_type -> gosdn.plugin.UnmarshalRequest 2, // 12: gosdn.plugin.Plugin.SetNode:input_type -> gosdn.plugin.SetNodeRequest 4, // 13: gosdn.plugin.Plugin.GetNode:input_type -> gosdn.plugin.GetNodeRequest @@ -1128,19 +1072,17 @@ var file_gosdn_plugin_plugin_proto_depIdxs = []int32{ 16, // 17: gosdn.plugin.Plugin.SchemaTreeGzip:input_type -> gosdn.plugin.SchemaTreeGzipRequest 12, // 18: gosdn.plugin.Plugin.ValidateChange:input_type -> gosdn.plugin.ValidateChangeRequest 14, // 19: gosdn.plugin.Plugin.PruneConfigFalse:input_type -> gosdn.plugin.PruneConfigFalseRequest - 18, // 20: gosdn.plugin.Plugin.GetAvailablePlugins:input_type -> gosdn.plugin.GetAvailablePluginsRequest - 1, // 21: gosdn.plugin.Plugin.Unmarshal:output_type -> gosdn.plugin.UnmarshalResponse - 3, // 22: gosdn.plugin.Plugin.SetNode:output_type -> gosdn.plugin.SetNodeResponse - 5, // 23: gosdn.plugin.Plugin.GetNode:output_type -> gosdn.plugin.GetNodeResponse - 7, // 24: gosdn.plugin.Plugin.DeleteNode:output_type -> gosdn.plugin.DeleteNodeResponse - 9, // 25: gosdn.plugin.Plugin.Model:output_type -> gosdn.plugin.ModelResponse - 11, // 26: gosdn.plugin.Plugin.Diff:output_type -> gosdn.plugin.DiffResponse - 17, // 27: gosdn.plugin.Plugin.SchemaTreeGzip:output_type -> gosdn.plugin.Payload - 13, // 28: gosdn.plugin.Plugin.ValidateChange:output_type -> gosdn.plugin.ValidateChangeResponse - 15, // 29: gosdn.plugin.Plugin.PruneConfigFalse:output_type -> gosdn.plugin.PruneConfigFalseResponse - 23, // 30: gosdn.plugin.Plugin.GetAvailablePlugins:output_type -> gosdn.plugin_registry.GetResponse - 21, // [21:31] is the sub-list for method output_type - 11, // [11:21] is the sub-list for method input_type + 1, // 20: gosdn.plugin.Plugin.Unmarshal:output_type -> gosdn.plugin.UnmarshalResponse + 3, // 21: gosdn.plugin.Plugin.SetNode:output_type -> gosdn.plugin.SetNodeResponse + 5, // 22: gosdn.plugin.Plugin.GetNode:output_type -> gosdn.plugin.GetNodeResponse + 7, // 23: gosdn.plugin.Plugin.DeleteNode:output_type -> gosdn.plugin.DeleteNodeResponse + 9, // 24: gosdn.plugin.Plugin.Model:output_type -> gosdn.plugin.ModelResponse + 11, // 25: gosdn.plugin.Plugin.Diff:output_type -> gosdn.plugin.DiffResponse + 17, // 26: gosdn.plugin.Plugin.SchemaTreeGzip:output_type -> gosdn.plugin.Payload + 13, // 27: gosdn.plugin.Plugin.ValidateChange:output_type -> gosdn.plugin.ValidateChangeResponse + 15, // 28: gosdn.plugin.Plugin.PruneConfigFalse:output_type -> gosdn.plugin.PruneConfigFalseResponse + 20, // [20:29] is the sub-list for method output_type + 11, // [11:20] is the sub-list for method input_type 11, // [11:11] is the sub-list for extension type_name 11, // [11:11] is the sub-list for extension extendee 0, // [0:11] is the sub-list for field type_name @@ -1157,7 +1099,7 @@ func file_gosdn_plugin_plugin_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_gosdn_plugin_plugin_proto_rawDesc), len(file_gosdn_plugin_plugin_proto_rawDesc)), NumEnums: 0, - NumMessages: 19, + NumMessages: 18, NumExtensions: 0, NumServices: 1, }, diff --git a/api/go/gosdn/plugin/plugin.pb.gw.go b/api/go/gosdn/plugin/plugin.pb.gw.go deleted file mode 100644 index 745f6caddb5b793e5366230c419b3146a0179dbc..0000000000000000000000000000000000000000 --- a/api/go/gosdn/plugin/plugin.pb.gw.go +++ /dev/null @@ -1,162 +0,0 @@ -// Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: gosdn/plugin/plugin.proto - -/* -Package plugin is a reverse proxy. - -It translates gRPC into RESTful JSON APIs. -*/ -package plugin - -import ( - "context" - "errors" - "io" - "net/http" - - "github.com/grpc-ecosystem/grpc-gateway/v2/runtime" - "github.com/grpc-ecosystem/grpc-gateway/v2/utilities" - "google.golang.org/grpc" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/grpclog" - "google.golang.org/grpc/metadata" - "google.golang.org/grpc/status" - "google.golang.org/protobuf/proto" -) - -// Suppress "imported and not used" errors -var ( - _ codes.Code - _ io.Reader - _ status.Status - _ = errors.New - _ = runtime.String - _ = utilities.NewDoubleArray - _ = metadata.Join -) - -var filter_Plugin_GetAvailablePlugins_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} - -func request_Plugin_GetAvailablePlugins_0(ctx context.Context, marshaler runtime.Marshaler, client PluginClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var ( - protoReq GetAvailablePluginsRequest - metadata runtime.ServerMetadata - ) - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Plugin_GetAvailablePlugins_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := client.GetAvailablePlugins(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) - return msg, metadata, err -} - -func local_request_Plugin_GetAvailablePlugins_0(ctx context.Context, marshaler runtime.Marshaler, server PluginServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { - var ( - protoReq GetAvailablePluginsRequest - metadata runtime.ServerMetadata - ) - if err := req.ParseForm(); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Plugin_GetAvailablePlugins_0); err != nil { - return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) - } - msg, err := server.GetAvailablePlugins(ctx, &protoReq) - return msg, metadata, err -} - -// RegisterPluginHandlerServer registers the http handlers for service Plugin to "mux". -// UnaryRPC :call PluginServer directly. -// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. -// Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterPluginHandlerFromEndpoint instead. -// GRPC interceptors will not work for this type of registration. To use interceptors, you must use the "runtime.WithMiddlewares" option in the "runtime.NewServeMux" call. -func RegisterPluginHandlerServer(ctx context.Context, mux *runtime.ServeMux, server PluginServer) error { - mux.Handle(http.MethodGet, pattern_Plugin_GetAvailablePlugins_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { - ctx, cancel := context.WithCancel(req.Context()) - defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) - inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - annotatedContext, err := runtime.AnnotateIncomingContext(ctx, mux, req, "/gosdn.plugin.Plugin/GetAvailablePlugins", runtime.WithHTTPPathPattern("/plugins/plugin")) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - resp, md, err := local_request_Plugin_GetAvailablePlugins_0(annotatedContext, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) - annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md) - if err != nil { - runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err) - return - } - forward_Plugin_GetAvailablePlugins_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - }) - - return nil -} - -// RegisterPluginHandlerFromEndpoint is same as RegisterPluginHandler but -// automatically dials to "endpoint" and closes the connection when "ctx" gets done. -func RegisterPluginHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { - conn, err := grpc.NewClient(endpoint, opts...) - if err != nil { - return err - } - defer func() { - if err != nil { - if cerr := conn.Close(); cerr != nil { - grpclog.Errorf("Failed to close conn to %s: %v", endpoint, cerr) - } - return - } - go func() { - <-ctx.Done() - if cerr := conn.Close(); cerr != nil { - grpclog.Errorf("Failed to close conn to %s: %v", endpoint, cerr) - } - }() - }() - return RegisterPluginHandler(ctx, mux, conn) -} - -// RegisterPluginHandler registers the http handlers for service Plugin to "mux". -// The handlers forward requests to the grpc endpoint over "conn". -func RegisterPluginHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { - return RegisterPluginHandlerClient(ctx, mux, NewPluginClient(conn)) -} - -// RegisterPluginHandlerClient registers the http handlers for service Plugin -// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "PluginClient". -// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "PluginClient" -// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in -// "PluginClient" to call the correct interceptors. This client ignores the HTTP middlewares. -func RegisterPluginHandlerClient(ctx context.Context, mux *runtime.ServeMux, client PluginClient) error { - mux.Handle(http.MethodGet, pattern_Plugin_GetAvailablePlugins_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { - ctx, cancel := context.WithCancel(req.Context()) - defer cancel() - inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) - annotatedContext, err := runtime.AnnotateContext(ctx, mux, req, "/gosdn.plugin.Plugin/GetAvailablePlugins", runtime.WithHTTPPathPattern("/plugins/plugin")) - if err != nil { - runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) - return - } - resp, md, err := request_Plugin_GetAvailablePlugins_0(annotatedContext, inboundMarshaler, client, req, pathParams) - annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md) - if err != nil { - runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err) - return - } - forward_Plugin_GetAvailablePlugins_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) - }) - return nil -} - -var ( - pattern_Plugin_GetAvailablePlugins_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"plugins", "plugin"}, "")) -) - -var ( - forward_Plugin_GetAvailablePlugins_0 = runtime.ForwardResponseMessage -) diff --git a/api/go/gosdn/plugin/plugin_grpc.pb.go b/api/go/gosdn/plugin/plugin_grpc.pb.go index ec194d82da166cef9fd0e4ffb0a7d404bf10a15d..e524b8c4bc2dad4a123d8fd5756c3424320a3427 100644 --- a/api/go/gosdn/plugin/plugin_grpc.pb.go +++ b/api/go/gosdn/plugin/plugin_grpc.pb.go @@ -7,7 +7,6 @@ package plugin import ( - plugin_registry "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/plugin-registry" context "context" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" @@ -20,16 +19,15 @@ import ( const _ = grpc.SupportPackageIsVersion9 const ( - Plugin_Unmarshal_FullMethodName = "/gosdn.plugin.Plugin/Unmarshal" - Plugin_SetNode_FullMethodName = "/gosdn.plugin.Plugin/SetNode" - Plugin_GetNode_FullMethodName = "/gosdn.plugin.Plugin/GetNode" - Plugin_DeleteNode_FullMethodName = "/gosdn.plugin.Plugin/DeleteNode" - Plugin_Model_FullMethodName = "/gosdn.plugin.Plugin/Model" - Plugin_Diff_FullMethodName = "/gosdn.plugin.Plugin/Diff" - Plugin_SchemaTreeGzip_FullMethodName = "/gosdn.plugin.Plugin/SchemaTreeGzip" - Plugin_ValidateChange_FullMethodName = "/gosdn.plugin.Plugin/ValidateChange" - Plugin_PruneConfigFalse_FullMethodName = "/gosdn.plugin.Plugin/PruneConfigFalse" - Plugin_GetAvailablePlugins_FullMethodName = "/gosdn.plugin.Plugin/GetAvailablePlugins" + Plugin_Unmarshal_FullMethodName = "/gosdn.plugin.Plugin/Unmarshal" + Plugin_SetNode_FullMethodName = "/gosdn.plugin.Plugin/SetNode" + Plugin_GetNode_FullMethodName = "/gosdn.plugin.Plugin/GetNode" + Plugin_DeleteNode_FullMethodName = "/gosdn.plugin.Plugin/DeleteNode" + Plugin_Model_FullMethodName = "/gosdn.plugin.Plugin/Model" + Plugin_Diff_FullMethodName = "/gosdn.plugin.Plugin/Diff" + Plugin_SchemaTreeGzip_FullMethodName = "/gosdn.plugin.Plugin/SchemaTreeGzip" + Plugin_ValidateChange_FullMethodName = "/gosdn.plugin.Plugin/ValidateChange" + Plugin_PruneConfigFalse_FullMethodName = "/gosdn.plugin.Plugin/PruneConfigFalse" ) // PluginClient is the client API for Plugin service. @@ -45,7 +43,6 @@ type PluginClient interface { SchemaTreeGzip(ctx context.Context, in *SchemaTreeGzipRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[Payload], error) ValidateChange(ctx context.Context, in *ValidateChangeRequest, opts ...grpc.CallOption) (*ValidateChangeResponse, error) PruneConfigFalse(ctx context.Context, in *PruneConfigFalseRequest, opts ...grpc.CallOption) (*PruneConfigFalseResponse, error) - GetAvailablePlugins(ctx context.Context, in *GetAvailablePluginsRequest, opts ...grpc.CallOption) (*plugin_registry.GetResponse, error) } type pluginClient struct { @@ -155,16 +152,6 @@ func (c *pluginClient) PruneConfigFalse(ctx context.Context, in *PruneConfigFals return out, nil } -func (c *pluginClient) GetAvailablePlugins(ctx context.Context, in *GetAvailablePluginsRequest, opts ...grpc.CallOption) (*plugin_registry.GetResponse, error) { - cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) - out := new(plugin_registry.GetResponse) - err := c.cc.Invoke(ctx, Plugin_GetAvailablePlugins_FullMethodName, in, out, cOpts...) - if err != nil { - return nil, err - } - return out, nil -} - // PluginServer is the server API for Plugin service. // All implementations must embed UnimplementedPluginServer // for forward compatibility. @@ -178,7 +165,6 @@ type PluginServer interface { SchemaTreeGzip(*SchemaTreeGzipRequest, grpc.ServerStreamingServer[Payload]) error ValidateChange(context.Context, *ValidateChangeRequest) (*ValidateChangeResponse, error) PruneConfigFalse(context.Context, *PruneConfigFalseRequest) (*PruneConfigFalseResponse, error) - GetAvailablePlugins(context.Context, *GetAvailablePluginsRequest) (*plugin_registry.GetResponse, error) mustEmbedUnimplementedPluginServer() } @@ -216,9 +202,6 @@ func (UnimplementedPluginServer) ValidateChange(context.Context, *ValidateChange func (UnimplementedPluginServer) PruneConfigFalse(context.Context, *PruneConfigFalseRequest) (*PruneConfigFalseResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PruneConfigFalse not implemented") } -func (UnimplementedPluginServer) GetAvailablePlugins(context.Context, *GetAvailablePluginsRequest) (*plugin_registry.GetResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetAvailablePlugins not implemented") -} func (UnimplementedPluginServer) mustEmbedUnimplementedPluginServer() {} func (UnimplementedPluginServer) testEmbeddedByValue() {} @@ -395,24 +378,6 @@ func _Plugin_PruneConfigFalse_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } -func _Plugin_GetAvailablePlugins_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetAvailablePluginsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PluginServer).GetAvailablePlugins(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: Plugin_GetAvailablePlugins_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PluginServer).GetAvailablePlugins(ctx, req.(*GetAvailablePluginsRequest)) - } - return interceptor(ctx, in, info, handler) -} - // Plugin_ServiceDesc is the grpc.ServiceDesc for Plugin service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -452,10 +417,6 @@ var Plugin_ServiceDesc = grpc.ServiceDesc{ MethodName: "PruneConfigFalse", Handler: _Plugin_PruneConfigFalse_Handler, }, - { - MethodName: "GetAvailablePlugins", - Handler: _Plugin_GetAvailablePlugins_Handler, - }, }, Streams: []grpc.StreamDesc{ { diff --git a/api/proto/gosdn/plugin-registry/plugin-registry.proto b/api/proto/gosdn/plugin-registry/plugin-registry.proto index 1210ab99c50858be92448026e0b17bc1c1c4d566..c8f99c581ec61fbccc4e0c7f874c3348434f290f 100644 --- a/api/proto/gosdn/plugin-registry/plugin-registry.proto +++ b/api/proto/gosdn/plugin-registry/plugin-registry.proto @@ -4,7 +4,6 @@ package gosdn.plugin_registry; import "google/protobuf/timestamp.proto"; import "buf/validate/validate.proto"; -import "google/api/annotations.proto"; option go_package = "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/plugin-registry"; @@ -66,12 +65,3 @@ message Manifest { string author = 3; string version = 4; } - -message GetAvailablePluginsResponse { - int64 timestamp = 1; // Timestamp in nanoseconds since Epoch. - repeated gosdn.plugin_registry.Plugin plugins = 2; -} - -message GetAvailablePluginsRequest { - int64 timestamp = 1; -} \ No newline at end of file diff --git a/api/proto/gosdn/plugin/plugin.proto b/api/proto/gosdn/plugin/plugin.proto index 6d7ca844709641343758d05f2259f4b23bb268a1..0fdf94e80ec4bb2dfa0a620789a1c5c88914d843 100644 --- a/api/proto/gosdn/plugin/plugin.proto +++ b/api/proto/gosdn/plugin/plugin.proto @@ -23,7 +23,6 @@ service Plugin { rpc SchemaTreeGzip(SchemaTreeGzipRequest) returns (stream Payload); rpc ValidateChange(ValidateChangeRequest) returns (ValidateChangeResponse); rpc PruneConfigFalse(PruneConfigFalseRequest) returns (PruneConfigFalseResponse); - rpc GetAvailablePlugins(GetAvailablePluginsRequest) returns (gosdn.plugin_registry.GetResponse); } message UnmarshalRequest { @@ -103,7 +102,3 @@ message SchemaTreeGzipRequest { message Payload { bytes chunk = 1; } - -message GetAvailablePluginsRequest { - int64 timestamp = 1; - } \ No newline at end of file diff --git a/controller/controller.go b/controller/controller.go index 3b339bd5204cbe9fffefbd571619d0dd4ac19820..a1a24aaf60deb2c47f7b2bf4dc9aa0e37bc66fa4 100644 --- a/controller/controller.go +++ b/controller/controller.go @@ -346,10 +346,8 @@ func ensureAdminRoleExists() error { "/gosdn.networkelement.NetworkElementService/DeviceSchema", "/gosdn.networkelement.NetworkElementService/Delete", "/gosdn.networkelement.NetworkElementService/SubscribePath", - "/gosdn.networkelement.NetworkElementService/ParseYang", "/gosdn.plugin_internal.PluginInternalService/AvailablePlugins", "/gosdn.plugin_internal.PluginInternalService/GetPluginSchema", - "/gosdn.plugin_internal.PluginInternalService/GetAvailablePlugins", "/gosdn.app.AppService/Register", "/gosdn.app.AppService/Deregister", "/gosdn.configurationmanagement.ConfigurationManagementService/ExportSDNConfig", diff --git a/controller/http.go b/controller/http.go index 684b8f83f39ccb0deb201799e5ac555c377b9380..394b7a0b06099a59cc2947a83e0e29fa0be7c1f6 100644 --- a/controller/http.go +++ b/controller/http.go @@ -16,7 +16,6 @@ import ( "google.golang.org/grpc/status" mnegw "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/networkelement" - plg "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/plugin-internal" pgw "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/pnd" agw "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/rbac" tgw "code.fbi.h-da.de/danet/gosdn/api/go/gosdn/topology" @@ -86,11 +85,6 @@ func setupHttpServer() error { return err } - err = plg.RegisterPluginInternalServiceHandlerFromEndpoint(ctx, mux, *grpcServerEndpoint, opts) - if err != nil { - return err - } - // Set the HTTP server of core to the new server c.httpServer = &http.Server{Addr: ":8080", Handler: mux, diff --git a/react-ui/src/components/devices/routines/plugin.routine.ts b/react-ui/src/components/devices/routines/plugin.routine.ts index ece4608f7ba8caf8a0d25558ca37532d25e6a6eb..91acc0fefa6028fbc23ade7fdd21a9b409301ab7 100644 --- a/react-ui/src/components/devices/routines/plugin.routine.ts +++ b/react-ui/src/components/devices/routines/plugin.routine.ts @@ -1,4 +1,4 @@ -import { PluginInternalServiceGetAvailablePluginsApiArg, api } from "@api/api" +import { api, PluginInternalServiceAvailablePluginsApiArg } from "@api/api" import { warnMessage } from "@helper/debug" import { createAsyncThunk } from "@reduxjs/toolkit" import { RootState } from "src/stores" @@ -17,12 +17,12 @@ export const fetchPluginsThunk = createAsyncThunk( return } - const payload: PluginInternalServiceGetAvailablePluginsApiArg = { + const payload: PluginInternalServiceAvailablePluginsApiArg = { timestamp: new Date().getTime().toString(), } - const plugins = await thunkApi.dispatch(api.endpoints.pluginInternalServiceGetAvailablePlugins.initiate(payload)) + const plugins = await thunkApi.dispatch(api.endpoints.pluginInternalServiceAvailablePlugins.initiate(payload)) if (plugins.error || !plugins.data?.plugins) { warnMessage('Plugin fetch returned an error: ' + plugins.error) diff --git a/react-ui/src/shared/api/api.ts b/react-ui/src/shared/api/api.ts index c223fa2cf6b7a9785a9b89e20049ab294d8608e9..2b9439b9669f90cb7a9d1cb9f4ae58535b96ea28 100755 --- a/react-ui/src/shared/api/api.ts +++ b/react-ui/src/shared/api/api.ts @@ -212,9 +212,9 @@ const injectedRtkApi = api }), invalidatesTags: ['NetworkElementService'], }), - pluginInternalServiceGetAvailablePlugins: build.query< - PluginInternalServiceGetAvailablePluginsApiResponse, - PluginInternalServiceGetAvailablePluginsApiArg + pluginInternalServiceAvailablePlugins: build.query< + PluginInternalServiceAvailablePluginsApiResponse, + PluginInternalServiceAvailablePluginsApiArg >({ query: queryArg => ({ url: `/plugins`, @@ -564,19 +564,6 @@ const injectedRtkApi = api }), invalidatesTags: ['UserService'], }), - networkElementServiceParseYang: build.query< - NetworkElementServiceParseYangApiResponse, - NetworkElementServiceParseYangApiArg - >({ - query: queryArg => ({ - url: `/yang/parse`, - params: { - timestamp: queryArg.timestamp, - yang: queryArg.yang, - }, - }), - providesTags: ['NetworkElementService'], - }), }), overrideExisting: false, }) @@ -686,9 +673,9 @@ export type NetworkElementServiceUpdateApiResponse = export type NetworkElementServiceUpdateApiArg = { networkelementUpdateNetworkElementRequest: TodoChangeNameToFitTheRest } -export type PluginInternalServiceGetAvailablePluginsApiResponse = +export type PluginInternalServiceAvailablePluginsApiResponse = /** status 200 A successful response. */ GosdnpluginRegistryGetResponse -export type PluginInternalServiceGetAvailablePluginsApiArg = { +export type PluginInternalServiceAvailablePluginsApiArg = { timestamp?: string } export type PndServiceGetPndApiResponse = /** status 200 A successful response. */ PndGetPndResponse @@ -849,13 +836,6 @@ export type UserServiceUpdateUsersApiResponse = export type UserServiceUpdateUsersApiArg = { rbacUpdateUsersRequest: UpdateUsers } -export type NetworkElementServiceParseYangApiResponse = - /** status 200 A successful response. */ NetworkelementParseYangResponse -export type NetworkElementServiceParseYangApiArg = { - /** Timestamp in nanoseconds since Epoch. */ - timestamp?: string - yang?: string -} export type AppAppDeregisterResponse = { timestamp?: string } @@ -1424,11 +1404,6 @@ export type UpdateUsers = { timestamp?: string user?: RbacUpdateUser[] } -export type NetworkelementParseYangResponse = { - /** Timestamp in nanoseconds since Epoch. */ - timestamp?: string - json?: string -} export const { useAppServiceDeregisterMutation, useConfigurationManagementServiceExportSdnConfigQuery, @@ -1446,7 +1421,7 @@ export const { useNetworkElementServiceGetIntendedPathQuery, useNetworkElementServiceGetPathQuery, useNetworkElementServiceUpdateMutation, - usePluginInternalServiceGetAvailablePluginsQuery, + usePluginInternalServiceAvailablePluginsQuery, usePndServiceGetPndQuery, usePndServiceGetPndListQuery, usePndServiceCreatePndListMutation, @@ -1475,5 +1450,4 @@ export const { useUserServiceDeleteUsersMutation, useUserServiceGetUserQuery, useUserServiceUpdateUsersMutation, - useNetworkElementServiceParseYangQuery, } = injectedRtkApi