You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by GitBox <gi...@apache.org> on 2022/04/07 02:04:46 UTC

[GitHub] [incubator-inlong] healchow commented on a diff in pull request #3554: [INLONG-3538][Manager] Adjust mode of getting sort URL

healchow commented on code in PR #3554:
URL: https://github.com/apache/incubator-inlong/pull/3554#discussion_r844570744


##########
inlong-manager/manager-plugins/src/main/java/org/apache/inlong/manager/plugin/flink/IntergrationTaskRunner.java:
##########
@@ -172,6 +172,12 @@ public void run() {
                         flinkInfo.setSavepointPath(savepointPath);
                         log.info("the jobId :{} status: {} ", flinkInfo.getJobId(),status);
                     }
+                    JobStatus jobStatus = flinkService.getJobStatus(flinkInfo.getJobId());
+                    if (jobStatus.isTerminalState()) {
+                        log.info("stop  job : {} status : {} ,success in backend", flinkInfo.getJobId(),jobStatus);

Review Comment:
   Change the log info to `log.info("stop job {}, status: {}, success in backend", flinkInfo.getJobId(), jobStatus);`



##########
inlong-manager/manager-plugins/src/main/java/org/apache/inlong/manager/plugin/flink/FlinkService.java:
##########
@@ -63,16 +70,41 @@
     private final Integer parallelism;
     private final String savepointDirectory;
 
-    public FlinkService() throws IOException {
+    public FlinkService(String endpoint) throws IOException {
         FlinkConfiguration flinkConfiguration = new FlinkConfiguration();
         flinkConfig = flinkConfiguration.getFlinkConfig();
-        address = flinkConfig.getAddress();
-        port = flinkConfig.getPort();
         jobManagerPort = flinkConfig.getJobManagerPort();
         parallelism = flinkConfig.getParallelism();
         savepointDirectory = flinkConfig.getSavepointDirectory();
+        if (endpoint.length() == 0) {

Review Comment:
   Use `StringUtils.isEmpty()` to check the string variable.



-- 
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: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org