summaryrefslogtreecommitdiff
path: root/scorshd.go
diff options
context:
space:
mode:
authorKatolaZ <katolaz@freaknet.org>2017-08-07 09:55:35 +0100
committerKatolaZ <katolaz@freaknet.org>2017-08-07 09:55:35 +0100
commit096b3fd2867d7bb2d3cd1f85d8806c651b26d625 (patch)
tree4dfcc77e86cc0e667c14a92c43d1785b4cb5e4b8 /scorshd.go
parent802d703f617036ec1d18aa8ecb9678ca3390f68a (diff)
parentd3105e671a19fec1060652531ce783227fb9fab6 (diff)
Merge branch 'devel'
Diffstat (limited to 'scorshd.go')
-rw-r--r--scorshd.go14
1 files changed, 7 insertions, 7 deletions
diff --git a/scorshd.go b/scorshd.go
index b69e501..9ada3b8 100644
--- a/scorshd.go
+++ b/scorshd.go
@@ -46,9 +46,9 @@ func SCORSHerr(err int) error {
}
-func findMatchingWorkers(master *SCORSHmaster, msg *SCORSHmsg) []*SCORSHworker {
+func findMatchingWorkers(master *master, msg *spoolMsg) []*worker {
- var ret []*SCORSHworker
+ var ret []*worker
for idx, w := range master.Workers {
if w.Matches(msg.Repo, msg.Branch) {
@@ -59,7 +59,7 @@ func findMatchingWorkers(master *SCORSHmaster, msg *SCORSHmsg) []*SCORSHworker {
return ret
}
-func runMaster(master *SCORSHmaster) {
+func runMaster(master *master) {
// master main loop:
@@ -108,16 +108,16 @@ func runMaster(master *SCORSHmaster) {
debug.log("[master] Exiting the for loop, for some mysterious reason...\n")
}
-func initMaster() *SCORSHmaster {
+func initMaster() *master {
master := readGlobalConfig(*confFile)
- master.Repos = make(map[string][]*SCORSHworker)
+ master.Repos = make(map[string][]*worker)
master.WorkingMsg = make(map[string]int)
// This is the channel on which we receive acks from workers
- master.StatusChan = make(chan SCORSHmsg)
+ master.StatusChan = make(chan spoolMsg)
// This is the channel on which we exchange messages with the spooler
- master.Spooler = make(chan SCORSHmsg)
+ master.Spooler = make(chan spoolMsg)
debug.log("[InitMaster] StatusChan: %s\n", master.StatusChan)