Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶ added in v2.0.1
func New(schedulerServer SchedulerServer, opts ...grpc.ServerOption) *grpc.Server
Types ¶
type SchedulerServer ¶
type SchedulerServer interface { // RegisterPeerTask registers a peer into one task. RegisterPeerTask(context.Context, *scheduler.PeerTaskRequest) (*scheduler.RegisterResult, error) // ReportPieceResult reports piece results and receives peer packets. ReportPieceResult(scheduler.Scheduler_ReportPieceResultServer) error // ReportPeerResult reports downloading result for the peer task. ReportPeerResult(context.Context, *scheduler.PeerResult) error // LeaveTask makes the peer leaving from scheduling overlay for the task. LeaveTask(context.Context, *scheduler.PeerTarget) error }
SchedulerServer refer to scheduler.SchedulerServer
Click to show internal directories.
Click to hide internal directories.