TQJADE commented on code in PR #909:
URL:
https://github.com/apache/spark-kubernetes-operator/pull/909#discussion_r4160526963
##########
docs/spark_custom_resources.md:
##########
@@ -544,7 +544,12 @@ published when enabled. Since the status is not there to
fall back on, it is rep
minutes by default while the hold lasts, so that it outlives the event
retention of the API
server. An application held later, in `ScheduledToRestart`, keeps the status
its previous attempt
already wrote and gets the same event, since that status says that a restart
is due, not that the
-next attempt is withheld.
+next attempt is withheld. If the driver (or master) cannot be read to check
whether it was requested
+already, e.g. since the API server rejects the read, the resource is neither
held nor started, and
+the `SuspendCheckFailed` event is published instead, until the check succeeds.
A failure which may
Review Comment:
updated
##########
spark-operator/src/main/java/org/apache/spark/k8s/operator/reconciler/reconcilesteps/ClusterInitStep.java:
##########
@@ -68,27 +68,30 @@ public ReconcileProgress reconcile(
return proceed();
}
SparkCluster cluster = context.getResource();
- // A cluster whose master StatefulSet already exists has been requested
before (e.g. the status
- // update to RunningHealthy failed), so let it complete its initialization
even if suspended.
+
+ boolean masterRequested = false;
if (cluster.getSpec().isSuspend()) {
- final boolean masterRequested;
+ // Unlike a first attempt, a cluster resumed from Suspended or queued
again after an eviction
+ // has persisted this Submitted state, which would keep saying that it
is resumed. It goes
+ // back to Suspended instead, where ClusterSuspendStep deletes the
master and worker
+ // StatefulSets by name and releases whatever it holds only after its
pods are gone. That
+ // happens whether or not the master was requested, so it is not looked
up.
Review Comment:
updated
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]