This is an automated email from the ASF dual-hosted git repository.
zhongjiajie pushed a commit to branch 2.0.7-prepare
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git
The following commit(s) were added to refs/heads/2.0.7-prepare by this push:
new ab57ad6c59 [bugfix-10116]fix complement data bug (#12376)
ab57ad6c59 is described below
commit ab57ad6c59e5f684d45600b6acc2bb066498d2b7
Author: JinYong Li <[email protected]>
AuthorDate: Fri Oct 14 13:49:07 2022 +0800
[bugfix-10116]fix complement data bug (#12376)
---
.../dolphinscheduler/spi/task/paramparser/BusinessTimeUtils.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git
a/dolphinscheduler-spi/src/main/java/org/apache/dolphinscheduler/spi/task/paramparser/BusinessTimeUtils.java
b/dolphinscheduler-spi/src/main/java/org/apache/dolphinscheduler/spi/task/paramparser/BusinessTimeUtils.java
index b35598d42e..56ee124866 100644
---
a/dolphinscheduler-spi/src/main/java/org/apache/dolphinscheduler/spi/task/paramparser/BusinessTimeUtils.java
+++
b/dolphinscheduler-spi/src/main/java/org/apache/dolphinscheduler/spi/task/paramparser/BusinessTimeUtils.java
@@ -26,6 +26,7 @@ import static
org.apache.dolphinscheduler.spi.utils.DateUtils.addDays;
import static org.apache.dolphinscheduler.spi.utils.DateUtils.format;
import org.apache.dolphinscheduler.spi.enums.CommandType;
+import org.apache.dolphinscheduler.spi.utils.DateUtils;
import java.util.Date;
import java.util.HashMap;
@@ -47,9 +48,10 @@ public class BusinessTimeUtils {
* @return business time
*/
public static Map<String, String> getBusinessTime(CommandType commandType,
Date runTime) {
- Date businessDate = runTime;
+ Date businessDate;
switch (commandType) {
case COMPLEMENT_DATA:
+ businessDate = DateUtils.addDays(runTime, -1);
break;
case START_PROCESS:
case START_CURRENT_TASK_PROCESS: