List分割每次请求500条数据
//分割idList 每次请求500条数据,noticeSize可在配置文件中灵活配置
@Value("${aliyun.notice.size}")
private int noticeSize;
List<List<String>> partition = Lists.partition(idList, noticeSize);
if (partition.size() > 0) {
for (List<String> list : partition) {
noticeRequest.setUserIds(list);
responseDto = push(noticeRequest, client);
}
}