You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2022/05/19 08:25:09 UTC

[GitHub] [dolphinscheduler] Amy0104 commented on a diff in pull request #9577: [feature][task-flink] Support Flink application mode

Amy0104 commented on code in PR #9577:
URL: https://github.com/apache/dolphinscheduler/pull/9577#discussion_r876757962


##########
dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-flink.ts:
##########
@@ -36,14 +36,51 @@ export function useFlink(model: { [field: string]: any }): IJsonItem[] {
   )
 
   const taskManagerNumberSpan = computed(() =>
-    model.flinkVersion === '<1.10' && model.deployMode === 'cluster' ? 12 : 0
+    model.flinkVersion === '<1.10' && model.deployMode !== 'local' ? 12 : 0
   )
 
   const deployModeSpan = computed(() =>
-    model.deployMode === 'cluster' ? 12 : 0
+    model.deployMode !== 'local' ? 12 : 0
   )
 
-  const appNameSpan = computed(() => (model.deployMode === 'cluster' ? 24 : 0))
+  const appNameSpan = computed(() => (model.deployMode !== 'local' ? 24 : 0))
+
+  const deployModeOptions = computed(() => {
+    if (model.flinkVersion === '<1.10') {
+      return [
+        {
+          label: 'cluster',
+          value: 'cluster'
+        },
+        {
+          label: 'local',
+          value: 'local'
+        }
+      ];
+    } else {
+      return [
+        {
+          label: 'per-job/cluster',
+          value: 'cluster'
+        },
+        {
+          label: 'application',
+          value: 'application'
+        },
+        {
+          label: 'local',
+          value: 'local'
+        }
+      ];
+    }
+  })
+
+  watch(
+    () => model.flinkVersion,
+    () => {
+      model.deployMode = 'cluster'
+    }
+  )

Review Comment:
   There will be a bug here after setting deployMode to application and flinkVersion to 1.11.



-- 
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@dolphinscheduler.apache.org

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