✨ List related relatives
This commit is contained in:
		| @@ -600,7 +600,8 @@ type ListUserRelativeRequest struct { | ||||
| 	sizeCache     protoimpl.SizeCache | ||||
| 	unknownFields protoimpl.UnknownFields | ||||
|  | ||||
| 	UserId uint64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` | ||||
| 	UserId    uint64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` | ||||
| 	IsRelated bool   `protobuf:"varint,2,opt,name=is_related,json=isRelated,proto3" json:"is_related,omitempty"` | ||||
| } | ||||
|  | ||||
| func (x *ListUserRelativeRequest) Reset() { | ||||
| @@ -642,6 +643,13 @@ func (x *ListUserRelativeRequest) GetUserId() uint64 { | ||||
| 	return 0 | ||||
| } | ||||
|  | ||||
| func (x *ListUserRelativeRequest) GetIsRelated() bool { | ||||
| 	if x != nil { | ||||
| 		return x.IsRelated | ||||
| 	} | ||||
| 	return false | ||||
| } | ||||
|  | ||||
| type ListUserRelativeResponse struct { | ||||
| 	state         protoimpl.MessageState | ||||
| 	sizeCache     protoimpl.SizeCache | ||||
| @@ -756,41 +764,43 @@ var file_auth_proto_rawDesc = []byte{ | ||||
| 	0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, | ||||
| 	0x28, 0x04, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, | ||||
| 	0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x69, | ||||
| 	0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x69, 0x63, 0x6b, 0x22, 0x32, | ||||
| 	0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x69, 0x63, 0x6b, 0x22, 0x51, | ||||
| 	0x0a, 0x17, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x69, | ||||
| 	0x76, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x17, 0x0a, 0x07, 0x75, 0x73, 0x65, | ||||
| 	0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, | ||||
| 	0x49, 0x64, 0x22, 0x45, 0x0a, 0x18, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, | ||||
| 	0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x29, | ||||
| 	0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x70, | ||||
| 	0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x53, 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, | ||||
| 	0x6e, 0x66, 0x6f, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x32, 0x8c, 0x03, 0x0a, 0x04, 0x41, 0x75, | ||||
| 	0x74, 0x68, 0x12, 0x36, 0x0a, 0x0c, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, | ||||
| 	0x74, 0x65, 0x12, 0x12, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x52, | ||||
| 	0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x41, | ||||
| 	0x75, 0x74, 0x68, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x00, 0x12, 0x48, 0x0a, 0x11, 0x45, 0x6e, | ||||
| 	0x73, 0x75, 0x72, 0x65, 0x50, 0x65, 0x72, 0x6d, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, | ||||
| 	0x17, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x65, 0x72, | ||||
| 	0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, | ||||
| 	0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x65, 0x72, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, | ||||
| 	0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x15, 0x45, 0x6e, 0x73, 0x75, 0x72, 0x65, 0x55, 0x73, | ||||
| 	0x65, 0x72, 0x50, 0x65, 0x72, 0x6d, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, 0x1b, 0x2e, | ||||
| 	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x55, 0x73, 0x65, 0x72, 0x50, | ||||
| 	0x65, 0x72, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x70, 0x72, 0x6f, | ||||
| 	0x74, 0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x55, 0x73, 0x65, 0x72, 0x50, 0x65, 0x72, 0x6d, | ||||
| 	0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0f, 0x4c, 0x69, | ||||
| 	0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x46, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x73, 0x12, 0x1e, 0x2e, | ||||
| 	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, | ||||
| 	0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, | ||||
| 	0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, | ||||
| 	0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, | ||||
| 	0x12, 0x56, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6c, 0x6f, 0x63, | ||||
| 	0x6b, 0x6c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, | ||||
| 	0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, | ||||
| 	0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, | ||||
| 	0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, | ||||
| 	0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x09, 0x5a, 0x07, 0x2e, 0x3b, 0x70, 0x72, | ||||
| 	0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, | ||||
| 	0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x72, 0x65, 0x6c, 0x61, 0x74, 0x65, 0x64, | ||||
| 	0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x65, | ||||
| 	0x64, 0x22, 0x45, 0x0a, 0x18, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, | ||||
| 	0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x29, 0x0a, | ||||
| 	0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x70, 0x72, | ||||
| 	0x6f, 0x74, 0x6f, 0x2e, 0x53, 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, | ||||
| 	0x66, 0x6f, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x32, 0x8c, 0x03, 0x0a, 0x04, 0x41, 0x75, 0x74, | ||||
| 	0x68, 0x12, 0x36, 0x0a, 0x0c, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, | ||||
| 	0x65, 0x12, 0x12, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x52, 0x65, | ||||
| 	0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x41, 0x75, | ||||
| 	0x74, 0x68, 0x52, 0x65, 0x70, 0x6c, 0x79, 0x22, 0x00, 0x12, 0x48, 0x0a, 0x11, 0x45, 0x6e, 0x73, | ||||
| 	0x75, 0x72, 0x65, 0x50, 0x65, 0x72, 0x6d, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, 0x17, | ||||
| 	0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x65, 0x72, 0x6d, | ||||
| 	0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, | ||||
| 	0x43, 0x68, 0x65, 0x63, 0x6b, 0x50, 0x65, 0x72, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, | ||||
| 	0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x15, 0x45, 0x6e, 0x73, 0x75, 0x72, 0x65, 0x55, 0x73, 0x65, | ||||
| 	0x72, 0x50, 0x65, 0x72, 0x6d, 0x47, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, 0x1b, 0x2e, 0x70, | ||||
| 	0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x55, 0x73, 0x65, 0x72, 0x50, 0x65, | ||||
| 	0x72, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x70, 0x72, 0x6f, 0x74, | ||||
| 	0x6f, 0x2e, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x55, 0x73, 0x65, 0x72, 0x50, 0x65, 0x72, 0x6d, 0x52, | ||||
| 	0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0f, 0x4c, 0x69, 0x73, | ||||
| 	0x74, 0x55, 0x73, 0x65, 0x72, 0x46, 0x72, 0x69, 0x65, 0x6e, 0x64, 0x73, 0x12, 0x1e, 0x2e, 0x70, | ||||
| 	0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, | ||||
| 	0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x70, | ||||
| 	0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, | ||||
| 	0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, | ||||
| 	0x56, 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6c, 0x6f, 0x63, 0x6b, | ||||
| 	0x6c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, | ||||
| 	0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x71, | ||||
| 	0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x4c, 0x69, 0x73, | ||||
| 	0x74, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x73, | ||||
| 	0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x09, 0x5a, 0x07, 0x2e, 0x3b, 0x70, 0x72, 0x6f, | ||||
| 	0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, | ||||
| } | ||||
|  | ||||
| var ( | ||||
|   | ||||
| @@ -69,6 +69,7 @@ message SimpleUserInfo { | ||||
|  | ||||
| message ListUserRelativeRequest { | ||||
|     uint64 user_id = 1; | ||||
|     bool is_related = 2; | ||||
| } | ||||
|  | ||||
| message ListUserRelativeResponse { | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: auth.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	Auth_Authenticate_FullMethodName          = "/proto.Auth/Authenticate" | ||||
| @@ -97,7 +97,7 @@ func (c *authClient) ListUserBlocklist(ctx context.Context, in *ListUserRelative | ||||
|  | ||||
| // AuthServer is the server API for Auth service. | ||||
| // All implementations must embed UnimplementedAuthServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type AuthServer interface { | ||||
| 	Authenticate(context.Context, *AuthRequest) (*AuthReply, error) | ||||
| 	EnsurePermGranted(context.Context, *CheckPermRequest) (*CheckPermResponse, error) | ||||
| @@ -107,9 +107,12 @@ type AuthServer interface { | ||||
| 	mustEmbedUnimplementedAuthServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedAuthServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedAuthServer struct { | ||||
| } | ||||
| // UnimplementedAuthServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedAuthServer struct{} | ||||
|  | ||||
| func (UnimplementedAuthServer) Authenticate(context.Context, *AuthRequest) (*AuthReply, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method Authenticate not implemented") | ||||
| @@ -127,6 +130,7 @@ func (UnimplementedAuthServer) ListUserBlocklist(context.Context, *ListUserRelat | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method ListUserBlocklist not implemented") | ||||
| } | ||||
| func (UnimplementedAuthServer) mustEmbedUnimplementedAuthServer() {} | ||||
| func (UnimplementedAuthServer) testEmbeddedByValue()              {} | ||||
|  | ||||
| // UnsafeAuthServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to AuthServer will | ||||
| @@ -136,6 +140,13 @@ type UnsafeAuthServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedAuthServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&Auth_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: notify.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	Notifier_NotifyUser_FullMethodName      = "/proto.Notifier/NotifyUser" | ||||
| @@ -73,7 +73,7 @@ func (c *notifierClient) NotifyAllUser(ctx context.Context, in *NotifyRequest, o | ||||
|  | ||||
| // NotifierServer is the server API for Notifier service. | ||||
| // All implementations must embed UnimplementedNotifierServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type NotifierServer interface { | ||||
| 	NotifyUser(context.Context, *NotifyUserRequest) (*NotifyResponse, error) | ||||
| 	NotifyUserBatch(context.Context, *NotifyUserBatchRequest) (*NotifyResponse, error) | ||||
| @@ -81,9 +81,12 @@ type NotifierServer interface { | ||||
| 	mustEmbedUnimplementedNotifierServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedNotifierServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedNotifierServer struct { | ||||
| } | ||||
| // UnimplementedNotifierServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedNotifierServer struct{} | ||||
|  | ||||
| func (UnimplementedNotifierServer) NotifyUser(context.Context, *NotifyUserRequest) (*NotifyResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method NotifyUser not implemented") | ||||
| @@ -95,6 +98,7 @@ func (UnimplementedNotifierServer) NotifyAllUser(context.Context, *NotifyRequest | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method NotifyAllUser not implemented") | ||||
| } | ||||
| func (UnimplementedNotifierServer) mustEmbedUnimplementedNotifierServer() {} | ||||
| func (UnimplementedNotifierServer) testEmbeddedByValue()                  {} | ||||
|  | ||||
| // UnsafeNotifierServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to NotifierServer will | ||||
| @@ -104,6 +108,13 @@ type UnsafeNotifierServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterNotifierServer(s grpc.ServiceRegistrar, srv NotifierServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedNotifierServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&Notifier_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: postman.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	Postman_DeliverNotification_FullMethodName      = "/proto.Postman/DeliverNotification" | ||||
| @@ -85,7 +85,7 @@ func (c *postmanClient) DeliverEmailBatch(ctx context.Context, in *DeliverEmailB | ||||
|  | ||||
| // PostmanServer is the server API for Postman service. | ||||
| // All implementations must embed UnimplementedPostmanServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type PostmanServer interface { | ||||
| 	DeliverNotification(context.Context, *DeliverNotificationRequest) (*DeliverResponse, error) | ||||
| 	DeliverNotificationBatch(context.Context, *DeliverNotificationBatchRequest) (*DeliverResponse, error) | ||||
| @@ -94,9 +94,12 @@ type PostmanServer interface { | ||||
| 	mustEmbedUnimplementedPostmanServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedPostmanServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedPostmanServer struct { | ||||
| } | ||||
| // UnimplementedPostmanServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedPostmanServer struct{} | ||||
|  | ||||
| func (UnimplementedPostmanServer) DeliverNotification(context.Context, *DeliverNotificationRequest) (*DeliverResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method DeliverNotification not implemented") | ||||
| @@ -111,6 +114,7 @@ func (UnimplementedPostmanServer) DeliverEmailBatch(context.Context, *DeliverEma | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method DeliverEmailBatch not implemented") | ||||
| } | ||||
| func (UnimplementedPostmanServer) mustEmbedUnimplementedPostmanServer() {} | ||||
| func (UnimplementedPostmanServer) testEmbeddedByValue()                 {} | ||||
|  | ||||
| // UnsafePostmanServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to PostmanServer will | ||||
| @@ -120,6 +124,13 @@ type UnsafePostmanServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterPostmanServer(s grpc.ServiceRegistrar, srv PostmanServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedPostmanServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&Postman_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: realm.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	Realm_ListCommunityRealm_FullMethodName   = "/proto.Realm/ListCommunityRealm" | ||||
| @@ -121,7 +121,7 @@ func (c *realmClient) CheckRealmMemberPerm(ctx context.Context, in *CheckRealmPe | ||||
|  | ||||
| // RealmServer is the server API for Realm service. | ||||
| // All implementations must embed UnimplementedRealmServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type RealmServer interface { | ||||
| 	ListCommunityRealm(context.Context, *ListRealmRequest) (*ListRealmResponse, error) | ||||
| 	ListAvailableRealm(context.Context, *LookupUserRealmRequest) (*ListRealmResponse, error) | ||||
| @@ -133,9 +133,12 @@ type RealmServer interface { | ||||
| 	mustEmbedUnimplementedRealmServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedRealmServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedRealmServer struct { | ||||
| } | ||||
| // UnimplementedRealmServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedRealmServer struct{} | ||||
|  | ||||
| func (UnimplementedRealmServer) ListCommunityRealm(context.Context, *ListRealmRequest) (*ListRealmResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method ListCommunityRealm not implemented") | ||||
| @@ -159,6 +162,7 @@ func (UnimplementedRealmServer) CheckRealmMemberPerm(context.Context, *CheckReal | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method CheckRealmMemberPerm not implemented") | ||||
| } | ||||
| func (UnimplementedRealmServer) mustEmbedUnimplementedRealmServer() {} | ||||
| func (UnimplementedRealmServer) testEmbeddedByValue()               {} | ||||
|  | ||||
| // UnsafeRealmServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to RealmServer will | ||||
| @@ -168,6 +172,13 @@ type UnsafeRealmServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterRealmServer(s grpc.ServiceRegistrar, srv RealmServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedRealmServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&Realm_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: record.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	EventRecorder_RecordEvent_FullMethodName = "/proto.EventRecorder/RecordEvent" | ||||
| @@ -49,20 +49,24 @@ func (c *eventRecorderClient) RecordEvent(ctx context.Context, in *RecordEventRe | ||||
|  | ||||
| // EventRecorderServer is the server API for EventRecorder service. | ||||
| // All implementations must embed UnimplementedEventRecorderServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type EventRecorderServer interface { | ||||
| 	RecordEvent(context.Context, *RecordEventRequest) (*RecordEventResponse, error) | ||||
| 	mustEmbedUnimplementedEventRecorderServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedEventRecorderServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedEventRecorderServer struct { | ||||
| } | ||||
| // UnimplementedEventRecorderServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedEventRecorderServer struct{} | ||||
|  | ||||
| func (UnimplementedEventRecorderServer) RecordEvent(context.Context, *RecordEventRequest) (*RecordEventResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method RecordEvent not implemented") | ||||
| } | ||||
| func (UnimplementedEventRecorderServer) mustEmbedUnimplementedEventRecorderServer() {} | ||||
| func (UnimplementedEventRecorderServer) testEmbeddedByValue()                       {} | ||||
|  | ||||
| // UnsafeEventRecorderServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to EventRecorderServer will | ||||
| @@ -72,6 +76,13 @@ type UnsafeEventRecorderServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterEventRecorderServer(s grpc.ServiceRegistrar, srv EventRecorderServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedEventRecorderServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&EventRecorder_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: services.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	ServiceDirectory_GetService_FullMethodName    = "/proto.ServiceDirectory/GetService" | ||||
| @@ -85,7 +85,7 @@ func (c *serviceDirectoryClient) RemoveService(ctx context.Context, in *RemoveSe | ||||
|  | ||||
| // ServiceDirectoryServer is the server API for ServiceDirectory service. | ||||
| // All implementations must embed UnimplementedServiceDirectoryServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type ServiceDirectoryServer interface { | ||||
| 	GetService(context.Context, *GetServiceRequest) (*GetServiceResponse, error) | ||||
| 	ListService(context.Context, *ListServiceRequest) (*ListServiceResponse, error) | ||||
| @@ -94,9 +94,12 @@ type ServiceDirectoryServer interface { | ||||
| 	mustEmbedUnimplementedServiceDirectoryServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedServiceDirectoryServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedServiceDirectoryServer struct { | ||||
| } | ||||
| // UnimplementedServiceDirectoryServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedServiceDirectoryServer struct{} | ||||
|  | ||||
| func (UnimplementedServiceDirectoryServer) GetService(context.Context, *GetServiceRequest) (*GetServiceResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method GetService not implemented") | ||||
| @@ -111,6 +114,7 @@ func (UnimplementedServiceDirectoryServer) RemoveService(context.Context, *Remov | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method RemoveService not implemented") | ||||
| } | ||||
| func (UnimplementedServiceDirectoryServer) mustEmbedUnimplementedServiceDirectoryServer() {} | ||||
| func (UnimplementedServiceDirectoryServer) testEmbeddedByValue()                          {} | ||||
|  | ||||
| // UnsafeServiceDirectoryServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to ServiceDirectoryServer will | ||||
| @@ -120,6 +124,13 @@ type UnsafeServiceDirectoryServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterServiceDirectoryServer(s grpc.ServiceRegistrar, srv ServiceDirectoryServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedServiceDirectoryServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&ServiceDirectory_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| // Code generated by protoc-gen-go-grpc. DO NOT EDIT. | ||||
| // versions: | ||||
| // - protoc-gen-go-grpc v1.4.0 | ||||
| // - protoc-gen-go-grpc v1.5.1 | ||||
| // - protoc             v5.27.1 | ||||
| // source: stream.proto | ||||
|  | ||||
| @@ -15,8 +15,8 @@ import ( | ||||
|  | ||||
| // 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.62.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion8 | ||||
| // Requires gRPC-Go v1.64.0 or later. | ||||
| const _ = grpc.SupportPackageIsVersion9 | ||||
|  | ||||
| const ( | ||||
| 	StreamController_CountStreamConnection_FullMethodName = "/proto.StreamController/CountStreamConnection" | ||||
| @@ -85,7 +85,7 @@ func (c *streamControllerClient) EmitStreamEvent(ctx context.Context, in *Stream | ||||
|  | ||||
| // StreamControllerServer is the server API for StreamController service. | ||||
| // All implementations must embed UnimplementedStreamControllerServer | ||||
| // for forward compatibility | ||||
| // for forward compatibility. | ||||
| type StreamControllerServer interface { | ||||
| 	CountStreamConnection(context.Context, *CountConnectionRequest) (*CountConnectionResponse, error) | ||||
| 	PushStream(context.Context, *PushStreamRequest) (*PushStreamResponse, error) | ||||
| @@ -94,9 +94,12 @@ type StreamControllerServer interface { | ||||
| 	mustEmbedUnimplementedStreamControllerServer() | ||||
| } | ||||
|  | ||||
| // UnimplementedStreamControllerServer must be embedded to have forward compatible implementations. | ||||
| type UnimplementedStreamControllerServer struct { | ||||
| } | ||||
| // UnimplementedStreamControllerServer must be embedded to have | ||||
| // forward compatible implementations. | ||||
| // | ||||
| // NOTE: this should be embedded by value instead of pointer to avoid a nil | ||||
| // pointer dereference when methods are called. | ||||
| type UnimplementedStreamControllerServer struct{} | ||||
|  | ||||
| func (UnimplementedStreamControllerServer) CountStreamConnection(context.Context, *CountConnectionRequest) (*CountConnectionResponse, error) { | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method CountStreamConnection not implemented") | ||||
| @@ -111,6 +114,7 @@ func (UnimplementedStreamControllerServer) EmitStreamEvent(context.Context, *Str | ||||
| 	return nil, status.Errorf(codes.Unimplemented, "method EmitStreamEvent not implemented") | ||||
| } | ||||
| func (UnimplementedStreamControllerServer) mustEmbedUnimplementedStreamControllerServer() {} | ||||
| func (UnimplementedStreamControllerServer) testEmbeddedByValue()                          {} | ||||
|  | ||||
| // UnsafeStreamControllerServer may be embedded to opt out of forward compatibility for this service. | ||||
| // Use of this interface is not recommended, as added methods to StreamControllerServer will | ||||
| @@ -120,6 +124,13 @@ type UnsafeStreamControllerServer interface { | ||||
| } | ||||
|  | ||||
| func RegisterStreamControllerServer(s grpc.ServiceRegistrar, srv StreamControllerServer) { | ||||
| 	// If the following call pancis, it indicates UnimplementedStreamControllerServer was | ||||
| 	// embedded by pointer and is nil.  This will cause panics if an | ||||
| 	// unimplemented method is ever invoked, so we test this at initialization | ||||
| 	// time to prevent it from happening at runtime later due to I/O. | ||||
| 	if t, ok := srv.(interface{ testEmbeddedByValue() }); ok { | ||||
| 		t.testEmbeddedByValue() | ||||
| 	} | ||||
| 	s.RegisterService(&StreamController_ServiceDesc, srv) | ||||
| } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user