Commit fbc83fa8 authored by 陈宏杰's avatar 陈宏杰

优化

parent b1bc3fc5
......@@ -540,8 +540,9 @@ public class BaiHangFileReportService {
private void saveRepaymentLoanInfoLog(List<RepaymentInfoZhuDai> recordList,String startTime, String endTime) {
if (!CollectionUtils.isEmpty(recordList)) {
List<List<RepaymentInfoZhuDai>> allList = null;
try {
List<List<RepaymentInfoZhuDai>> allList = Lists.partition(recordList, LISTS_PARTITION_SIZE);
allList = Lists.partition(recordList, LISTS_PARTITION_SIZE);
Stopwatch saveStopwatch = Stopwatch.createStarted();
allList.stream().forEach(pRecordList -> {
repaymentLoanInfoDbMapper.batchSaveRepaymentLoanInfoLog(pRecordList);
......@@ -549,6 +550,8 @@ public class BaiHangFileReportService {
log.info("量化派助贷TO百行报送(D3)批量插入结束, startTime: {} , endTime: {} , 大小: {} , 耗时: {} ", startTime, endTime, recordList.size(), (saveStopwatch.stop().elapsed(TimeUnit.MILLISECONDS) / 1000) + ".s");
} catch (Exception e) {
log.error("量化派助贷TO百行报送(D3)保存异常", e);
} finally {
clear(recordList,allList);
}
}
}
......
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