You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pkg/watcher/watcher.go
+43Lines changed: 43 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ import (
5
5
"fmt"
6
6
"log/slog"
7
7
"strconv"
8
+
"sync"
8
9
"time"
9
10
10
11
"github.com/civo/civogo"
@@ -39,6 +40,9 @@ type watcher struct {
39
40
nodeDesiredGPUCountint
40
41
rebootTimeWindowMinutes time.Duration
41
42
43
+
// NOTE: This is only effective when running with a single node-agent. If we want to run multiple instances, additional logic modifications will be required.
// isLastRebootCommandTimeAfter checks if the last reboot command time for the specified node
213
+
// is after the given threshold time. In case of delays in reboot, the
214
+
// LastTransitionTime of node might not be updated, so it compares the latest reboot
215
+
// command time to prevent sending reboot commands multiple times.
216
+
// NOTE: This is only effective when running with a single node-agent. If we want to run multiple instances, additional logic modifications will be required.
0 commit comments