Skip to content

Commit

Permalink
SerfManager
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Castell committed May 20, 2015
1 parent 479bc69 commit e3814f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dcron/serf.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ func (sm *serfManager) Terminate() {
sm.Agent.Process.Signal(syscall.SIGKILL)
}

func NewSerfClient(agent *exec.Cmd) *serfManager {
func NewSerfManager(agent *exec.Cmd) *serfManager {
serfConfig := &client.Config{Addr: config.GetString("rpc_addr")}
sc, err := client.ClientFromConfig(serfConfig)
// wait for serf
Expand Down Expand Up @@ -65,7 +65,7 @@ func initSerf() {
serfArgs := []string{discover, "-rpc-addr=" + config.GetString("rpc_addr"), "-config-file=config/dcron.json"}
agent, err := spawnProc("./bin/serf agent" + strings.Join(serfArgs, " "))

serf = NewSerfClient(agent)
serf = NewSerfManager(agent)
defer serf.Close()

ch := make(chan map[string]interface{}, 1)
Expand Down

0 comments on commit e3814f6

Please sign in to comment.