This is an automated email from the ASF dual-hosted git repository.
benjobs pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-streampark.git
The following commit(s) were added to refs/heads/dev by this push:
new 7b45e1f86 [bug]Fix the strong stop logic (#1864)
7b45e1f86 is described below
commit 7b45e1f86f9d3f3a9582b16b9b2e2b9caeeb1d57
Author: monster <[email protected]>
AuthorDate: Tue Oct 18 22:07:28 2022 +0800
[bug]Fix the strong stop logic (#1864)
* [bug]Fix the strong stop logic
* Update docker-compose.yaml
---
deploy/docker/docker-compose.yaml | 2 +-
.../console/core/service/impl/ApplicationServiceImpl.java | 13 +++++++------
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/deploy/docker/docker-compose.yaml
b/deploy/docker/docker-compose.yaml
index 5de0c1f4e..53c5ebb63 100644
--- a/deploy/docker/docker-compose.yaml
+++ b/deploy/docker/docker-compose.yaml
@@ -17,7 +17,7 @@
version: '3.8'
services:
streampark-server:
- image: ${HUB}/streampark:${TAG}
+ image: ${HUB}:${TAG}
command: ${COMMAND}
ports:
- 10000:10000
diff --git
a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/service/impl/ApplicationServiceImpl.java
b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/service/impl/ApplicationServiceImpl.java
index febe1e1b3..8fc9cea5f 100644
---
a/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/service/impl/ApplicationServiceImpl.java
+++
b/streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/core/service/impl/ApplicationServiceImpl.java
@@ -906,6 +906,13 @@ public class ApplicationServiceImpl extends
ServiceImpl<ApplicationMapper, Appli
public void forcedStop(Application app) {
CompletableFuture<SubmitResponse> startFuture =
startFutureMap.remove(app.getId());
CompletableFuture<CancelResponse> cancelFuture =
cancelFutureMap.remove(app.getId());
+ Application application = this.baseMapper.getApp(app);
+ if (isKubernetesApp(application)) {
+
KubernetesDeploymentHelper.watchPodTerminatedLog(application.getK8sNamespace(),
application.getJobName());
+
KubernetesDeploymentHelper.deleteTaskDeployment(application.getK8sNamespace(),
application.getJobName());
+
KubernetesDeploymentHelper.deleteTaskConfigMap(application.getK8sNamespace(),
application.getJobName());
+ IngressController.deleteIngress(application.getK8sNamespace(),
application.getJobName());
+ }
if (startFuture != null) {
startFuture.cancel(true);
}
@@ -915,12 +922,6 @@ public class ApplicationServiceImpl extends
ServiceImpl<ApplicationMapper, Appli
if (startFuture == null && cancelFuture == null) {
this.updateToStopped(app);
}
- if (isKubernetesApp(app)) {
-
KubernetesDeploymentHelper.watchPodTerminatedLog(app.getK8sNamespace(),
app.getJobName());
-
KubernetesDeploymentHelper.deleteTaskDeployment(app.getK8sNamespace(),
app.getJobName());
-
KubernetesDeploymentHelper.deleteTaskConfigMap(app.getK8sNamespace(),
app.getJobName());
- IngressController.deleteIngress(app.getK8sNamespace(),
app.getJobName());
- }
}