Skip to content

Commit

Permalink
Remove PodSchedulingFailure condition instead of setting to false
Browse files Browse the repository at this point in the history
  • Loading branch information
nikita-vanyasin committed Aug 4, 2023
1 parent 0453352 commit 050d84a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
- (Maintenance) Bump K8S Version to 1.25.12
- (Maintenance) Bump Go to 1.20.7
- (Improvement) Restart pod if it could not be scheduled and related scheduling parameters changed
- (Improvement) Remove PodSchedulingFailure condition instead of setting to false

## [1.2.31](https://github.com/arangodb/kube-arangodb/tree/1.2.31) (2023-07-14)
- (Improvement) Block traffic on the services if there is more than 1 active leader in ActiveFailover mode
Expand Down
4 changes: 1 addition & 3 deletions pkg/deployment/resources/pod_inspector.go
Original file line number Diff line number Diff line change
Expand Up @@ -527,9 +527,7 @@ func (r *Resources) InspectPods(ctx context.Context, cachedStatus inspectorInter
}
} else if status.Conditions.IsTrue(api.ConditionTypePodSchedulingFailure) &&
len(unscheduledPodNames) == 0 {
if status.Conditions.Update(api.ConditionTypePodSchedulingFailure, false,
"Pods Scheduling Resolved",
"No pod reports a scheduling timeout") {
if status.Conditions.Remove(api.ConditionTypePodSchedulingFailure) {
r.context.CreateEvent(k8sutil.NewPodsSchedulingResolvedEvent(r.context.GetAPIObject()))
}
}
Expand Down

0 comments on commit 050d84a

Please sign in to comment.