You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by zh...@apache.org on 2022/04/22 06:10:27 UTC
[dolphinscheduler] branch dev updated: [Improvement][server] varPool support syntax #{setValue(key=value)} (#9586)
This is an automated email from the ASF dual-hosted git repository.
zhongjiajie pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git
The following commit(s) were added to refs/heads/dev by this push:
new 36f01155b5 [Improvement][server] varPool support syntax #{setValue(key=value)} (#9586)
36f01155b5 is described below
commit 36f01155b5c528cd7551c0d79662ba62b3de1677
Author: exmy <xu...@gmail.com>
AuthorDate: Fri Apr 22 14:10:21 2022 +0800
[Improvement][server] varPool support syntax #{setValue(key=value)} (#9586)
---
.../dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java | 2 +-
.../java/org/apache/dolphinscheduler/plugin/task/api/TaskConstants.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java b/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java
index 340053844a..e5e85a4332 100644
--- a/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java
+++ b/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/AbstractCommandExecutor.java
@@ -318,7 +318,7 @@ public abstract class AbstractCommandExecutor {
try (BufferedReader inReader = new BufferedReader(new InputStreamReader(process.getInputStream()))) {
String line;
while ((line = inReader.readLine()) != null) {
- if (line.startsWith("${setValue(")) {
+ if (line.startsWith("${setValue(") || line.startsWith("#{setValue(")) {
varPool.append(findVarPool(line));
varPool.append("$VarPool$");
} else {
diff --git a/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/TaskConstants.java b/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/TaskConstants.java
index 209be57e71..bb00b6257b 100644
--- a/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/TaskConstants.java
+++ b/dolphinscheduler-task-plugin/dolphinscheduler-task-api/src/main/java/org/apache/dolphinscheduler/plugin/task/api/TaskConstants.java
@@ -28,7 +28,7 @@ public class TaskConstants {
public static final String APPLICATION_REGEX = "application_\\d+_\\d+";
- public static final String SETVALUE_REGEX = "\\$\\{setValue\\(([^)]*)\\)}";
+ public static final String SETVALUE_REGEX = "[\\$#]\\{setValue\\(([^)]*)\\)}";
/**
* string false