Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FinishedTaskArgs ¶
type FinishedTaskArgs struct { // what type of task was the worker assigned? TaskType TaskType // which task was it ? TaskNum int }
The second RPC finshed worker -> coordinator FinishedTask RPCs are sent from an idle worker to coordinator to indicate that a task has been completed
type GetTaskArgs ¶
type GetTaskArgs struct{}
The first RPC idle worker -> coordinator GetTask RPCs are sent from an idle worker to coordinator to ask the next task to perform
type GetTaskReply ¶
type GetTaskReply struct { // what type of the task is this? (map, reduce, done) TaskType TaskType // task number of ether map/reduce task TaskNum int // needed for Map (to know which file to write) NReduceTask int // needed for Map (to know which file to read) MapFile string // needed for Reduce (to know how many intermediate map file to read) NMapTasks int }
type Master ¶
type Master struct {
// contains filtered or unexported fields
}
func MakeMaster ¶
create a Master mrmaster.go calls this function nReduce is the number of reduce tasks to use.
Click to show internal directories.
Click to hide internal directories.