MCPcopy Create free account
hub / github.com/BWbwchen/MapReduce / startWorker

Function startWorker

util.go:109–123  ·  view source on GitHub ↗
(plugin string, id int, nReducer int, storeInRAM bool)

Source from the content-addressed store, hash-verified

107}
108
109func startWorker(plugin string, id int, nReducer int, storeInRAM bool) {
110 pluginFile, _ := filepath.Abs(plugin)
111
112 var wg sync.WaitGroup
113 worker.Init(MasterIP)
114
115 // Start Worker
116 wg.Add(1)
117 go func() {
118 worker.StartWorker(pluginFile, nReducer, fmt.Sprintf(":1000%v", id+1), storeInRAM)
119 wg.Done()
120 }()
121
122 wg.Wait()
123}

Callers 1

StartWorkerFunction · 0.85

Calls 2

InitFunction · 0.92
StartWorkerFunction · 0.92

Tested by

no test coverage detected