You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by le...@apache.org on 2021/10/20 16:20:18 UTC

[dolphinscheduler] branch 2.0.0-alpha-release updated (a729c82 -> c53e21b)

This is an automated email from the ASF dual-hosted git repository.

leonbao pushed a change to branch 2.0.0-alpha-release
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git.


    from a729c82  [maven-release-plugin] prepare for next development iteration
     new 986f813  fix import processDefinition error (#6573)
     new 257b76c  fix switch node cannot get branch flow (#6565)
     new c53e21b  fix import process definition url error (#6567)

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../apache/dolphinscheduler/api/dto/DagDataSchedule.java    |  3 +++
 .../js/conf/home/pages/dag/_source/formModel/formModel.vue  | 13 ++++++++++---
 .../conf/home/pages/dag/_source/formModel/tasks/switch.vue  | 10 +++++-----
 .../js/module/components/fileUpdate/definitionUpdate.vue    |  4 ++--
 4 files changed, 20 insertions(+), 10 deletions(-)

[dolphinscheduler] 02/03: fix switch node cannot get branch flow (#6565)

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leonbao pushed a commit to branch 2.0.0-alpha-release
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git

commit 257b76cccfacf018647a1d69da4cd31fe7cd93f6
Author: wangyizhi <wa...@cmss.chinamobile.com>
AuthorDate: Wed Oct 20 16:55:38 2021 +0800

    fix switch node cannot get branch flow (#6565)
---
 .../js/conf/home/pages/dag/_source/formModel/formModel.vue  | 13 ++++++++++---
 .../conf/home/pages/dag/_source/formModel/tasks/switch.vue  | 10 +++++-----
 2 files changed, 15 insertions(+), 8 deletions(-)

diff --git a/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/formModel.vue b/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/formModel.vue
index 06f7fe6..1dcb81c 100644
--- a/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/formModel.vue
+++ b/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/formModel.vue
@@ -383,6 +383,7 @@
             @on-switch-result="_onSwitchResult"
             :backfill-item="backfillItem"
             :nodeData="nodeData"
+            :postTasks="postTasks"
           ></m-switch>
           <!-- waterdrop node -->
           <m-waterdrop
@@ -517,7 +518,7 @@
             label: `${i18n.$t('Failed')}`
           }
         ],
-        // for CONDITIONS
+        // for CONDITIONS and SWITCH
         postTasks: [],
         prevTasks: [],
         // refresh part of the formModel, after set backfillItem outside
@@ -550,6 +551,7 @@
         return {
           code: task.code,
           conditionResult: task.taskParams.conditionResult,
+          switchResult: task.taskParams.switchResult,
           delayTime: task.delayTime,
           dependence: task.taskParams.dependence,
           desc: task.description,
@@ -559,7 +561,8 @@
           params: _.omit(task.taskParams, [
             'conditionResult',
             'dependence',
-            'waitStartTimeout'
+            'waitStartTimeout',
+            'switchResult'
           ]),
           retryInterval: task.failRetryInterval,
           runFlag: task.flag,
@@ -770,7 +773,8 @@
               ...this.params,
               dependence: this.cacheDependence,
               conditionResult: this.conditionResult,
-              waitStartTimeout: this.waitStartTimeout
+              waitStartTimeout: this.waitStartTimeout,
+              switchResult: this.switchResult
             },
             flag: this.runFlag,
             taskPriority: this.taskInstancePriority,
@@ -868,6 +872,9 @@
             this.successBranch = o.conditionResult.successNode[0]
             this.failedBranch = o.conditionResult.failedNode[0]
           }
+          if (o.switchResult) {
+            this.switchResult = o.switchResult
+          }
           // If the workergroup has been deleted, set the default workergroup
           for (
             let i = 0;
diff --git a/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/switch.vue b/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/switch.vue
index 8475193..d003405 100644
--- a/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/switch.vue
+++ b/dolphinscheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/switch.vue
@@ -34,8 +34,8 @@
               </textarea>
             </label>
             <span class="text-b" style="padding-left: 0">{{$t('Branch flow')}}</span>
-            <el-select style="width: 157px;" size="small" v-model="el.nextNode" clearable>
-              <el-option v-for="item in nodeData.rearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
+            <el-select style="width: 157px;" size="small" v-model="el.nextNode" clearable :disabled="isDetails">
+              <el-option v-for="item in postTasks" :key="item.code" :value="item.name" :label="item.name"></el-option>
             </el-select>
             <span class="operation">
               <a href="javascript:" class="delete" @click="!isDetails && _removeDep(index)" v-if="index === (dependItemList.length - 1)">
@@ -53,7 +53,7 @@
       <div slot="text">{{$t('Branch flow')}}</div>
       <div slot="content">
         <el-select style="width: 157px;" size="small" v-model="nextNode" clearable :disabled="isDetails">
-          <el-option v-for="item in nodeData.rearList" :key="item.value" :value="item.value" :label="item.label"></el-option>
+          <el-option v-for="item in postTasks" :key="item.code" :value="item.name" :label="item.name"></el-option>
         </el-select>
       </div>
     </m-list-box>
@@ -82,7 +82,7 @@
     props: {
       nodeData: Object,
       backfillItem: Object,
-      rearList: Array
+      postTasks: Array
     },
     methods: {
       editList (index) {
@@ -90,7 +90,7 @@
         const self = this
         const editor = codemirror(`code-switch-mirror${index}`, {
           mode: 'shell',
-          readOnly: this.isInstance
+          readOnly: this.isDetails
         }, this)
         editor.on('change', function () {
           const outputList = _.cloneDeep(self.dependItemList)

[dolphinscheduler] 03/03: fix import process definition url error (#6567)

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leonbao pushed a commit to branch 2.0.0-alpha-release
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git

commit c53e21b9810a225f434214be9cb304e22be9b41c
Author: wangyizhi <wa...@cmss.chinamobile.com>
AuthorDate: Wed Oct 20 18:58:23 2021 +0800

    fix import process definition url error (#6567)
---
 .../src/js/module/components/fileUpdate/definitionUpdate.vue          | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dolphinscheduler-ui/src/js/module/components/fileUpdate/definitionUpdate.vue b/dolphinscheduler-ui/src/js/module/components/fileUpdate/definitionUpdate.vue
index 6c34c8e..b8b768b 100644
--- a/dolphinscheduler-ui/src/js/module/components/fileUpdate/definitionUpdate.vue
+++ b/dolphinscheduler-ui/src/js/module/components/fileUpdate/definitionUpdate.vue
@@ -137,9 +137,9 @@
         return new Promise((resolve, reject) => {
           let self = this
           let formData = new FormData()
+          const projectCode = this.store.state.dag.projectCode
           formData.append('file', this.file)
-          formData.append('projectName', this.store.state.dag.projectName)
-          io.post('projects/import-definition', res => {
+          io.post(`projects/${projectCode}/process-definition/import`, res => {
             this.$message.success(res.msg)
             resolve()
             self.$emit('onUpdateDefinition')

[dolphinscheduler] 01/03: fix import processDefinition error (#6573)

Posted by le...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

leonbao pushed a commit to branch 2.0.0-alpha-release
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git

commit 986f81381deb51acc95ca67c38726390ca73d464
Author: JinYong Li <42...@users.noreply.github.com>
AuthorDate: Wed Oct 20 23:45:38 2021 +0800

    fix import processDefinition error (#6573)
---
 .../main/java/org/apache/dolphinscheduler/api/dto/DagDataSchedule.java | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/dto/DagDataSchedule.java b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/dto/DagDataSchedule.java
index 249d8b3..d944ffb 100644
--- a/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/dto/DagDataSchedule.java
+++ b/dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/dto/DagDataSchedule.java
@@ -30,6 +30,9 @@ public class DagDataSchedule extends DagData {
      */
     private Schedule schedule;
 
+    public DagDataSchedule() {
+    }
+
     public DagDataSchedule(DagData dagData) {
         super();
         this.setProcessDefinition(dagData.getProcessDefinition());