dongjoon-hyun commented on code in PR #867:
URL: 
https://github.com/apache/spark-kubernetes-operator/pull/867#discussion_r4080223999


##########
spark-operator/src/main/java/org/apache/spark/k8s/operator/reconciler/observers/BaseAppDriverObserver.java:
##########
@@ -101,6 +99,11 @@ protected Optional<ApplicationState> 
observeDriverTermination(
       return Optional.of(new ApplicationState(Succeeded, 
DRIVER_COMPLETED_MESSAGE));
     }
 
+    if (status.getContainerStatuses() == null || 
status.getContainerStatuses().isEmpty()) {

Review Comment:
   Thank you. I added five tests with a `Running` driver pod to cover the 
init-container failure, the terminated driver container (non-zero and zero 
exit), the restarted driver container, and a running driver container. With the 
three branches deleted, the four branch tests fail.
   
   A default `ApplicationSpec` is enough here because 
`findDriverMainContainerStatus` returns all container statuses when the driver 
container name is not configured.



-- 
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]

Reply via email to