Add http endpoints

This commit is contained in:
Barak Michener 2020-12-04 18:06:24 -08:00
parent 3b05f4316c
commit 56116aea2a
7 changed files with 136 additions and 1 deletions

View file

@ -2,6 +2,7 @@ package main
import (
"context"
"fmt"
"github.com/barakmich/tinkerbell/ray_rpc"
"go.uber.org/zap"
@ -41,6 +42,7 @@ func (r *Raylet) WaitObject(_ context.Context, _ *ray_rpc.WaitRequest) (*ray_rpc
}
func (r *Raylet) Schedule(_ context.Context, task *ray_rpc.ClientTask) (*ray_rpc.ClientTaskTicket, error) {
fmt.Println(task)
zap.S().Debug("Schedule:", task.Type)
id := r.Objects.MakeID()
ticket := &ray_rpc.ClientTaskTicket{serializeObjectID(id)}