Skip to content

Commit 936b352

Browse files
committed
[core] Inform user if offer includes multiple executors
1 parent a5dc1f1 commit 936b352

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

core/task/scheduler.go

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -554,8 +554,19 @@ func (state *schedulerState) resourceOffers(fidStore store.Singleton) events.Han
554554
// we start a new one by generating a new ID
555555
if len(offer.ExecutorIDs) == 0 {
556556
targetExecutorId.Value = uid.New().String()
557+
log.WithField("executorId", targetExecutorId.Value).
558+
WithField("offerHost", offer.GetHostname()).
559+
WithField("level", infologger.IL_Devel).
560+
Info("received offer without executor ID, will start new executor if accepted")
557561
} else {
558562
targetExecutorId.Value = offer.ExecutorIDs[0].Value
563+
if len(offer.ExecutorIDs) > 1 {
564+
log.WithField("executorId", targetExecutorId.Value).
565+
WithField("executorIds", offer.ExecutorIDs).
566+
WithField("offerHost", offer.GetHostname()).
567+
WithField("level", infologger.IL_Devel).
568+
Warn("received offer with more than one executor ID, will use first one")
569+
}
559570
}
560571

561572
host := offer.GetHostname()

0 commit comments

Comments
 (0)