Преглед на файлове

[Improvement] Add Flink job name (#4285)

* [Improvement] Add Flink job name

* fix typo
zh0122 преди 4 години
родител
ревизия
140679e337

+ 22 - 0
dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/flink.vue

@@ -81,6 +81,19 @@
       </div>
     </m-list-box>
     <div class="list-box-4p" v-if="deployMode === 'cluster'">
+      <div class="clearfix list">
+        <span class="sp1" style="word-break:break-all">{{$t('appName')}}</span>
+        <span class="sp2">
+          <el-input
+            :disabled="isDetails"
+            type="input"
+            size="small"
+            v-model="appName"
+            :placeholder="$t('Please enter the job name of Flink')"
+            style="width: 200px;">
+        </el-input>
+        </span>
+      </div>
       <div class="clearfix list">
         <span class="sp1" style="word-break:break-all">{{$t('jobManagerMemory')}}</span>
         <span class="sp2">
@@ -216,6 +229,8 @@
         jobManagerMemory: '1G',
         // taskManager Memory
         taskManagerMemory: '2G',
+        // Flink Job Name
+        appName: '',
         // Command line argument
         mainArgs: '',
         // Other parameters
@@ -288,6 +303,11 @@
           return false
         }
 
+        if (!this.appName) {
+          this.$message.warning(`${i18n.$t('Please enter the job name of Flink')}`)
+          return false
+        }
+
         if (!this.jobManagerMemory) {
           this.$message.warning(`${i18n.$t('Please enter jobManager memory')}`)
           return false
@@ -333,6 +353,7 @@
           flinkVersion: this.flinkVersion,
           slot: this.slot,
           taskManager: this.taskManager,
+          appName: this.appName,
           jobManagerMemory: this.jobManagerMemory,
           taskManagerMemory: this.taskManagerMemory,
           mainArgs: this.mainArgs,
@@ -468,6 +489,7 @@
           localParams: this.localParams,
           slot: this.slot,
           taskManager: this.taskManager,
+          appName: this.appName,
           jobManagerMemory: this.jobManagerMemory,
           taskManagerMemory: this.taskManagerMemory,
           mainArgs: this.mainArgs,

+ 2 - 0
dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js

@@ -108,6 +108,7 @@ export default {
   'Driver memory use': 'Driver memory use',
   'Please enter driver memory use': 'Please enter driver memory use',
   'Number of Executors': 'Number of Executors',
+  'Please enter the job name of Flink': 'Please enter the job name of Flink',
   'Please enter the number of Executor': 'Please enter the number of Executor',
   'Executor memory': 'Executor memory',
   'Please enter the Executor memory': 'Please enter the Executor memory',
@@ -339,6 +340,7 @@ export default {
   'Complement Data': 'Complement Data',
   slot: 'slot',
   taskManager: 'taskManager',
+  appName: 'Flink job name',
   jobManagerMemory: 'jobManagerMemory',
   taskManagerMemory: 'taskManagerMemory',
   'Scheduling execution': 'Scheduling execution',

+ 2 - 0
dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js

@@ -106,6 +106,7 @@ export default {
   'Driver memory use': 'Driver内存数',
   'Please enter driver memory use': '请输入Driver内存数',
   'Number of Executors': 'Executor数量',
+  'Please enter the job name of Flink': '请输入Flink任务名称',
   'Please enter the number of Executor': '请输入Executor数量',
   'Executor memory': 'Executor内存数',
   'Please enter the Executor memory': '请输入Executor内存数',
@@ -538,6 +539,7 @@ export default {
   'Complement range': '补数范围',
   slot: 'slot数量',
   taskManager: 'taskManager数量',
+  appName: 'Flink任务名称',
   jobManagerMemory: 'jobManager内存数',
   taskManagerMemory: 'taskManager内存数',
   'Http Url': '请求地址',