use of org.apache.flink.kubernetes.kubeclient.resources.KubernetesWatch in project flink by apache.
the class KubernetesResourceManagerDriver method terminate.
@Override
public void terminate() throws Exception {
if (!running) {
return;
}
running = false;
// shut down all components
Exception exception = null;
try {
podsWatchOpt.ifPresent(KubernetesWatch::close);
} catch (Exception e) {
exception = e;
}
try {
flinkKubeClient.close();
} catch (Exception e) {
exception = ExceptionUtils.firstOrSuppressed(e, exception);
}
if (exception != null) {
throw exception;
}
}
Aggregations