private Executor personInfoTaskExecutor;
@GetMapping("asyncExceutorInfo")
public Map getThreadInfo() {
Object[] myThread = {personInfoTaskExecutor};
for (Object thread : myThread) {
ThreadPoolTaskExecutor threadTask = (ThreadPoolTaskExecutor) thread;
ThreadPoolExecutor threadPoolExecutor =threadTask.getThreadPoolExecutor();
map.put("提交任务数-->",threadPoolExecutor.getTaskCount());
map.put("完成任务数-->",threadPoolExecutor.getCompletedTaskCount());
map.put("当前有多少线程正在处理任务-->",threadPoolExecutor.getActiveCount());
map.put("还剩多少个任务未执行-->",threadPoolExecutor.getQueue().size());
map.put("当前可用队列长度-->",threadPoolExecutor.getQueue().remainingCapacity());