Skip to content

Commit

Permalink
Fix service status retrieval (#457)
Browse files Browse the repository at this point in the history
  • Loading branch information
olevitt authored Jul 15, 2024
1 parent 639126a commit dcbd64d
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ private static List<HealthCheckResult> checkHealth(
.get();
details.setDesired(deployment.getSpec().getReplicas());
details.setReady(deployment.getStatus().getReadyReplicas());
break;
case "StatefulSet":
StatefulSet statefulset =
kubernetesClient
Expand All @@ -65,6 +66,7 @@ private static List<HealthCheckResult> checkHealth(
.get();
details.setDesired(statefulset.getSpec().getReplicas());
details.setReady(statefulset.getStatus().getReadyReplicas());
break;
case "DaemonSet":
DaemonSet daemonSet =
kubernetesClient
Expand All @@ -75,6 +77,7 @@ private static List<HealthCheckResult> checkHealth(
.get();
details.setDesired(daemonSet.getStatus().getDesiredNumberScheduled());
details.setReady(daemonSet.getStatus().getNumberReady());
break;
default:
continue;
}
Expand Down

0 comments on commit dcbd64d

Please sign in to comment.