Authored by fanzelei

Merge branch 'master' of http://git.yoho.cn/ops/monitor-service

... ... @@ -19,7 +19,8 @@ public class ScheduledPlan {
JavaApiClient javaApiClient;
// @Scheduled(fixedRate=10000000)
//TODO config prop
@Scheduled(fixedRate = 180000)
public void run() {
log.info("task start...");
... ...
... ... @@ -47,7 +47,7 @@ public class JavaApiClient {
private List<IJavaApiHadnler> javaApiHadnlerList;
//TODO 需要 线程安全 处理
//TODO 需要 线程安全 处理 不过一般不会出现并发,任务周期比较长,一般周期内任务能够完成
private Map<String, JavaApiInfo> javaApimap;
private MultiValueMap<Integer, MObjectInfo> mObjInfoMap;
... ... @@ -56,9 +56,6 @@ public class JavaApiClient {
private CompletionService<JavaApiStatics> completionService;
private long startTime;
private long endTime;
public void initClient() {
executorService = new ThreadPoolExecutor(10, 30, 60, TimeUnit.SECONDS, new LinkedBlockingDeque<>(),
... ... @@ -88,7 +85,7 @@ public class JavaApiClient {
public void run() {
startTime = System.currentTimeMillis();
long startTime = System.currentTimeMillis();
int tastNum = 0;
for (JavaApiInfo javaApiInfo : javaApimap.values()) {
... ... @@ -117,7 +114,7 @@ public class JavaApiClient {
//close 线程池
executorService.shutdownNow();
endTime = System.currentTimeMillis();
long endTime = System.currentTimeMillis();
}
... ...