Browse Source

任务回调队列,poll改为take;修复一处可能导致cpu占满的问题

xueli.xue 9 năm trước cách đây
mục cha
commit
4f3f5e849c

+ 1 - 1
xxl-job-core/src/main/java/com/xxl/job/core/handler/HandlerRepository.java

@@ -206,7 +206,7 @@ public class HandlerRepository {
 			public void run() {
 				while(true){
 					try {
-						HashMap<String, String> item = callBackQueue.poll();
+						HashMap<String, String> item = callBackQueue.take();
 						if (item != null) {
 							RemoteCallBack callback = null;
 							try {