SuccessChanges

Summary

  1. [SPARK-30821][K8S] Handle executor failure with multiple containers (details)
Commit f65952772702f0a8772c93b79f562f35c337f5a5 by hkarau
[SPARK-30821][K8S] Handle executor failure with multiple containers
Handle executor failure with multiple containers
Added a spark property spark.kubernetes.executor.checkAllContainers,
with default being false. When it's true, the executor snapshot will
take all containers in the executor into consideration when deciding
whether the executor is in "Running" state, if the pod restart policy is
"Never". Also, added the new spark property to the doc.
### What changes were proposed in this pull request?
Checking of all containers in the executor pod when reporting executor
status, if the `spark.kubernetes.executor.checkAllContainers` property
is set to true.
### Why are the changes needed?
Currently, a pod remains "running" as long as there is at least one
running container. This prevents Spark from noticing when a container
has failed in an executor pod with multiple containers. With this
change, user can configure the behavior to be different. Namely, if any
container in the executor pod has failed, either the executor process or
one of its sidecars, the pod is considered to be failed, and it will be
rescheduled.
### Does this PR introduce _any_ user-facing change?
Yes, new spark property added. User is now able to choose whether to
turn on this feature using the
`spark.kubernetes.executor.checkAllContainers` property.
### How was this patch tested?
Unit test was added and all passed. I tried to run integration test by
following the instruction
[here](https://spark.apache.org/developer-tools.html) (section "Testing
K8S") and also
[here](https://github.com/apache/spark/blob/master/resource-managers/kubernetes/integration-tests/README.md),
but I wasn't able to run it smoothly as it fails to talk with minikube
cluster. Maybe it's because my minikube version is too new (I'm using
v1.13.1)...? Since I've been trying it for two days and still can't make
it work, I decided to submit this PR and hopefully the Jenkins test will
pass.
Closes #29924 from huskysun/exec-sidecar-failure.
Authored-by: Shiqi Sun <s.sun@salesforce.com> Signed-off-by: Holden
Karau <hkarau@apple.com>
The file was modifiedresource-managers/kubernetes/core/src/main/scala/org/apache/spark/deploy/k8s/Config.scala (diff)
The file was modifiedresource-managers/kubernetes/core/src/test/scala/org/apache/spark/scheduler/cluster/k8s/DeterministicExecutorPodsSnapshotsStore.scala (diff)
The file was modifiedresource-managers/kubernetes/core/src/test/scala/org/apache/spark/scheduler/cluster/k8s/ExecutorPodsSnapshotSuite.scala (diff)
The file was modifiedresource-managers/kubernetes/core/src/main/scala/org/apache/spark/scheduler/cluster/k8s/KubernetesClusterManager.scala (diff)
The file was modifiedresource-managers/kubernetes/core/src/test/scala/org/apache/spark/scheduler/cluster/k8s/ExecutorPodsSnapshotsStoreSuite.scala (diff)
The file was modifieddocs/running-on-kubernetes.md (diff)
The file was modifiedresource-managers/kubernetes/core/src/main/scala/org/apache/spark/scheduler/cluster/k8s/ExecutorPodsSnapshot.scala (diff)
The file was modifiedresource-managers/kubernetes/core/src/test/scala/org/apache/spark/scheduler/cluster/k8s/ExecutorLifecycleTestUtils.scala (diff)