diff --git a/go/gosdn/core/core.pb.go b/go/gosdn/core/core.pb.go index 1ffa1a77ba09c1ed8a552eba6da5e874a125a745..01dee433e54d97e038af932155b01c6a23fc3eef 100644 --- a/go/gosdn/core/core.pb.go +++ b/go/gosdn/core/core.pb.go @@ -123,8 +123,8 @@ type GetPndRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. - Pid string `protobuf:"bytes,3,opt,name=pid,proto3" json:"pid,omitempty"` + Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. + Pid []string `protobuf:"bytes,3,rep,name=pid,proto3" json:"pid,omitempty"` } func (x *GetPndRequest) Reset() { @@ -166,11 +166,11 @@ func (x *GetPndRequest) GetTimestamp() int64 { return 0 } -func (x *GetPndRequest) GetPid() string { +func (x *GetPndRequest) GetPid() []string { if x != nil { return x.Pid } - return "" + return nil } type GetPndListResponse struct { @@ -581,7 +581,7 @@ var file_gosdn_core_core_proto_rawDesc = []byte{ 0x50, 0x6e, 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, 0x10, 0x0a, 0x03, 0x70, 0x69, 0x64, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x70, 0x69, 0x64, 0x22, 0x67, 0x0a, 0x12, 0x47, 0x65, + 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x03, 0x70, 0x69, 0x64, 0x22, 0x67, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x50, 0x6e, 0x64, 0x4c, 0x69, 0x73, 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, 0x33, diff --git a/go/gosdn/core/core.pb.gw.go b/go/gosdn/core/core.pb.gw.go index 8c56242b632551449573f8c7e56c895e2fe3c12f..f20b6b3fcf07850e55869757651a55ebdeccda38 100644 --- a/go/gosdn/core/core.pb.gw.go +++ b/go/gosdn/core/core.pb.gw.go @@ -51,7 +51,7 @@ func request_CoreService_GetPnd_0(ctx context.Context, marshaler runtime.Marshal return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pid") } - protoReq.Pid, err = runtime.String(val) + protoReq.Pid, err = runtime.StringSlice(val, ",") if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pid", err) } @@ -84,7 +84,7 @@ func local_request_CoreService_GetPnd_0(ctx context.Context, marshaler runtime.M return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pid") } - protoReq.Pid, err = runtime.String(val) + protoReq.Pid, err = runtime.StringSlice(val, ",") if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pid", err) } diff --git a/go/gosdn/pnd/pnd.pb.go b/go/gosdn/pnd/pnd.pb.go index a22332fae58da9c5c7dc3d3617476b2aedd39554..748b56d9770c2e28002182f87f874ec6e4b0566c 100644 --- a/go/gosdn/pnd/pnd.pb.go +++ b/go/gosdn/pnd/pnd.pb.go @@ -294,9 +294,9 @@ type GetOndRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. - Did string `protobuf:"bytes,3,opt,name=did,proto3" json:"did,omitempty"` - Pid string `protobuf:"bytes,4,opt,name=pid,proto3" json:"pid,omitempty"` + Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. + Did []string `protobuf:"bytes,3,rep,name=did,proto3" json:"did,omitempty"` + Pid string `protobuf:"bytes,4,opt,name=pid,proto3" json:"pid,omitempty"` } func (x *GetOndRequest) Reset() { @@ -338,11 +338,11 @@ func (x *GetOndRequest) GetTimestamp() int64 { return 0 } -func (x *GetOndRequest) GetDid() string { +func (x *GetOndRequest) GetDid() []string { if x != nil { return x.Did } - return "" + return nil } func (x *GetOndRequest) GetPid() string { @@ -2306,7 +2306,7 @@ var file_gosdn_pnd_pnd_proto_rawDesc = []byte{ 0x65, 0x74, 0x4f, 0x6e, 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, 0x10, 0x0a, 0x03, 0x64, 0x69, - 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x64, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, + 0x64, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x03, 0x64, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x70, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x70, 0x69, 0x64, 0x22, 0x43, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x53, 0x62, 0x69, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, diff --git a/go/gosdn/pnd/pnd.pb.gw.go b/go/gosdn/pnd/pnd.pb.gw.go index 352d623cc1e492cbc73ed6609724ce297249b7cb..05cade791536aafaa08fdfcbabbc458cedeb446c 100644 --- a/go/gosdn/pnd/pnd.pb.gw.go +++ b/go/gosdn/pnd/pnd.pb.gw.go @@ -131,7 +131,7 @@ func request_PndService_GetOnd_0(ctx context.Context, marshaler runtime.Marshale return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "did") } - protoReq.Did, err = runtime.String(val) + protoReq.Did, err = runtime.StringSlice(val, ",") if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "did", err) } @@ -174,7 +174,7 @@ func local_request_PndService_GetOnd_0(ctx context.Context, marshaler runtime.Ma return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "did") } - protoReq.Did, err = runtime.String(val) + protoReq.Did, err = runtime.StringSlice(val, ",") if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "did", err) } diff --git a/openapiv2/gosdn_northbound.swagger.json b/openapiv2/gosdn_northbound.swagger.json index e1e377688728c91033ad92ec981af4d3ccffe801..0ac935cd8bc5dca8d591efcaaf29fc9feb925eb3 100644 --- a/openapiv2/gosdn_northbound.swagger.json +++ b/openapiv2/gosdn_northbound.swagger.json @@ -17,9 +17,6 @@ { "name": "PndService" }, - { - "name": "Collector" - }, { "name": "gNMI" }, @@ -27,10 +24,13 @@ "name": "CsbiService" }, { - "name": "AgentManager" + "name": "CoreService" }, { - "name": "CoreService" + "name": "Collector" + }, + { + "name": "AgentManager" } ], "consumes": [ @@ -63,7 +63,12 @@ "name": "pid", "in": "path", "required": true, - "type": "string" + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "csv", + "minItems": 1 }, { "name": "timestamp", @@ -339,7 +344,12 @@ "name": "did", "in": "path", "required": true, - "type": "string" + "type": "array", + "items": { + "type": "string" + }, + "collectionFormat": "csv", + "minItems": 1 }, { "name": "timestamp", diff --git a/proto/gosdn/core/core.proto b/proto/gosdn/core/core.proto index 0a63a27fdd986ead6ba585ddac8311226f9e5a7e..affbac00af644aa6a75dc5fcc9ff72ef386ea0f6 100644 --- a/proto/gosdn/core/core.proto +++ b/proto/gosdn/core/core.proto @@ -41,7 +41,7 @@ message GetPndListRequest { message GetPndRequest { int64 timestamp = 1; // Timestamp in nanoseconds since Epoch. - string pid = 3; + repeated string pid = 3; } message GetPndListResponse { diff --git a/proto/gosdn/pnd/pnd.proto b/proto/gosdn/pnd/pnd.proto index 41d4cbac2a6384a52d11b485f5a5e2ba93f2dfbf..6aa9bf9ee4e9671e3d638ea78208cf1b0739c9da 100644 --- a/proto/gosdn/pnd/pnd.proto +++ b/proto/gosdn/pnd/pnd.proto @@ -124,7 +124,7 @@ message GetOndListRequest { message GetOndRequest { int64 timestamp = 1; // Timestamp in nanoseconds since Epoch. - string did = 3; + repeated string did = 3; string pid = 4; }