Commit e8e8af7b by 周晓航

Merge branch 'feature/20210510/v2.0.30-记录每天下单门店-周晓航'

parents 8e3ca945 a007a4eb
...@@ -15,6 +15,7 @@ import org.springframework.util.CollectionUtils; ...@@ -15,6 +15,7 @@ import org.springframework.util.CollectionUtils;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.*; import java.util.*;
import java.util.concurrent.TimeUnit;
/** /**
* @author : xh.Z * @author : xh.Z
...@@ -38,7 +39,8 @@ public class OrderReportJobHandler { ...@@ -38,7 +39,8 @@ public class OrderReportJobHandler {
public void sendYesterDayStoreMsg() { public void sendYesterDayStoreMsg() {
String date = getYesterdayString(pattern_yyyy_MM_dd); String date = getYesterdayString(pattern_yyyy_MM_dd);
BoundHashOperations<String, String, Set<String>> boundHashOperations = redisCache.getRedisTemplate().boundHashOps(RedisKeyConstant.KGD_NO_ORDER_STORE_DATE + date); String key = RedisKeyConstant.KGD_NO_ORDER_STORE_DATE + date;
BoundHashOperations<String, String, Set<String>> boundHashOperations = redisCache.getRedisTemplate().boundHashOps(key);
Map<String, Set<String>> entries = boundHashOperations.entries(); Map<String, Set<String>> entries = boundHashOperations.entries();
LogUtil.info("下单门店记录推送 entries", entries, null); LogUtil.info("下单门店记录推送 entries", entries, null);
if (!CollectionUtils.isEmpty(entries)) { if (!CollectionUtils.isEmpty(entries)) {
...@@ -55,7 +57,8 @@ public class OrderReportJobHandler { ...@@ -55,7 +57,8 @@ public class OrderReportJobHandler {
.build(); .build();
BaseResponse baseResponse = storeBackstageClient.pushOrderStore(pushOrderStoreDto); BaseResponse baseResponse = storeBackstageClient.pushOrderStore(pushOrderStoreDto);
LogUtil.info("上报门店支付情况", JSON.toJSONString(pushOrderStoreDto), JSON.toJSONString(baseResponse)); LogUtil.info("上报门店支付情况", JSON.toJSONString(pushOrderStoreDto), JSON.toJSONString(baseResponse));
// fisherman 数据推送之后的 redis 缓存数据 是否清理 暂时没需求 // 数据推送之后的 redis 缓存数据 清理
redisCache.updateTTL(key, 1, TimeUnit.DAYS);
} catch (Exception e) { } catch (Exception e) {
LogUtil.error("上报门店支付情况 error", null, JSON.toJSONString(e)); LogUtil.error("上报门店支付情况 error", null, JSON.toJSONString(e));
} }
......
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