// Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.2.0 // - protoc v3.21.6 // source: pkg/apis/scheduler/v2/scheduler.proto package scheduler import ( context "context" v2 "d7y.io/api/v2/pkg/apis/common/v2" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" emptypb "google.golang.org/protobuf/types/known/emptypb" ) // 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 // SchedulerClient is the client API for Scheduler 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 SchedulerClient interface { // AnnouncePeer announces peer to scheduler. AnnouncePeer(ctx context.Context, opts ...grpc.CallOption) (Scheduler_AnnouncePeerClient, error) // Checks information of peer. StatPeer(ctx context.Context, in *StatPeerRequest, opts ...grpc.CallOption) (*v2.Peer, error) // DeletePeer releases peer in scheduler. DeletePeer(ctx context.Context, in *DeletePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // Checks information of task. StatTask(ctx context.Context, in *StatTaskRequest, opts ...grpc.CallOption) (*v2.Task, error) // DeleteTask releases task in scheduler. DeleteTask(ctx context.Context, in *DeleteTaskRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // AnnounceHost announces host to scheduler. AnnounceHost(ctx context.Context, in *AnnounceHostRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // ListHosts lists hosts in scheduler. ListHosts(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ListHostsResponse, error) // DeleteHost releases host in scheduler. DeleteHost(ctx context.Context, in *DeleteHostRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // AnnouncePersistentCachePeer announces persistent cache peer to scheduler. AnnouncePersistentCachePeer(ctx context.Context, opts ...grpc.CallOption) (Scheduler_AnnouncePersistentCachePeerClient, error) // Checks information of persistent cache peer. StatPersistentCachePeer(ctx context.Context, in *StatPersistentCachePeerRequest, opts ...grpc.CallOption) (*v2.PersistentCachePeer, error) // DeletePersistentCachePeer releases persistent cache peer in scheduler. DeletePersistentCachePeer(ctx context.Context, in *DeletePersistentCachePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // UploadPersistentCacheTaskStarted uploads persistent cache task started to scheduler. UploadPersistentCacheTaskStarted(ctx context.Context, in *UploadPersistentCacheTaskStartedRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // UploadPersistentCacheTaskFinished uploads persistent cache task finished to scheduler. UploadPersistentCacheTaskFinished(ctx context.Context, in *UploadPersistentCacheTaskFinishedRequest, opts ...grpc.CallOption) (*v2.PersistentCacheTask, error) // UploadPersistentCacheTaskFailed uploads persistent cache task failed to scheduler. UploadPersistentCacheTaskFailed(ctx context.Context, in *UploadPersistentCacheTaskFailedRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // Checks information of persistent cache task. StatPersistentCacheTask(ctx context.Context, in *StatPersistentCacheTaskRequest, opts ...grpc.CallOption) (*v2.PersistentCacheTask, error) // DeletePersistentCacheTask releases persistent cache task in scheduler. DeletePersistentCacheTask(ctx context.Context, in *DeletePersistentCacheTaskRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) } type schedulerClient struct { cc grpc.ClientConnInterface } func NewSchedulerClient(cc grpc.ClientConnInterface) SchedulerClient { return &schedulerClient{cc} } func (c *schedulerClient) AnnouncePeer(ctx context.Context, opts ...grpc.CallOption) (Scheduler_AnnouncePeerClient, error) { stream, err := c.cc.NewStream(ctx, &Scheduler_ServiceDesc.Streams[0], "/scheduler.v2.Scheduler/AnnouncePeer", opts...) if err != nil { return nil, err } x := &schedulerAnnouncePeerClient{stream} return x, nil } type Scheduler_AnnouncePeerClient interface { Send(*AnnouncePeerRequest) error Recv() (*AnnouncePeerResponse, error) grpc.ClientStream } type schedulerAnnouncePeerClient struct { grpc.ClientStream } func (x *schedulerAnnouncePeerClient) Send(m *AnnouncePeerRequest) error { return x.ClientStream.SendMsg(m) } func (x *schedulerAnnouncePeerClient) Recv() (*AnnouncePeerResponse, error) { m := new(AnnouncePeerResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } return m, nil } func (c *schedulerClient) StatPeer(ctx context.Context, in *StatPeerRequest, opts ...grpc.CallOption) (*v2.Peer, error) { out := new(v2.Peer) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/StatPeer", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) DeletePeer(ctx context.Context, in *DeletePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/DeletePeer", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) StatTask(ctx context.Context, in *StatTaskRequest, opts ...grpc.CallOption) (*v2.Task, error) { out := new(v2.Task) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/StatTask", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) DeleteTask(ctx context.Context, in *DeleteTaskRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/DeleteTask", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) AnnounceHost(ctx context.Context, in *AnnounceHostRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/AnnounceHost", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) ListHosts(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ListHostsResponse, error) { out := new(ListHostsResponse) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/ListHosts", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) DeleteHost(ctx context.Context, in *DeleteHostRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/DeleteHost", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) AnnouncePersistentCachePeer(ctx context.Context, opts ...grpc.CallOption) (Scheduler_AnnouncePersistentCachePeerClient, error) { stream, err := c.cc.NewStream(ctx, &Scheduler_ServiceDesc.Streams[1], "/scheduler.v2.Scheduler/AnnouncePersistentCachePeer", opts...) if err != nil { return nil, err } x := &schedulerAnnouncePersistentCachePeerClient{stream} return x, nil } type Scheduler_AnnouncePersistentCachePeerClient interface { Send(*AnnouncePersistentCachePeerRequest) error Recv() (*AnnouncePersistentCachePeerResponse, error) grpc.ClientStream } type schedulerAnnouncePersistentCachePeerClient struct { grpc.ClientStream } func (x *schedulerAnnouncePersistentCachePeerClient) Send(m *AnnouncePersistentCachePeerRequest) error { return x.ClientStream.SendMsg(m) } func (x *schedulerAnnouncePersistentCachePeerClient) Recv() (*AnnouncePersistentCachePeerResponse, error) { m := new(AnnouncePersistentCachePeerResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } return m, nil } func (c *schedulerClient) StatPersistentCachePeer(ctx context.Context, in *StatPersistentCachePeerRequest, opts ...grpc.CallOption) (*v2.PersistentCachePeer, error) { out := new(v2.PersistentCachePeer) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/StatPersistentCachePeer", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) DeletePersistentCachePeer(ctx context.Context, in *DeletePersistentCachePeerRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/DeletePersistentCachePeer", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) UploadPersistentCacheTaskStarted(ctx context.Context, in *UploadPersistentCacheTaskStartedRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/UploadPersistentCacheTaskStarted", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) UploadPersistentCacheTaskFinished(ctx context.Context, in *UploadPersistentCacheTaskFinishedRequest, opts ...grpc.CallOption) (*v2.PersistentCacheTask, error) { out := new(v2.PersistentCacheTask) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/UploadPersistentCacheTaskFinished", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) UploadPersistentCacheTaskFailed(ctx context.Context, in *UploadPersistentCacheTaskFailedRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/UploadPersistentCacheTaskFailed", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) StatPersistentCacheTask(ctx context.Context, in *StatPersistentCacheTaskRequest, opts ...grpc.CallOption) (*v2.PersistentCacheTask, error) { out := new(v2.PersistentCacheTask) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/StatPersistentCacheTask", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *schedulerClient) DeletePersistentCacheTask(ctx context.Context, in *DeletePersistentCacheTaskRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/scheduler.v2.Scheduler/DeletePersistentCacheTask", in, out, opts...) if err != nil { return nil, err } return out, nil } // SchedulerServer is the server API for Scheduler service. // All implementations should embed UnimplementedSchedulerServer // for forward compatibility type SchedulerServer interface { // AnnouncePeer announces peer to scheduler. AnnouncePeer(Scheduler_AnnouncePeerServer) error // Checks information of peer. StatPeer(context.Context, *StatPeerRequest) (*v2.Peer, error) // DeletePeer releases peer in scheduler. DeletePeer(context.Context, *DeletePeerRequest) (*emptypb.Empty, error) // Checks information of task. StatTask(context.Context, *StatTaskRequest) (*v2.Task, error) // DeleteTask releases task in scheduler. DeleteTask(context.Context, *DeleteTaskRequest) (*emptypb.Empty, error) // AnnounceHost announces host to scheduler. AnnounceHost(context.Context, *AnnounceHostRequest) (*emptypb.Empty, error) // ListHosts lists hosts in scheduler. ListHosts(context.Context, *emptypb.Empty) (*ListHostsResponse, error) // DeleteHost releases host in scheduler. DeleteHost(context.Context, *DeleteHostRequest) (*emptypb.Empty, error) // AnnouncePersistentCachePeer announces persistent cache peer to scheduler. AnnouncePersistentCachePeer(Scheduler_AnnouncePersistentCachePeerServer) error // Checks information of persistent cache peer. StatPersistentCachePeer(context.Context, *StatPersistentCachePeerRequest) (*v2.PersistentCachePeer, error) // DeletePersistentCachePeer releases persistent cache peer in scheduler. DeletePersistentCachePeer(context.Context, *DeletePersistentCachePeerRequest) (*emptypb.Empty, error) // UploadPersistentCacheTaskStarted uploads persistent cache task started to scheduler. UploadPersistentCacheTaskStarted(context.Context, *UploadPersistentCacheTaskStartedRequest) (*emptypb.Empty, error) // UploadPersistentCacheTaskFinished uploads persistent cache task finished to scheduler. UploadPersistentCacheTaskFinished(context.Context, *UploadPersistentCacheTaskFinishedRequest) (*v2.PersistentCacheTask, error) // UploadPersistentCacheTaskFailed uploads persistent cache task failed to scheduler. UploadPersistentCacheTaskFailed(context.Context, *UploadPersistentCacheTaskFailedRequest) (*emptypb.Empty, error) // Checks information of persistent cache task. StatPersistentCacheTask(context.Context, *StatPersistentCacheTaskRequest) (*v2.PersistentCacheTask, error) // DeletePersistentCacheTask releases persistent cache task in scheduler. DeletePersistentCacheTask(context.Context, *DeletePersistentCacheTaskRequest) (*emptypb.Empty, error) } // UnimplementedSchedulerServer should be embedded to have forward compatible implementations. type UnimplementedSchedulerServer struct { } func (UnimplementedSchedulerServer) AnnouncePeer(Scheduler_AnnouncePeerServer) error { return status.Errorf(codes.Unimplemented, "method AnnouncePeer not implemented") } func (UnimplementedSchedulerServer) StatPeer(context.Context, *StatPeerRequest) (*v2.Peer, error) { return nil, status.Errorf(codes.Unimplemented, "method StatPeer not implemented") } func (UnimplementedSchedulerServer) DeletePeer(context.Context, *DeletePeerRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeletePeer not implemented") } func (UnimplementedSchedulerServer) StatTask(context.Context, *StatTaskRequest) (*v2.Task, error) { return nil, status.Errorf(codes.Unimplemented, "method StatTask not implemented") } func (UnimplementedSchedulerServer) DeleteTask(context.Context, *DeleteTaskRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeleteTask not implemented") } func (UnimplementedSchedulerServer) AnnounceHost(context.Context, *AnnounceHostRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method AnnounceHost not implemented") } func (UnimplementedSchedulerServer) ListHosts(context.Context, *emptypb.Empty) (*ListHostsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ListHosts not implemented") } func (UnimplementedSchedulerServer) DeleteHost(context.Context, *DeleteHostRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeleteHost not implemented") } func (UnimplementedSchedulerServer) AnnouncePersistentCachePeer(Scheduler_AnnouncePersistentCachePeerServer) error { return status.Errorf(codes.Unimplemented, "method AnnouncePersistentCachePeer not implemented") } func (UnimplementedSchedulerServer) StatPersistentCachePeer(context.Context, *StatPersistentCachePeerRequest) (*v2.PersistentCachePeer, error) { return nil, status.Errorf(codes.Unimplemented, "method StatPersistentCachePeer not implemented") } func (UnimplementedSchedulerServer) DeletePersistentCachePeer(context.Context, *DeletePersistentCachePeerRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeletePersistentCachePeer not implemented") } func (UnimplementedSchedulerServer) UploadPersistentCacheTaskStarted(context.Context, *UploadPersistentCacheTaskStartedRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method UploadPersistentCacheTaskStarted not implemented") } func (UnimplementedSchedulerServer) UploadPersistentCacheTaskFinished(context.Context, *UploadPersistentCacheTaskFinishedRequest) (*v2.PersistentCacheTask, error) { return nil, status.Errorf(codes.Unimplemented, "method UploadPersistentCacheTaskFinished not implemented") } func (UnimplementedSchedulerServer) UploadPersistentCacheTaskFailed(context.Context, *UploadPersistentCacheTaskFailedRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method UploadPersistentCacheTaskFailed not implemented") } func (UnimplementedSchedulerServer) StatPersistentCacheTask(context.Context, *StatPersistentCacheTaskRequest) (*v2.PersistentCacheTask, error) { return nil, status.Errorf(codes.Unimplemented, "method StatPersistentCacheTask not implemented") } func (UnimplementedSchedulerServer) DeletePersistentCacheTask(context.Context, *DeletePersistentCacheTaskRequest) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method DeletePersistentCacheTask not implemented") } // UnsafeSchedulerServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to SchedulerServer will // result in compilation errors. type UnsafeSchedulerServer interface { mustEmbedUnimplementedSchedulerServer() } func RegisterSchedulerServer(s grpc.ServiceRegistrar, srv SchedulerServer) { s.RegisterService(&Scheduler_ServiceDesc, srv) } func _Scheduler_AnnouncePeer_Handler(srv interface{}, stream grpc.ServerStream) error { return srv.(SchedulerServer).AnnouncePeer(&schedulerAnnouncePeerServer{stream}) } type Scheduler_AnnouncePeerServer interface { Send(*AnnouncePeerResponse) error Recv() (*AnnouncePeerRequest, error) grpc.ServerStream } type schedulerAnnouncePeerServer struct { grpc.ServerStream } func (x *schedulerAnnouncePeerServer) Send(m *AnnouncePeerResponse) error { return x.ServerStream.SendMsg(m) } func (x *schedulerAnnouncePeerServer) Recv() (*AnnouncePeerRequest, error) { m := new(AnnouncePeerRequest) if err := x.ServerStream.RecvMsg(m); err != nil { return nil, err } return m, nil } func _Scheduler_StatPeer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(StatPeerRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).StatPeer(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/StatPeer", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).StatPeer(ctx, req.(*StatPeerRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_DeletePeer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeletePeerRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).DeletePeer(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/DeletePeer", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).DeletePeer(ctx, req.(*DeletePeerRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_StatTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(StatTaskRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).StatTask(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/StatTask", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).StatTask(ctx, req.(*StatTaskRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_DeleteTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeleteTaskRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).DeleteTask(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/DeleteTask", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).DeleteTask(ctx, req.(*DeleteTaskRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_AnnounceHost_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AnnounceHostRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).AnnounceHost(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/AnnounceHost", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).AnnounceHost(ctx, req.(*AnnounceHostRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_ListHosts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(emptypb.Empty) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).ListHosts(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/ListHosts", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).ListHosts(ctx, req.(*emptypb.Empty)) } return interceptor(ctx, in, info, handler) } func _Scheduler_DeleteHost_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeleteHostRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).DeleteHost(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/DeleteHost", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).DeleteHost(ctx, req.(*DeleteHostRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_AnnouncePersistentCachePeer_Handler(srv interface{}, stream grpc.ServerStream) error { return srv.(SchedulerServer).AnnouncePersistentCachePeer(&schedulerAnnouncePersistentCachePeerServer{stream}) } type Scheduler_AnnouncePersistentCachePeerServer interface { Send(*AnnouncePersistentCachePeerResponse) error Recv() (*AnnouncePersistentCachePeerRequest, error) grpc.ServerStream } type schedulerAnnouncePersistentCachePeerServer struct { grpc.ServerStream } func (x *schedulerAnnouncePersistentCachePeerServer) Send(m *AnnouncePersistentCachePeerResponse) error { return x.ServerStream.SendMsg(m) } func (x *schedulerAnnouncePersistentCachePeerServer) Recv() (*AnnouncePersistentCachePeerRequest, error) { m := new(AnnouncePersistentCachePeerRequest) if err := x.ServerStream.RecvMsg(m); err != nil { return nil, err } return m, nil } func _Scheduler_StatPersistentCachePeer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(StatPersistentCachePeerRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).StatPersistentCachePeer(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/StatPersistentCachePeer", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).StatPersistentCachePeer(ctx, req.(*StatPersistentCachePeerRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_DeletePersistentCachePeer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeletePersistentCachePeerRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).DeletePersistentCachePeer(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/DeletePersistentCachePeer", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).DeletePersistentCachePeer(ctx, req.(*DeletePersistentCachePeerRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_UploadPersistentCacheTaskStarted_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UploadPersistentCacheTaskStartedRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).UploadPersistentCacheTaskStarted(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/UploadPersistentCacheTaskStarted", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).UploadPersistentCacheTaskStarted(ctx, req.(*UploadPersistentCacheTaskStartedRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_UploadPersistentCacheTaskFinished_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UploadPersistentCacheTaskFinishedRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).UploadPersistentCacheTaskFinished(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/UploadPersistentCacheTaskFinished", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).UploadPersistentCacheTaskFinished(ctx, req.(*UploadPersistentCacheTaskFinishedRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_UploadPersistentCacheTaskFailed_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UploadPersistentCacheTaskFailedRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).UploadPersistentCacheTaskFailed(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/UploadPersistentCacheTaskFailed", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).UploadPersistentCacheTaskFailed(ctx, req.(*UploadPersistentCacheTaskFailedRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_StatPersistentCacheTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(StatPersistentCacheTaskRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).StatPersistentCacheTask(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/StatPersistentCacheTask", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).StatPersistentCacheTask(ctx, req.(*StatPersistentCacheTaskRequest)) } return interceptor(ctx, in, info, handler) } func _Scheduler_DeletePersistentCacheTask_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeletePersistentCacheTaskRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(SchedulerServer).DeletePersistentCacheTask(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/scheduler.v2.Scheduler/DeletePersistentCacheTask", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(SchedulerServer).DeletePersistentCacheTask(ctx, req.(*DeletePersistentCacheTaskRequest)) } return interceptor(ctx, in, info, handler) } // Scheduler_ServiceDesc is the grpc.ServiceDesc for Scheduler service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var Scheduler_ServiceDesc = grpc.ServiceDesc{ ServiceName: "scheduler.v2.Scheduler", HandlerType: (*SchedulerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "StatPeer", Handler: _Scheduler_StatPeer_Handler, }, { MethodName: "DeletePeer", Handler: _Scheduler_DeletePeer_Handler, }, { MethodName: "StatTask", Handler: _Scheduler_StatTask_Handler, }, { MethodName: "DeleteTask", Handler: _Scheduler_DeleteTask_Handler, }, { MethodName: "AnnounceHost", Handler: _Scheduler_AnnounceHost_Handler, }, { MethodName: "ListHosts", Handler: _Scheduler_ListHosts_Handler, }, { MethodName: "DeleteHost", Handler: _Scheduler_DeleteHost_Handler, }, { MethodName: "StatPersistentCachePeer", Handler: _Scheduler_StatPersistentCachePeer_Handler, }, { MethodName: "DeletePersistentCachePeer", Handler: _Scheduler_DeletePersistentCachePeer_Handler, }, { MethodName: "UploadPersistentCacheTaskStarted", Handler: _Scheduler_UploadPersistentCacheTaskStarted_Handler, }, { MethodName: "UploadPersistentCacheTaskFinished", Handler: _Scheduler_UploadPersistentCacheTaskFinished_Handler, }, { MethodName: "UploadPersistentCacheTaskFailed", Handler: _Scheduler_UploadPersistentCacheTaskFailed_Handler, }, { MethodName: "StatPersistentCacheTask", Handler: _Scheduler_StatPersistentCacheTask_Handler, }, { MethodName: "DeletePersistentCacheTask", Handler: _Scheduler_DeletePersistentCacheTask_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "AnnouncePeer", Handler: _Scheduler_AnnouncePeer_Handler, ServerStreams: true, ClientStreams: true, }, { StreamName: "AnnouncePersistentCachePeer", Handler: _Scheduler_AnnouncePersistentCachePeer_Handler, ServerStreams: true, ClientStreams: true, }, }, Metadata: "pkg/apis/scheduler/v2/scheduler.proto", }