Documentation
¶
Index ¶
Constants ¶
View Source
const ( UnAllocated = iota Allocated Finished )
file status
View Source
const ( MsgForStartTask = iota MsgForFinishMap MsgForFinishReduce )
MessageType
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Master ¶
type Master struct {
BeginningFile []string
MapTaskNum int
BeginningFileStatus map[string]int
MapFinished bool
NReduce int
InterFile [][]string
InterFileStatus map[int]int
ReduceFinished bool
RWLock *sync.RWMutex
}
Master...
func MakeMaster ¶
create a Master. main/mrmaster.go calls this function. nReduce is the number of reduce tasks to use.
func (*Master) HandleCallForInterFile ¶
func (m *Master) HandleCallForInterFile(args *MyIntermediateFile, reply *MyReply) error
type MyIntermediateFile ¶
send intermediate files' filename to master
Click to show internal directories.
Click to hide internal directories.