You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
788 B
35 lines
788 B
package com.bfd.assemble.cache;
|
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
|
import java.util.Map;
|
|
import java.util.concurrent.LinkedBlockingDeque;
|
|
|
|
/**
|
|
* @author jian.mao
|
|
* @date 2022年11月11日
|
|
* @description 静态变量类
|
|
*/
|
|
@Slf4j
|
|
public class ConfigCache {
|
|
|
|
/**启动条件**/
|
|
public static boolean isStart = true;
|
|
/*****任务队列*****/
|
|
public static LinkedBlockingDeque<Map<String, Object>> taskQueue = new LinkedBlockingDeque<Map<String,Object>>();
|
|
|
|
|
|
/**
|
|
* 队列录入任务
|
|
* @param queue
|
|
* @param task
|
|
*/
|
|
public static void putQueue(LinkedBlockingDeque<Map<String, Object>> queue,Map<String, Object> task){
|
|
//next app 写入队列准备调出
|
|
try {
|
|
queue.put(task);
|
|
} catch (InterruptedException e) {
|
|
log.error("队列写入data失败---");
|
|
}
|
|
}
|
|
}
|