From a5306fa9f29557cf55cf9f152ba4acd86fab1cdd Mon Sep 17 00:00:00 2001 From: Wibowo Arindrarto Date: Wed, 11 Oct 2023 08:01:40 +0200 Subject: [PATCH] feat: Define and add skeleton for ViewEntry rpc --- api/iris.pb.go | 436 +++++++++++++++++++++----------- api/iris.proto | 11 + api/iris_grpc.pb.go | 39 +++ internal/server/service.go | 8 + internal/server/service_test.go | 16 ++ 5 files changed, 358 insertions(+), 152 deletions(-) diff --git a/api/iris.pb.go b/api/iris.pb.go index 1d210f1..ca1f58f 100644 --- a/api/iris.pb.go +++ b/api/iris.pb.go @@ -943,6 +943,100 @@ func (x *EditEntriesResponse) GetEntries() []*Entry { return nil } +type ViewEntryRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *ViewEntryRequest) Reset() { + *x = ViewEntryRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_iris_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ViewEntryRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ViewEntryRequest) ProtoMessage() {} + +func (x *ViewEntryRequest) ProtoReflect() protoreflect.Message { + mi := &file_iris_proto_msgTypes[16] + 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 ViewEntryRequest.ProtoReflect.Descriptor instead. +func (*ViewEntryRequest) Descriptor() ([]byte, []int) { + return file_iris_proto_rawDescGZIP(), []int{16} +} + +func (x *ViewEntryRequest) GetId() int32 { + if x != nil { + return x.Id + } + return 0 +} + +type ViewEntryResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Entry *Entry `protobuf:"bytes,1,opt,name=entry,proto3" json:"entry,omitempty"` +} + +func (x *ViewEntryResponse) Reset() { + *x = ViewEntryResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_iris_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ViewEntryResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ViewEntryResponse) ProtoMessage() {} + +func (x *ViewEntryResponse) ProtoReflect() protoreflect.Message { + mi := &file_iris_proto_msgTypes[17] + 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 ViewEntryResponse.ProtoReflect.Descriptor instead. +func (*ViewEntryResponse) Descriptor() ([]byte, []int) { + return file_iris_proto_rawDescGZIP(), []int{17} +} + +func (x *ViewEntryResponse) GetEntry() *Entry { + if x != nil { + return x.Entry + } + return nil +} + type ExportOPMLRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -954,7 +1048,7 @@ type ExportOPMLRequest struct { func (x *ExportOPMLRequest) Reset() { *x = ExportOPMLRequest{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[16] + mi := &file_iris_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -967,7 +1061,7 @@ func (x *ExportOPMLRequest) String() string { func (*ExportOPMLRequest) ProtoMessage() {} func (x *ExportOPMLRequest) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[16] + mi := &file_iris_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -980,7 +1074,7 @@ func (x *ExportOPMLRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ExportOPMLRequest.ProtoReflect.Descriptor instead. func (*ExportOPMLRequest) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{16} + return file_iris_proto_rawDescGZIP(), []int{18} } func (x *ExportOPMLRequest) GetTitle() string { @@ -1001,7 +1095,7 @@ type ExportOPMLResponse struct { func (x *ExportOPMLResponse) Reset() { *x = ExportOPMLResponse{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[17] + mi := &file_iris_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1014,7 +1108,7 @@ func (x *ExportOPMLResponse) String() string { func (*ExportOPMLResponse) ProtoMessage() {} func (x *ExportOPMLResponse) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[17] + mi := &file_iris_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1027,7 +1121,7 @@ func (x *ExportOPMLResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ExportOPMLResponse.ProtoReflect.Descriptor instead. func (*ExportOPMLResponse) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{17} + return file_iris_proto_rawDescGZIP(), []int{19} } func (x *ExportOPMLResponse) GetPayload() []byte { @@ -1048,7 +1142,7 @@ type ImportOPMLRequest struct { func (x *ImportOPMLRequest) Reset() { *x = ImportOPMLRequest{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[18] + mi := &file_iris_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1061,7 +1155,7 @@ func (x *ImportOPMLRequest) String() string { func (*ImportOPMLRequest) ProtoMessage() {} func (x *ImportOPMLRequest) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[18] + mi := &file_iris_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1074,7 +1168,7 @@ func (x *ImportOPMLRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ImportOPMLRequest.ProtoReflect.Descriptor instead. func (*ImportOPMLRequest) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{18} + return file_iris_proto_rawDescGZIP(), []int{20} } func (x *ImportOPMLRequest) GetPayload() []byte { @@ -1096,7 +1190,7 @@ type ImportOPMLResponse struct { func (x *ImportOPMLResponse) Reset() { *x = ImportOPMLResponse{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[19] + mi := &file_iris_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1109,7 +1203,7 @@ func (x *ImportOPMLResponse) String() string { func (*ImportOPMLResponse) ProtoMessage() {} func (x *ImportOPMLResponse) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[19] + mi := &file_iris_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1122,7 +1216,7 @@ func (x *ImportOPMLResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ImportOPMLResponse.ProtoReflect.Descriptor instead. func (*ImportOPMLResponse) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{19} + return file_iris_proto_rawDescGZIP(), []int{21} } func (x *ImportOPMLResponse) GetNumProcessed() int32 { @@ -1148,7 +1242,7 @@ type GetInfoRequest struct { func (x *GetInfoRequest) Reset() { *x = GetInfoRequest{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[20] + mi := &file_iris_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1161,7 +1255,7 @@ func (x *GetInfoRequest) String() string { func (*GetInfoRequest) ProtoMessage() {} func (x *GetInfoRequest) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[20] + mi := &file_iris_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1174,7 +1268,7 @@ func (x *GetInfoRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetInfoRequest.ProtoReflect.Descriptor instead. func (*GetInfoRequest) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{20} + return file_iris_proto_rawDescGZIP(), []int{22} } type GetInfoResponse struct { @@ -1191,7 +1285,7 @@ type GetInfoResponse struct { func (x *GetInfoResponse) Reset() { *x = GetInfoResponse{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[21] + mi := &file_iris_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1204,7 +1298,7 @@ func (x *GetInfoResponse) String() string { func (*GetInfoResponse) ProtoMessage() {} func (x *GetInfoResponse) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[21] + mi := &file_iris_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1217,7 +1311,7 @@ func (x *GetInfoResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetInfoResponse.ProtoReflect.Descriptor instead. func (*GetInfoResponse) Descriptor() ([]byte, []int) { - return file_iris_proto_rawDescGZIP(), []int{21} + return file_iris_proto_rawDescGZIP(), []int{23} } func (x *GetInfoResponse) GetName() string { @@ -1260,7 +1354,7 @@ type EditFeedsRequest_Op struct { func (x *EditFeedsRequest_Op) Reset() { *x = EditFeedsRequest_Op{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[22] + mi := &file_iris_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1273,7 +1367,7 @@ func (x *EditFeedsRequest_Op) String() string { func (*EditFeedsRequest_Op) ProtoMessage() {} func (x *EditFeedsRequest_Op) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[22] + mi := &file_iris_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1320,7 +1414,7 @@ type EditFeedsRequest_Op_Fields struct { func (x *EditFeedsRequest_Op_Fields) Reset() { *x = EditFeedsRequest_Op_Fields{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[23] + mi := &file_iris_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1333,7 +1427,7 @@ func (x *EditFeedsRequest_Op_Fields) String() string { func (*EditFeedsRequest_Op_Fields) ProtoMessage() {} func (x *EditFeedsRequest_Op_Fields) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[23] + mi := &file_iris_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1389,7 +1483,7 @@ type EditEntriesRequest_Op struct { func (x *EditEntriesRequest_Op) Reset() { *x = EditEntriesRequest_Op{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[24] + mi := &file_iris_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1402,7 +1496,7 @@ func (x *EditEntriesRequest_Op) String() string { func (*EditEntriesRequest_Op) ProtoMessage() {} func (x *EditEntriesRequest_Op) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[24] + mi := &file_iris_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1443,7 +1537,7 @@ type EditEntriesRequest_Op_Fields struct { func (x *EditEntriesRequest_Op_Fields) Reset() { *x = EditEntriesRequest_Op_Fields{} if protoimpl.UnsafeEnabled { - mi := &file_iris_proto_msgTypes[25] + mi := &file_iris_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1456,7 +1550,7 @@ func (x *EditEntriesRequest_Op_Fields) String() string { func (*EditEntriesRequest_Op_Fields) ProtoMessage() {} func (x *EditEntriesRequest_Op_Fields) ProtoReflect() protoreflect.Message { - mi := &file_iris_proto_msgTypes[25] + mi := &file_iris_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1616,75 +1710,84 @@ var file_iris_proto_rawDesc = []byte{ 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x25, 0x0a, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, - 0x22, 0x38, 0x0a, 0x11, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x19, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x88, 0x01, 0x01, - 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x22, 0x2e, 0x0a, 0x12, 0x45, 0x78, - 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x22, 0x2d, 0x0a, 0x11, 0x49, 0x6d, - 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, - 0x18, 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x22, 0x5c, 0x0a, 0x12, 0x49, 0x6d, 0x70, - 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x23, 0x0a, 0x0d, 0x6e, 0x75, 0x6d, 0x5f, 0x70, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x6e, 0x75, 0x6d, 0x50, 0x72, 0x6f, 0x63, 0x65, - 0x73, 0x73, 0x65, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x75, 0x6d, 0x5f, 0x69, 0x6d, 0x70, 0x6f, - 0x72, 0x74, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x6e, 0x75, 0x6d, 0x49, - 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x22, 0x10, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x49, 0x6e, - 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x7d, 0x0a, 0x0f, 0x47, 0x65, 0x74, - 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, - 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x69, - 0x74, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x67, 0x69, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x75, 0x69, - 0x6c, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, - 0x75, 0x69, 0x6c, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x32, 0x94, 0x05, 0x0a, 0x04, 0x49, 0x72, 0x69, - 0x73, 0x12, 0x38, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, 0x64, 0x12, 0x14, 0x2e, 0x69, - 0x72, 0x69, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, - 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3e, 0x0a, 0x09, 0x45, - 0x64, 0x69, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, - 0x45, 0x64, 0x69, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x46, 0x65, 0x65, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3e, 0x0a, 0x09, 0x4c, - 0x69, 0x73, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, - 0x4c, 0x69, 0x73, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x65, 0x65, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x40, 0x0a, 0x09, 0x50, - 0x75, 0x6c, 0x6c, 0x46, 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, - 0x50, 0x75, 0x6c, 0x6c, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x50, 0x75, 0x6c, 0x6c, 0x46, 0x65, 0x65, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0x44, 0x0a, - 0x0b, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x46, 0x65, 0x65, 0x64, 0x73, 0x12, 0x18, 0x2e, 0x69, - 0x72, 0x69, 0x73, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x44, 0x65, - 0x6c, 0x65, 0x74, 0x65, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, - 0x65, 0x73, 0x12, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, - 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x69, - 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x0b, 0x45, 0x64, 0x69, - 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, - 0x45, 0x64, 0x69, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x45, 0x6e, - 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x41, 0x0a, 0x0a, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x12, 0x17, 0x2e, - 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x78, - 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x00, 0x12, 0x41, 0x0a, 0x0a, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, - 0x12, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, - 0x4d, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, - 0x2e, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x38, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, - 0x12, 0x14, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x47, 0x65, - 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, - 0x19, 0x5a, 0x17, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x6f, - 0x77, 0x2f, 0x69, 0x72, 0x69, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x33, + 0x22, 0x22, 0x0a, 0x10, 0x56, 0x69, 0x65, 0x77, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x02, 0x69, 0x64, 0x22, 0x36, 0x0a, 0x11, 0x56, 0x69, 0x65, 0x77, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x21, 0x0a, 0x05, 0x65, 0x6e, 0x74, + 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, + 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x65, 0x6e, 0x74, 0x72, 0x79, 0x22, 0x38, 0x0a, 0x11, + 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x19, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x48, 0x00, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x88, 0x01, 0x01, 0x42, 0x08, 0x0a, 0x06, + 0x5f, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x22, 0x2e, 0x0a, 0x12, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, + 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, + 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x22, 0x2d, 0x0a, 0x11, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, + 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x70, + 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 0x61, + 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x22, 0x5c, 0x0a, 0x12, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, + 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x6e, + 0x75, 0x6d, 0x5f, 0x70, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x05, 0x52, 0x0c, 0x6e, 0x75, 0x6d, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, + 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x75, 0x6d, 0x5f, 0x69, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x6e, 0x75, 0x6d, 0x49, 0x6d, 0x70, 0x6f, 0x72, + 0x74, 0x65, 0x64, 0x22, 0x10, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x7d, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, + 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, + 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x69, 0x74, 0x5f, 0x63, 0x6f, + 0x6d, 0x6d, 0x69, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x67, 0x69, 0x74, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x5f, 0x74, + 0x69, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x75, 0x69, 0x6c, 0x64, + 0x54, 0x69, 0x6d, 0x65, 0x32, 0xd4, 0x05, 0x0a, 0x04, 0x49, 0x72, 0x69, 0x73, 0x12, 0x38, 0x0a, + 0x07, 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, 0x64, 0x12, 0x14, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, + 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, + 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3e, 0x0a, 0x09, 0x45, 0x64, 0x69, 0x74, 0x46, + 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, + 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x69, + 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3e, 0x0a, 0x09, 0x4c, 0x69, 0x73, 0x74, 0x46, + 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, + 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x69, + 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x40, 0x0a, 0x09, 0x50, 0x75, 0x6c, 0x6c, 0x46, + 0x65, 0x65, 0x64, 0x73, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x50, 0x75, 0x6c, 0x6c, + 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x69, + 0x72, 0x69, 0x73, 0x2e, 0x50, 0x75, 0x6c, 0x6c, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x30, 0x01, 0x12, 0x44, 0x0a, 0x0b, 0x44, 0x65, 0x6c, + 0x65, 0x74, 0x65, 0x46, 0x65, 0x65, 0x64, 0x73, 0x12, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, + 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, + 0x46, 0x65, 0x65, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x44, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, 0x18, + 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, + 0x4c, 0x69, 0x73, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x0b, 0x45, 0x64, 0x69, 0x74, 0x45, 0x6e, 0x74, + 0x72, 0x69, 0x65, 0x73, 0x12, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, + 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, + 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x64, 0x69, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3e, 0x0a, 0x09, 0x56, + 0x69, 0x65, 0x77, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x16, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, + 0x56, 0x69, 0x65, 0x77, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x56, 0x69, 0x65, 0x77, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, 0x0a, 0x45, + 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x12, 0x17, 0x2e, 0x69, 0x72, 0x69, 0x73, + 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, + 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, + 0x0a, 0x0a, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x12, 0x17, 0x2e, 0x69, + 0x72, 0x69, 0x73, 0x2e, 0x49, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x49, 0x6d, 0x70, + 0x6f, 0x72, 0x74, 0x4f, 0x50, 0x4d, 0x4c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x00, 0x12, 0x38, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x2e, 0x69, + 0x72, 0x69, 0x73, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x69, 0x72, 0x69, 0x73, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, + 0x6f, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x19, 0x5a, 0x17, 0x67, + 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x62, 0x6f, 0x77, 0x2f, 0x69, 0x72, + 0x69, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1699,7 +1802,7 @@ func file_iris_proto_rawDescGZIP() []byte { return file_iris_proto_rawDescData } -var file_iris_proto_msgTypes = make([]protoimpl.MessageInfo, 26) +var file_iris_proto_msgTypes = make([]protoimpl.MessageInfo, 28) var file_iris_proto_goTypes = []interface{}{ (*Feed)(nil), // 0: iris.Feed (*Entry)(nil), // 1: iris.Entry @@ -1717,59 +1820,64 @@ var file_iris_proto_goTypes = []interface{}{ (*ListEntriesResponse)(nil), // 13: iris.ListEntriesResponse (*EditEntriesRequest)(nil), // 14: iris.EditEntriesRequest (*EditEntriesResponse)(nil), // 15: iris.EditEntriesResponse - (*ExportOPMLRequest)(nil), // 16: iris.ExportOPMLRequest - (*ExportOPMLResponse)(nil), // 17: iris.ExportOPMLResponse - (*ImportOPMLRequest)(nil), // 18: iris.ImportOPMLRequest - (*ImportOPMLResponse)(nil), // 19: iris.ImportOPMLResponse - (*GetInfoRequest)(nil), // 20: iris.GetInfoRequest - (*GetInfoResponse)(nil), // 21: iris.GetInfoResponse - (*EditFeedsRequest_Op)(nil), // 22: iris.EditFeedsRequest.Op - (*EditFeedsRequest_Op_Fields)(nil), // 23: iris.EditFeedsRequest.Op.Fields - (*EditEntriesRequest_Op)(nil), // 24: iris.EditEntriesRequest.Op - (*EditEntriesRequest_Op_Fields)(nil), // 25: iris.EditEntriesRequest.Op.Fields - (*timestamppb.Timestamp)(nil), // 26: google.protobuf.Timestamp + (*ViewEntryRequest)(nil), // 16: iris.ViewEntryRequest + (*ViewEntryResponse)(nil), // 17: iris.ViewEntryResponse + (*ExportOPMLRequest)(nil), // 18: iris.ExportOPMLRequest + (*ExportOPMLResponse)(nil), // 19: iris.ExportOPMLResponse + (*ImportOPMLRequest)(nil), // 20: iris.ImportOPMLRequest + (*ImportOPMLResponse)(nil), // 21: iris.ImportOPMLResponse + (*GetInfoRequest)(nil), // 22: iris.GetInfoRequest + (*GetInfoResponse)(nil), // 23: iris.GetInfoResponse + (*EditFeedsRequest_Op)(nil), // 24: iris.EditFeedsRequest.Op + (*EditFeedsRequest_Op_Fields)(nil), // 25: iris.EditFeedsRequest.Op.Fields + (*EditEntriesRequest_Op)(nil), // 26: iris.EditEntriesRequest.Op + (*EditEntriesRequest_Op_Fields)(nil), // 27: iris.EditEntriesRequest.Op.Fields + (*timestamppb.Timestamp)(nil), // 28: google.protobuf.Timestamp } var file_iris_proto_depIdxs = []int32{ - 26, // 0: iris.Feed.update_time:type_name -> google.protobuf.Timestamp - 26, // 1: iris.Feed.subscription_time:type_name -> google.protobuf.Timestamp + 28, // 0: iris.Feed.update_time:type_name -> google.protobuf.Timestamp + 28, // 1: iris.Feed.subscription_time:type_name -> google.protobuf.Timestamp 1, // 2: iris.Feed.entries:type_name -> iris.Entry - 26, // 3: iris.Entry.update_time:type_name -> google.protobuf.Timestamp - 26, // 4: iris.Entry.publication_time:type_name -> google.protobuf.Timestamp + 28, // 3: iris.Entry.update_time:type_name -> google.protobuf.Timestamp + 28, // 4: iris.Entry.publication_time:type_name -> google.protobuf.Timestamp 0, // 5: iris.AddFeedResponse.feed:type_name -> iris.Feed - 22, // 6: iris.EditFeedsRequest.ops:type_name -> iris.EditFeedsRequest.Op + 24, // 6: iris.EditFeedsRequest.ops:type_name -> iris.EditFeedsRequest.Op 0, // 7: iris.EditFeedsResponse.feeds:type_name -> iris.Feed 0, // 8: iris.ListFeedsResponse.feeds:type_name -> iris.Feed 0, // 9: iris.PullFeedsResponse.feed:type_name -> iris.Feed 1, // 10: iris.ListEntriesResponse.entries:type_name -> iris.Entry - 24, // 11: iris.EditEntriesRequest.ops:type_name -> iris.EditEntriesRequest.Op + 26, // 11: iris.EditEntriesRequest.ops:type_name -> iris.EditEntriesRequest.Op 1, // 12: iris.EditEntriesResponse.entries:type_name -> iris.Entry - 23, // 13: iris.EditFeedsRequest.Op.fields:type_name -> iris.EditFeedsRequest.Op.Fields - 25, // 14: iris.EditEntriesRequest.Op.fields:type_name -> iris.EditEntriesRequest.Op.Fields - 2, // 15: iris.Iris.AddFeed:input_type -> iris.AddFeedRequest - 4, // 16: iris.Iris.EditFeeds:input_type -> iris.EditFeedsRequest - 6, // 17: iris.Iris.ListFeeds:input_type -> iris.ListFeedsRequest - 8, // 18: iris.Iris.PullFeeds:input_type -> iris.PullFeedsRequest - 10, // 19: iris.Iris.DeleteFeeds:input_type -> iris.DeleteFeedsRequest - 12, // 20: iris.Iris.ListEntries:input_type -> iris.ListEntriesRequest - 14, // 21: iris.Iris.EditEntries:input_type -> iris.EditEntriesRequest - 16, // 22: iris.Iris.ExportOPML:input_type -> iris.ExportOPMLRequest - 18, // 23: iris.Iris.ImportOPML:input_type -> iris.ImportOPMLRequest - 20, // 24: iris.Iris.GetInfo:input_type -> iris.GetInfoRequest - 3, // 25: iris.Iris.AddFeed:output_type -> iris.AddFeedResponse - 5, // 26: iris.Iris.EditFeeds:output_type -> iris.EditFeedsResponse - 7, // 27: iris.Iris.ListFeeds:output_type -> iris.ListFeedsResponse - 9, // 28: iris.Iris.PullFeeds:output_type -> iris.PullFeedsResponse - 11, // 29: iris.Iris.DeleteFeeds:output_type -> iris.DeleteFeedsResponse - 13, // 30: iris.Iris.ListEntries:output_type -> iris.ListEntriesResponse - 15, // 31: iris.Iris.EditEntries:output_type -> iris.EditEntriesResponse - 17, // 32: iris.Iris.ExportOPML:output_type -> iris.ExportOPMLResponse - 19, // 33: iris.Iris.ImportOPML:output_type -> iris.ImportOPMLResponse - 21, // 34: iris.Iris.GetInfo:output_type -> iris.GetInfoResponse - 25, // [25:35] is the sub-list for method output_type - 15, // [15:25] is the sub-list for method input_type - 15, // [15:15] is the sub-list for extension type_name - 15, // [15:15] is the sub-list for extension extendee - 0, // [0:15] is the sub-list for field type_name + 1, // 13: iris.ViewEntryResponse.entry:type_name -> iris.Entry + 25, // 14: iris.EditFeedsRequest.Op.fields:type_name -> iris.EditFeedsRequest.Op.Fields + 27, // 15: iris.EditEntriesRequest.Op.fields:type_name -> iris.EditEntriesRequest.Op.Fields + 2, // 16: iris.Iris.AddFeed:input_type -> iris.AddFeedRequest + 4, // 17: iris.Iris.EditFeeds:input_type -> iris.EditFeedsRequest + 6, // 18: iris.Iris.ListFeeds:input_type -> iris.ListFeedsRequest + 8, // 19: iris.Iris.PullFeeds:input_type -> iris.PullFeedsRequest + 10, // 20: iris.Iris.DeleteFeeds:input_type -> iris.DeleteFeedsRequest + 12, // 21: iris.Iris.ListEntries:input_type -> iris.ListEntriesRequest + 14, // 22: iris.Iris.EditEntries:input_type -> iris.EditEntriesRequest + 16, // 23: iris.Iris.ViewEntry:input_type -> iris.ViewEntryRequest + 18, // 24: iris.Iris.ExportOPML:input_type -> iris.ExportOPMLRequest + 20, // 25: iris.Iris.ImportOPML:input_type -> iris.ImportOPMLRequest + 22, // 26: iris.Iris.GetInfo:input_type -> iris.GetInfoRequest + 3, // 27: iris.Iris.AddFeed:output_type -> iris.AddFeedResponse + 5, // 28: iris.Iris.EditFeeds:output_type -> iris.EditFeedsResponse + 7, // 29: iris.Iris.ListFeeds:output_type -> iris.ListFeedsResponse + 9, // 30: iris.Iris.PullFeeds:output_type -> iris.PullFeedsResponse + 11, // 31: iris.Iris.DeleteFeeds:output_type -> iris.DeleteFeedsResponse + 13, // 32: iris.Iris.ListEntries:output_type -> iris.ListEntriesResponse + 15, // 33: iris.Iris.EditEntries:output_type -> iris.EditEntriesResponse + 17, // 34: iris.Iris.ViewEntry:output_type -> iris.ViewEntryResponse + 19, // 35: iris.Iris.ExportOPML:output_type -> iris.ExportOPMLResponse + 21, // 36: iris.Iris.ImportOPML:output_type -> iris.ImportOPMLResponse + 23, // 37: iris.Iris.GetInfo:output_type -> iris.GetInfoResponse + 27, // [27:38] is the sub-list for method output_type + 16, // [16:27] is the sub-list for method input_type + 16, // [16:16] is the sub-list for extension type_name + 16, // [16:16] is the sub-list for extension extendee + 0, // [0:16] is the sub-list for field type_name } func init() { file_iris_proto_init() } @@ -1971,7 +2079,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ExportOPMLRequest); i { + switch v := v.(*ViewEntryRequest); i { case 0: return &v.state case 1: @@ -1983,7 +2091,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ExportOPMLResponse); i { + switch v := v.(*ViewEntryResponse); i { case 0: return &v.state case 1: @@ -1995,7 +2103,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ImportOPMLRequest); i { + switch v := v.(*ExportOPMLRequest); i { case 0: return &v.state case 1: @@ -2007,7 +2115,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ImportOPMLResponse); i { + switch v := v.(*ExportOPMLResponse); i { case 0: return &v.state case 1: @@ -2019,7 +2127,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetInfoRequest); i { + switch v := v.(*ImportOPMLRequest); i { case 0: return &v.state case 1: @@ -2031,7 +2139,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetInfoResponse); i { + switch v := v.(*ImportOPMLResponse); i { case 0: return &v.state case 1: @@ -2043,7 +2151,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*EditFeedsRequest_Op); i { + switch v := v.(*GetInfoRequest); i { case 0: return &v.state case 1: @@ -2055,7 +2163,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*EditFeedsRequest_Op_Fields); i { + switch v := v.(*GetInfoResponse); i { case 0: return &v.state case 1: @@ -2067,7 +2175,7 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*EditEntriesRequest_Op); i { + switch v := v.(*EditFeedsRequest_Op); i { case 0: return &v.state case 1: @@ -2079,6 +2187,30 @@ func file_iris_proto_init() { } } file_iris_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*EditFeedsRequest_Op_Fields); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_iris_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*EditEntriesRequest_Op); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_iris_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*EditEntriesRequest_Op_Fields); i { case 0: return &v.state @@ -2095,16 +2227,16 @@ func file_iris_proto_init() { file_iris_proto_msgTypes[1].OneofWrappers = []interface{}{} file_iris_proto_msgTypes[2].OneofWrappers = []interface{}{} file_iris_proto_msgTypes[9].OneofWrappers = []interface{}{} - file_iris_proto_msgTypes[16].OneofWrappers = []interface{}{} - file_iris_proto_msgTypes[23].OneofWrappers = []interface{}{} + file_iris_proto_msgTypes[18].OneofWrappers = []interface{}{} file_iris_proto_msgTypes[25].OneofWrappers = []interface{}{} + file_iris_proto_msgTypes[27].OneofWrappers = []interface{}{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_iris_proto_rawDesc, NumEnums: 0, - NumMessages: 26, + NumMessages: 28, NumExtensions: 0, NumServices: 1, }, diff --git a/api/iris.proto b/api/iris.proto index 03a3dce..4a4e7a5 100644 --- a/api/iris.proto +++ b/api/iris.proto @@ -33,6 +33,9 @@ service Iris { // EditEntries sets one or more fields of an entry. rpc EditEntries (EditEntriesRequest) returns (EditEntriesResponse) {} + // ViewEntry returns the content of an entry. + rpc ViewEntry (ViewEntryRequest) returns (ViewEntryResponse) {} + // ExportOPML exports feed subscriptions as an OPML document. rpc ExportOPML (ExportOPMLRequest) returns (ExportOPMLResponse) {} @@ -148,6 +151,14 @@ message EditEntriesResponse { repeated Entry entries = 1; } +message ViewEntryRequest { + int32 id = 1; +} + +message ViewEntryResponse { + Entry entry = 1; +} + message ExportOPMLRequest { optional string title = 1; } diff --git a/api/iris_grpc.pb.go b/api/iris_grpc.pb.go index 42b2c05..6084aac 100644 --- a/api/iris_grpc.pb.go +++ b/api/iris_grpc.pb.go @@ -31,6 +31,7 @@ const ( Iris_DeleteFeeds_FullMethodName = "/iris.Iris/DeleteFeeds" Iris_ListEntries_FullMethodName = "/iris.Iris/ListEntries" Iris_EditEntries_FullMethodName = "/iris.Iris/EditEntries" + Iris_ViewEntry_FullMethodName = "/iris.Iris/ViewEntry" Iris_ExportOPML_FullMethodName = "/iris.Iris/ExportOPML" Iris_ImportOPML_FullMethodName = "/iris.Iris/ImportOPML" Iris_GetInfo_FullMethodName = "/iris.Iris/GetInfo" @@ -54,6 +55,8 @@ type IrisClient interface { ListEntries(ctx context.Context, in *ListEntriesRequest, opts ...grpc.CallOption) (*ListEntriesResponse, error) // EditEntries sets one or more fields of an entry. EditEntries(ctx context.Context, in *EditEntriesRequest, opts ...grpc.CallOption) (*EditEntriesResponse, error) + // ViewEntry returns the content of an entry. + ViewEntry(ctx context.Context, in *ViewEntryRequest, opts ...grpc.CallOption) (*ViewEntryResponse, error) // ExportOPML exports feed subscriptions as an OPML document. ExportOPML(ctx context.Context, in *ExportOPMLRequest, opts ...grpc.CallOption) (*ExportOPMLResponse, error) // ImportOPML imports an OPML document. @@ -156,6 +159,15 @@ func (c *irisClient) EditEntries(ctx context.Context, in *EditEntriesRequest, op return out, nil } +func (c *irisClient) ViewEntry(ctx context.Context, in *ViewEntryRequest, opts ...grpc.CallOption) (*ViewEntryResponse, error) { + out := new(ViewEntryResponse) + err := c.cc.Invoke(ctx, Iris_ViewEntry_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *irisClient) ExportOPML(ctx context.Context, in *ExportOPMLRequest, opts ...grpc.CallOption) (*ExportOPMLResponse, error) { out := new(ExportOPMLResponse) err := c.cc.Invoke(ctx, Iris_ExportOPML_FullMethodName, in, out, opts...) @@ -201,6 +213,8 @@ type IrisServer interface { ListEntries(context.Context, *ListEntriesRequest) (*ListEntriesResponse, error) // EditEntries sets one or more fields of an entry. EditEntries(context.Context, *EditEntriesRequest) (*EditEntriesResponse, error) + // ViewEntry returns the content of an entry. + ViewEntry(context.Context, *ViewEntryRequest) (*ViewEntryResponse, error) // ExportOPML exports feed subscriptions as an OPML document. ExportOPML(context.Context, *ExportOPMLRequest) (*ExportOPMLResponse, error) // ImportOPML imports an OPML document. @@ -235,6 +249,9 @@ func (UnimplementedIrisServer) ListEntries(context.Context, *ListEntriesRequest) func (UnimplementedIrisServer) EditEntries(context.Context, *EditEntriesRequest) (*EditEntriesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method EditEntries not implemented") } +func (UnimplementedIrisServer) ViewEntry(context.Context, *ViewEntryRequest) (*ViewEntryResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ViewEntry not implemented") +} func (UnimplementedIrisServer) ExportOPML(context.Context, *ExportOPMLRequest) (*ExportOPMLResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ExportOPML not implemented") } @@ -386,6 +403,24 @@ func _Iris_EditEntries_Handler(srv interface{}, ctx context.Context, dec func(in return interceptor(ctx, in, info, handler) } +func _Iris_ViewEntry_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ViewEntryRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(IrisServer).ViewEntry(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: Iris_ViewEntry_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(IrisServer).ViewEntry(ctx, req.(*ViewEntryRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _Iris_ExportOPML_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ExportOPMLRequest) if err := dec(in); err != nil { @@ -471,6 +506,10 @@ var Iris_ServiceDesc = grpc.ServiceDesc{ MethodName: "EditEntries", Handler: _Iris_EditEntries_Handler, }, + { + MethodName: "ViewEntry", + Handler: _Iris_ViewEntry_Handler, + }, { MethodName: "ExportOPML", Handler: _Iris_ExportOPML_Handler, diff --git a/internal/server/service.go b/internal/server/service.go index d5dc7a4..c23b7e5 100644 --- a/internal/server/service.go +++ b/internal/server/service.go @@ -216,6 +216,14 @@ func (svc *service) EditEntries( return &rsp, nil } +// ViewEntry satisfies the service API. +func (svc *service) ViewEntry( + ctx context.Context, + _ *api.ViewEntryRequest, +) (*api.ViewEntryResponse, error) { + return nil, status.Error(codes.Unimplemented, "unimplemented") +} + // ExportOPML satisfies the service API. func (svc *service) ExportOPML( ctx context.Context, diff --git a/internal/server/service_test.go b/internal/server/service_test.go index e6d469f..fcd56b7 100644 --- a/internal/server/service_test.go +++ b/internal/server/service_test.go @@ -551,6 +551,22 @@ func TestEditEntriesOk(t *testing.T) { a.Equal(entries[1].IsRead, entry1.IsRead) } +func TestViewEntryOk(t *testing.T) { + t.Parallel() + + r := require.New(t) + a := assert.New(t) + + client, _ := setupServerTest(t) + + req := api.ViewEntryRequest{} + rsp, err := client.ViewEntry(context.Background(), &req) + + r.EqualError(err, "rpc error: code = Unimplemented desc = unimplemented") + + a.Nil(rsp) +} + func TestExportOPMLOk(t *testing.T) { t.Parallel()