修改超时时间
parent
51895373cf
commit
af5c50cd89
|
@ -106,6 +106,11 @@
|
|||
<artifactId>cloud-common-etl</artifactId>
|
||||
<version>1.0.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>cloud-rule-client</artifactId>
|
||||
<version>1.0.0</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
|
|
@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.client.basic.RuleConfig;
|
||||
import com.muyu.client.mysql.MySqlDataSource;
|
||||
import com.muyu.client.mysql.MySqlQuery;
|
||||
import com.muyu.common.core.domain.Result;
|
||||
|
@ -366,7 +367,7 @@ public class TaskInfoServiceImpl extends ServiceImpl<TaskInfoMapper, TaskInfo> i
|
|||
private NodeRuleService nodeRuleService;
|
||||
|
||||
@Autowired
|
||||
private RuleFeign ruleFeign;
|
||||
private RuleConfig ruleConfig;
|
||||
|
||||
/**
|
||||
* 存放实例化引擎的容器
|
||||
|
@ -393,7 +394,7 @@ public class TaskInfoServiceImpl extends ServiceImpl<TaskInfoMapper, TaskInfo> i
|
|||
Future<DataValue[][]> currentFuture = executor.submit(tasks.poll());
|
||||
if (!CollectionUtils.isEmpty(list)) {
|
||||
for (NodeRule nodeRule : list) {
|
||||
Result<RuleEngineVersion> result = ruleFeign.findVersionById(nodeRule.getRuleId());
|
||||
Result<RuleEngineVersion> result = ruleConfig.findVersionById(nodeRule.getRuleId());
|
||||
RuleEngineVersion data = result.getData();
|
||||
final Future<DataValue[][]> finalCurrentFuture = currentFuture;
|
||||
log.info(finalCurrentFuture);
|
||||
|
@ -409,7 +410,7 @@ public class TaskInfoServiceImpl extends ServiceImpl<TaskInfoMapper, TaskInfo> i
|
|||
//log.info(value.getValue());
|
||||
try {
|
||||
//DataValue dataValue = loadEngineClass.testEngine(data.getClassName(), value);
|
||||
ruleFeign.testEngine(data.getClassName(),value);
|
||||
ruleConfig.testEngine(data.getClassName(),value);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage());
|
||||
}
|
||||
|
|
|
@ -11,15 +11,15 @@ public class OptimizedPrioritizedThreadPool {
|
|||
private static final Semaphore lowPrioritySemaphore;
|
||||
private static final Semaphore emergencySemaphore;
|
||||
|
||||
private static final int totalThreads =20; // 固定线程池大小
|
||||
private static final int defaultHighThreads = 10;
|
||||
private static final int defaultMediumThreads = 6;
|
||||
private static final int defaultLowThreads = 4;
|
||||
private static final int totalThreads =25; // 固定线程池大小
|
||||
private static final int defaultHighThreads = 12;
|
||||
private static final int defaultMediumThreads = 8;
|
||||
private static final int defaultLowThreads = 5;
|
||||
|
||||
private static final int emergencyThreads = 9;
|
||||
private static final int emergencyHighThreads = 3;
|
||||
private static final int emergencyMediumThreads = 3;
|
||||
private static final int emergencyLowThreads = 3;
|
||||
private static final int emergencyThreads = 12;
|
||||
private static final int emergencyHighThreads = 4;
|
||||
private static final int emergencyMediumThreads = 4;
|
||||
private static final int emergencyLowThreads = 4;
|
||||
|
||||
private static volatile boolean inEmergencyMode = false;
|
||||
public static final AtomicInteger activeEmergencyTasks = new AtomicInteger(0); // 紧急任务计数器
|
||||
|
|
Loading…
Reference in New Issue