摘要: 工具类,抽象死循环逻辑的 import java.util.concurrent.atomic.AtomicBoolean; /** * if the process closes, a signal is placed as true, and all threads get this flag 阅读全文
posted @ 2020-09-02 10:52 SpecialSpeculator 阅读(245) 评论(0) 推荐(0) 编辑
摘要: TaskManager任务管理工具类 public class TaskManager { public static AbstractTask newTask(TaskContext taskInstance) throws IllegalArgumentException { switch (t 阅读全文
posted @ 2020-09-02 10:45 SpecialSpeculator 阅读(243) 评论(0) 推荐(0) 编辑
摘要: 1.pom引入guava依赖 <dependency> <groupId>com.google.guava</groupId> <artifactId>guava</artifactId> <version>23.0</version> </dependency> 1.线程工具类ThreadUtil 阅读全文
posted @ 2020-09-02 10:37 SpecialSpeculator 阅读(1356) 评论(0) 推荐(0) 编辑
摘要: 1.pom中添加swagger依赖 <!-- swagger-ui --> <dependency> <groupId>io.springfox</groupId> <artifactId>springfox-swagger2</artifactId> <version>2.8.0</version 阅读全文
posted @ 2020-09-02 10:31 SpecialSpeculator 阅读(408) 评论(0) 推荐(0) 编辑
摘要: 1.依赖状态枚举 /** * status enum */ public enum Status { SUCCESS(0, "success", "成功"), INTERNAL_SERVER_ERROR_ARGS(10000, "Internal Server Error: {0}", "服务端异常 阅读全文
posted @ 2020-09-02 10:12 SpecialSpeculator 阅读(2900) 评论(0) 推荐(0) 编辑