diff --git a/client/driver/logrotator/logs.go b/client/driver/logrotator/logs.go index a9eecf983..026c196be 100644 --- a/client/driver/logrotator/logs.go +++ b/client/driver/logrotator/logs.go @@ -136,7 +136,6 @@ func (l *LogRotator) Start(r io.Reader) error { } } } - return nil } // PurgeOldFiles removes older files and keeps only the last N files rotated for diff --git a/client/task_runner.go b/client/task_runner.go index cbf4618ec..226b9de8a 100644 --- a/client/task_runner.go +++ b/client/task_runner.go @@ -320,8 +320,6 @@ func (r *TaskRunner) run() { // Set force start because we are restarting the task. forceStart = true } - - return } // handleUpdate takes an updated allocation and updates internal state to diff --git a/nomad/blocked_evals.go b/nomad/blocked_evals.go index 8d818c18f..1e627c591 100644 --- a/nomad/blocked_evals.go +++ b/nomad/blocked_evals.go @@ -259,8 +259,6 @@ SCAN: case <-b.duplicateCh: goto SCAN } - - return nil } // Flush is used to clear the state of blocked evaluations. diff --git a/scheduler/generic_sched_test.go b/scheduler/generic_sched_test.go index 55647ee0c..839112965 100644 --- a/scheduler/generic_sched_test.go +++ b/scheduler/generic_sched_test.go @@ -580,7 +580,7 @@ func TestServiceSched_JobModify_InPlace(t *testing.T) { h.AssertEvalStatus(t, structs.EvalStatusComplete) // Verify the network did not change - rp := structs.Port{"main", 5000} + rp := structs.Port{Label: "main", Value: 5000} for _, alloc := range out { for _, resources := range alloc.TaskResources { if resources.Networks[0].ReservedPorts[0] != rp { diff --git a/scheduler/system_sched_test.go b/scheduler/system_sched_test.go index fae5f322a..cd5fa77a0 100644 --- a/scheduler/system_sched_test.go +++ b/scheduler/system_sched_test.go @@ -468,7 +468,7 @@ func TestSystemSched_JobModify_InPlace(t *testing.T) { h.AssertEvalStatus(t, structs.EvalStatusComplete) // Verify the network did not change - rp := structs.Port{"main", 5000} + rp := structs.Port{Label: "main", Value: 5000} for _, alloc := range out { for _, resources := range alloc.TaskResources { if resources.Networks[0].ReservedPorts[0] != rp {