Skip to content

Commit

Permalink
Merge pull request cockroachdb#137 from crowdflux/flu_monitor_changes
Browse files Browse the repository at this point in the history
Logic correction for running job managers
  • Loading branch information
govindamurali authored Feb 5, 2017
2 parents d8988b6 + 060b4df commit e1ff564
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
3 changes: 2 additions & 1 deletion app/services/flu_svc/flu_monitor/flu_monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,13 @@ func (fm *FluMonitor) getOrCreateProjectHandler(flu models.FeedLineUnit) Project
pHandler := NewProjectHandler(pc)

fm.bulkProcessor.AddJobManager(pHandler.jobManager)

fm.projectHandlers[flu.ProjectId] = pHandler

go pHandler.startFeedLineProcessor()
go pHandler.startCBUProcessor()

pHandler.jobManager.Run()

projectHandler = pHandler
plog.Info("Flu Monitor", "Project Handler Set", projectHandler.config.ProjectId)
}
Expand Down
1 change: 1 addition & 0 deletions bulk_processor/bulk_processor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ func TestDispatcher_Start(t *testing.T) {

for _, c := range clients {
dispatcher.AddJobManager(c.jobManager)
c.jobManager.Run()
}

dispatcher.Start()
Expand Down
2 changes: 0 additions & 2 deletions bulk_processor/dispatcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ func (d *Dispatcher) Start() (started bool) {

d.startCheck()

runJobManagers(d.jobManagers)

d.startWorkers(d.maxWorkers)

go d.dispatch()
Expand Down

0 comments on commit e1ff564

Please sign in to comment.