Commit 31f6de8d by 向延琳

修改日志级别

1 parent a6528837
......@@ -50,7 +50,7 @@ public class JourneyService {
}
DeviceJourney journey = deviceJourneyMapper.selectBySnAndBeginTime(deviceJourneyDTO.getSn(), deviceJourneyDTO.getBeginTime());
long t2 = System.currentTimeMillis();
log.info("重复校验时间{}", t2 - t1);
log.debug("重复校验时间{}", t2 - t1);
if(Objects.nonNull(journey)) {
log.warn("该设备同样的开始时间行程数据已经存在" +
"sn: " + deviceJourneyDTO.getSn() + "beginTime:" + DateUtils.formatNormal(deviceJourneyDTO.getBeginTime()));
......@@ -62,12 +62,12 @@ public class JourneyService {
Long createdBy = Optional.ofNullable(vehicle).map(Vehicle::getCreatedBy).orElse(null);
Long updatedBy = Optional.ofNullable(vehicle).map(Vehicle::getUpdatedBy).orElse(null);
long t3 = System.currentTimeMillis();
log.info("获取创建人时间{}", t3 - t2);
log.debug("获取创建人时间{}", t3 - t2);
//从关联表从获取关联id
Long vdId = vehicleService.getVdId(deviceJourneyDTO.getSn());
long t4 = System.currentTimeMillis();
log.info("获取创建人时间{}", t4 - t3);
log.debug("获取创建人时间{}", t4 - t3);
//行程信息入库
DeviceJourney deviceJourney = convertTo(deviceJourneyDTO, vdId, createdBy, updatedBy);
......@@ -77,7 +77,7 @@ public class JourneyService {
log.info("vdId{}", vdId);
if(Objects.isNull(vdId)) {
log.warn("该设备没有绑定车辆" + deviceJourneyDTO.getSn());
log.info("同步里程总耗时{}", t4 - t1);
log.debug("同步里程总耗时{}", t4 - t1);
return;
}
......@@ -85,11 +85,11 @@ public class JourneyService {
DeviceJourneyOverview overviewDO = buildOverviewWitheJourney(deviceJourneyDTO, vdId, createdBy, updatedBy);
DeviceJourneyOverview overview = deviceJourneyOverviewMapper.selectBySnAndVdId(deviceJourneyDTO.getSn(), vdId);
long t5 = System.currentTimeMillis();
log.info("行程入库时间{}", t5 - t4);
log.debug("行程入库时间{}", t5 - t4);
if (Objects.isNull(overview)) {
//本设备的第一条里程数据
deviceJourneyOverviewMapper.insert(overviewDO);
log.info("同步里程总耗时{}", t5 - t1);
log.debug("同步里程总耗时{}", t5 - t1);
return;
}
overview.setDistance(overview.getDistance() + overviewDO.getDistance());
......@@ -97,7 +97,7 @@ public class JourneyService {
overview.setUpdatedDate(new Date());
deviceJourneyOverviewMapper.updateByPrimaryKeySelective(overview);
long t6 = System.currentTimeMillis();
log.info("同步里程和总里程总耗时{}", t6 - t1);
log.debug("同步里程和总里程总耗时{}", t6 - t1);
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!