|
@@ -219,10 +219,11 @@ public class CoreServiceImpl implements CoreService {
|
|
|
// 启动消费者线程
|
|
|
for (int i = 0; i < threadSize; i++) {
|
|
|
threadPoolExecutor.submit(new Thread(() -> {
|
|
|
+ log.info("启动匹配小程序线程");
|
|
|
while (true) {
|
|
|
try {
|
|
|
// 超过 10 分钟没有数据,销毁当前线程
|
|
|
- MatchContent matchContent = queue.poll(5, TimeUnit.MINUTES); // 等待最多 10 分钟
|
|
|
+ MatchContent matchContent = queue.poll(5, TimeUnit.MINUTES); // 等待最多 5 分钟
|
|
|
if (matchContent == null) {
|
|
|
break; // 退出当前线程
|
|
|
}
|
|
@@ -261,6 +262,7 @@ public class CoreServiceImpl implements CoreService {
|
|
|
throw new RuntimeException(e);
|
|
|
}
|
|
|
}
|
|
|
+ log.info("启动匹配小程序线程结束");
|
|
|
}));
|
|
|
}
|
|
|
}
|