Skip to content
This repository has been archived by the owner on Jul 7, 2019. It is now read-only.

Commit

Permalink
Merge pull request #25 from shivramsrivastava/schdname_cherry
Browse files Browse the repository at this point in the history
[CHERRY-PICK]  Changing the event source to the correct schedulerName
  • Loading branch information
volcano-sh-bot authored Jun 7, 2019
2 parents 92c4d3f + 120b716 commit 1b4f76c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/kube-batch/app/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func Run(opt *options.ServerOption) error {
// Prepare event clients.
broadcaster := record.NewBroadcaster()
broadcaster.StartRecordingToSink(&corev1.EventSinkImpl{Interface: leaderElectionClient.CoreV1().Events(opt.LockObjectNamespace)})
eventRecorder := broadcaster.NewRecorder(scheme.Scheme, v1.EventSource{Component: "kube-batch"})
eventRecorder := broadcaster.NewRecorder(scheme.Scheme, v1.EventSource{Component: opt.SchedulerName})

hostname, err := os.Hostname()
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/scheduler/cache/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ func newSchedulerCache(config *rest.Config, schedulerName string, defaultQueue s
// Prepare event clients.
broadcaster := record.NewBroadcaster()
broadcaster.StartRecordingToSink(&corev1.EventSinkImpl{Interface: sc.kubeclient.CoreV1().Events("")})
sc.Recorder = broadcaster.NewRecorder(scheme.Scheme, v1.EventSource{Component: "kube-batch"})
sc.Recorder = broadcaster.NewRecorder(scheme.Scheme, v1.EventSource{Component: schedulerName})

sc.Binder = &defaultBinder{
kubeclient: sc.kubeclient,
Expand Down

0 comments on commit 1b4f76c

Please sign in to comment.