diff --git a/services/common/genproto/modules/feeds.pb.go b/services/common/genproto/modules/feeds.pb.go new file mode 100644 index 0000000..97aaa32 --- /dev/null +++ b/services/common/genproto/modules/feeds.pb.go @@ -0,0 +1,312 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.1 +// protoc v5.27.1 +// source: feeds.proto + +package modules + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type Feed struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + Modules string `protobuf:"bytes,2,opt,name=modules,proto3" json:"modules,omitempty"` + Retrieved string `protobuf:"bytes,3,opt,name=retrieved,proto3" json:"retrieved,omitempty"` + Created string `protobuf:"bytes,4,opt,name=created,proto3" json:"created,omitempty"` + Updated string `protobuf:"bytes,5,opt,name=updated,proto3" json:"updated,omitempty"` +} + +func (x *Feed) Reset() { + *x = Feed{} + if protoimpl.UnsafeEnabled { + mi := &file_feeds_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Feed) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Feed) ProtoMessage() {} + +func (x *Feed) ProtoReflect() protoreflect.Message { + mi := &file_feeds_proto_msgTypes[0] + 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 Feed.ProtoReflect.Descriptor instead. +func (*Feed) Descriptor() ([]byte, []int) { + return file_feeds_proto_rawDescGZIP(), []int{0} +} + +func (x *Feed) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +func (x *Feed) GetModules() string { + if x != nil { + return x.Modules + } + return "" +} + +func (x *Feed) GetRetrieved() string { + if x != nil { + return x.Retrieved + } + return "" +} + +func (x *Feed) GetCreated() string { + if x != nil { + return x.Created + } + return "" +} + +func (x *Feed) GetUpdated() string { + if x != nil { + return x.Updated + } + return "" +} + +type GetFeedRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *GetFeedRequest) Reset() { + *x = GetFeedRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_feeds_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetFeedRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetFeedRequest) ProtoMessage() {} + +func (x *GetFeedRequest) ProtoReflect() protoreflect.Message { + mi := &file_feeds_proto_msgTypes[1] + 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 GetFeedRequest.ProtoReflect.Descriptor instead. +func (*GetFeedRequest) Descriptor() ([]byte, []int) { + return file_feeds_proto_rawDescGZIP(), []int{1} +} + +func (x *GetFeedRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type GetFeedResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Feed *Feed `protobuf:"bytes,1,opt,name=feed,proto3" json:"feed,omitempty"` +} + +func (x *GetFeedResponse) Reset() { + *x = GetFeedResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_feeds_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetFeedResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetFeedResponse) ProtoMessage() {} + +func (x *GetFeedResponse) ProtoReflect() protoreflect.Message { + mi := &file_feeds_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use GetFeedResponse.ProtoReflect.Descriptor instead. +func (*GetFeedResponse) Descriptor() ([]byte, []int) { + return file_feeds_proto_rawDescGZIP(), []int{2} +} + +func (x *GetFeedResponse) GetFeed() *Feed { + if x != nil { + return x.Feed + } + return nil +} + +var File_feeds_proto protoreflect.FileDescriptor + +var file_feeds_proto_rawDesc = []byte{ + 0x0a, 0x0b, 0x66, 0x65, 0x65, 0x64, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x82, 0x01, + 0x0a, 0x04, 0x46, 0x65, 0x65, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, + 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, + 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, 0x74, 0x72, 0x69, 0x65, 0x76, 0x65, 0x64, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, 0x65, 0x74, 0x72, 0x69, 0x65, 0x76, 0x65, 0x64, 0x12, 0x18, + 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x75, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x64, 0x22, 0x20, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x02, 0x69, 0x64, 0x22, 0x2c, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x46, 0x65, 0x65, 0x64, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x19, 0x0a, 0x04, 0x66, 0x65, 0x65, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x05, 0x2e, 0x46, 0x65, 0x65, 0x64, 0x52, 0x04, 0x66, 0x65, + 0x65, 0x64, 0x32, 0x3d, 0x0a, 0x0b, 0x46, 0x65, 0x65, 0x64, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x46, 0x65, 0x65, 0x64, 0x12, 0x0f, 0x2e, 0x47, + 0x65, 0x74, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, + 0x47, 0x65, 0x74, 0x46, 0x65, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x00, 0x42, 0x1c, 0x5a, 0x1a, 0x68, 0x74, 0x77, 0x6b, 0x61, 0x6c, 0x65, 0x6e, 0x64, 0x65, 0x72, + 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_feeds_proto_rawDescOnce sync.Once + file_feeds_proto_rawDescData = file_feeds_proto_rawDesc +) + +func file_feeds_proto_rawDescGZIP() []byte { + file_feeds_proto_rawDescOnce.Do(func() { + file_feeds_proto_rawDescData = protoimpl.X.CompressGZIP(file_feeds_proto_rawDescData) + }) + return file_feeds_proto_rawDescData +} + +var file_feeds_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_feeds_proto_goTypes = []interface{}{ + (*Feed)(nil), // 0: Feed + (*GetFeedRequest)(nil), // 1: GetFeedRequest + (*GetFeedResponse)(nil), // 2: GetFeedResponse +} +var file_feeds_proto_depIdxs = []int32{ + 0, // 0: GetFeedResponse.feed:type_name -> Feed + 1, // 1: FeedService.GetFeed:input_type -> GetFeedRequest + 2, // 2: FeedService.GetFeed:output_type -> GetFeedResponse + 2, // [2:3] is the sub-list for method output_type + 1, // [1:2] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_feeds_proto_init() } +func file_feeds_proto_init() { + if File_feeds_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_feeds_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Feed); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_feeds_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetFeedRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_feeds_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetFeedResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_feeds_proto_rawDesc, + NumEnums: 0, + NumMessages: 3, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_feeds_proto_goTypes, + DependencyIndexes: file_feeds_proto_depIdxs, + MessageInfos: file_feeds_proto_msgTypes, + }.Build() + File_feeds_proto = out.File + file_feeds_proto_rawDesc = nil + file_feeds_proto_goTypes = nil + file_feeds_proto_depIdxs = nil +} diff --git a/services/common/genproto/modules/feeds_grpc.pb.go b/services/common/genproto/modules/feeds_grpc.pb.go new file mode 100644 index 0000000..10d1fc2 --- /dev/null +++ b/services/common/genproto/modules/feeds_grpc.pb.go @@ -0,0 +1,105 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.2.0 +// - protoc v5.27.1 +// source: feeds.proto + +package modules + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +// FeedServiceClient is the client API for FeedService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type FeedServiceClient interface { + GetFeed(ctx context.Context, in *GetFeedRequest, opts ...grpc.CallOption) (*GetFeedResponse, error) +} + +type feedServiceClient struct { + cc grpc.ClientConnInterface +} + +func NewFeedServiceClient(cc grpc.ClientConnInterface) FeedServiceClient { + return &feedServiceClient{cc} +} + +func (c *feedServiceClient) GetFeed(ctx context.Context, in *GetFeedRequest, opts ...grpc.CallOption) (*GetFeedResponse, error) { + out := new(GetFeedResponse) + err := c.cc.Invoke(ctx, "/FeedService/GetFeed", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// FeedServiceServer is the server API for FeedService service. +// All implementations must embed UnimplementedFeedServiceServer +// for forward compatibility +type FeedServiceServer interface { + GetFeed(context.Context, *GetFeedRequest) (*GetFeedResponse, error) + mustEmbedUnimplementedFeedServiceServer() +} + +// UnimplementedFeedServiceServer must be embedded to have forward compatible implementations. +type UnimplementedFeedServiceServer struct { +} + +func (UnimplementedFeedServiceServer) GetFeed(context.Context, *GetFeedRequest) (*GetFeedResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetFeed not implemented") +} +func (UnimplementedFeedServiceServer) mustEmbedUnimplementedFeedServiceServer() {} + +// UnsafeFeedServiceServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to FeedServiceServer will +// result in compilation errors. +type UnsafeFeedServiceServer interface { + mustEmbedUnimplementedFeedServiceServer() +} + +func RegisterFeedServiceServer(s grpc.ServiceRegistrar, srv FeedServiceServer) { + s.RegisterService(&FeedService_ServiceDesc, srv) +} + +func _FeedService_GetFeed_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetFeedRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(FeedServiceServer).GetFeed(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/FeedService/GetFeed", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(FeedServiceServer).GetFeed(ctx, req.(*GetFeedRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// FeedService_ServiceDesc is the grpc.ServiceDesc for FeedService service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var FeedService_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "FeedService", + HandlerType: (*FeedServiceServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "GetFeed", + Handler: _FeedService_GetFeed_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "feeds.proto", +}