查看结果应用
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

6 months ago
  1. package com.bfd.assemble.cache;
  2. import lombok.extern.slf4j.Slf4j;
  3. import java.util.Map;
  4. import java.util.concurrent.LinkedBlockingDeque;
  5. /**
  6. * @author jian.mao
  7. * @date 2022年11月11日
  8. * @description 静态变量类
  9. */
  10. @Slf4j
  11. public class ConfigCache {
  12. /**启动条件**/
  13. public static boolean isStart = true;
  14. /*****任务队列*****/
  15. public static LinkedBlockingDeque<Map<String, Object>> taskQueue = new LinkedBlockingDeque<Map<String,Object>>();
  16. /**
  17. * 队列录入任务
  18. * @param queue
  19. * @param task
  20. */
  21. public static void putQueue(LinkedBlockingDeque<Map<String, Object>> queue,Map<String, Object> task){
  22. //next app 写入队列准备调出
  23. try {
  24. queue.put(task);
  25. } catch (InterruptedException e) {
  26. log.error("队列写入data失败---");
  27. }
  28. }
  29. }