feat(dev_1.1.0):
1、任务批次列表新增任务类型返回值 2、Reduce阶段新增参数结果集
This commit is contained in:
parent
6f37691be1
commit
ffdc3d9dc2
@ -9,11 +9,11 @@ import lombok.Data;
|
||||
* @date : 2024-06-12 13:59
|
||||
*/
|
||||
@Data
|
||||
public class MrTaskResult {
|
||||
public class MapArgs {
|
||||
|
||||
private String taskId;
|
||||
private String mapName;
|
||||
|
||||
private boolean success;
|
||||
private Boolean success;
|
||||
|
||||
private String result;
|
||||
}
|
@ -3,6 +3,8 @@ package com.aizuda.snailjob.client.job.core.dto;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author: opensnail
|
||||
* @date : 2024-06-13
|
||||
@ -13,4 +15,6 @@ import lombok.EqualsAndHashCode;
|
||||
public class MapReduceArgs extends JobArgs {
|
||||
|
||||
private String mapName;
|
||||
|
||||
private List<MapArgs> mapArgsList;
|
||||
}
|
||||
|
@ -11,7 +11,6 @@ import com.aizuda.snailjob.client.model.request.MapTaskRequest;
|
||||
import com.aizuda.snailjob.common.core.constant.SystemConstants;
|
||||
import com.aizuda.snailjob.common.core.exception.SnailJobMapReduceException;
|
||||
import com.aizuda.snailjob.common.core.model.JobContext;
|
||||
import com.aizuda.snailjob.common.core.model.MapContext;
|
||||
import com.aizuda.snailjob.common.core.model.NettyResult;
|
||||
import com.aizuda.snailjob.common.core.model.Result;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@ -35,7 +34,7 @@ public abstract class AbstractMapExecutor extends AbstractJobExecutor implements
|
||||
@Override
|
||||
protected ExecuteResult doJobExecute(final JobArgs jobArgs) {
|
||||
MapReduceArgs mapReduceArgs = (MapReduceArgs) jobArgs;
|
||||
return doJobExecute(mapReduceArgs);
|
||||
return this.doJobExecute(mapReduceArgs);
|
||||
}
|
||||
|
||||
public abstract ExecuteResult doJobExecute(MapReduceArgs mapReduceArgs);
|
||||
|
@ -1,9 +1,11 @@
|
||||
package com.aizuda.snailjob.client.job.core.executor;
|
||||
|
||||
import com.aizuda.snailjob.client.job.core.dto.JobArgs;
|
||||
import com.aizuda.snailjob.client.job.core.dto.MapArgs;
|
||||
import com.aizuda.snailjob.client.model.ExecuteResult;
|
||||
import com.aizuda.snailjob.common.core.model.JobContext;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author zhengweilin
|
||||
* @version 1.0.0
|
||||
@ -11,5 +13,5 @@ import com.aizuda.snailjob.common.core.model.JobContext;
|
||||
*/
|
||||
public abstract class AbstractMapReduceExecutor extends AbstractMapExecutor {
|
||||
|
||||
protected abstract ExecuteResult doReduceExecute(JobContext jobContext, JobArgs jobArgs);
|
||||
protected abstract ExecuteResult doReduceExecute(JobContext jobContext, List<MapArgs> mapArgsList);
|
||||
}
|
||||
|
@ -26,6 +26,11 @@ public class JobBatchResponseVO {
|
||||
*/
|
||||
private String jobName;
|
||||
|
||||
/**
|
||||
* 任务类型
|
||||
*/
|
||||
private String taskType;
|
||||
|
||||
/**
|
||||
* 工作流节点名称
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user