Skip to content
Snippets Groups Projects
Commit 7585111f authored by Sybren A. Stüvel's avatar Sybren A. Stüvel
Browse files

Manager: added some comments

parent 075b4b3e
No related branches found
No related tags found
No related merge requests found
...@@ -33,6 +33,7 @@ type Task struct { ...@@ -33,6 +33,7 @@ type Task struct {
LastWorkerPing *time.Time `bson:"last_worker_ping,omitempty" json:"-"` LastWorkerPing *time.Time `bson:"last_worker_ping,omitempty" json:"-"`
} }
// Both sent from Worker to Manager, as well as from Manager to Server.
type TaskUpdate struct { type TaskUpdate struct {
Id bson.ObjectId `bson:"_id" json:"_id"` Id bson.ObjectId `bson:"_id" json:"_id"`
TaskId bson.ObjectId `bson:"task_id" json:"task_id,omitempty"` TaskId bson.ObjectId `bson:"task_id" json:"task_id,omitempty"`
...@@ -46,6 +47,7 @@ type TaskUpdate struct { ...@@ -46,6 +47,7 @@ type TaskUpdate struct {
Worker string `bson:"worker" json:"worker"` Worker string `bson:"worker" json:"worker"`
} }
// Received from Server.
type TaskUpdateResponse struct { type TaskUpdateResponse struct {
ModifiedCount int `json:"modified_count"` ModifiedCount int `json:"modified_count"`
HandledUpdateIds []bson.ObjectId `json:"handled_update_ids,omitempty"` HandledUpdateIds []bson.ObjectId `json:"handled_update_ids,omitempty"`
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment