Commit ef269538 authored by 赵啸非's avatar 赵啸非

更新下发消息为线程池发送

parent 75f526dc
......@@ -23,7 +23,6 @@ import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.util.ObjectUtils;
import java.util.ArrayList;
import java.util.Comparator;
import java.util.Date;
import java.util.List;
......@@ -49,7 +48,7 @@ public class DownMsgTask implements Runnable {
@Override
public void run() {
try {
ArrayList<DeviceLogEntity> deviceLogList = new ArrayList<>();
//ArrayList<DeviceLogEntity> deviceLogList = new ArrayList<>();
List<DeviceMsgReq> collect = list.stream().sorted(Comparator.comparing(DeviceMsgReq::getTimestamp)).collect(Collectors.toList());
List<List<DeviceMsgReq>> partition = ListUtil.partition(collect, 10);
for (List<DeviceMsgReq> deviceMsgReqs : partition) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment