From 71bad3b7c3567b1376bce95b2018e33201337601 Mon Sep 17 00:00:00 2001 From: luoyang Date: Thu, 27 Sep 2018 17:31:32 +0800 Subject: [PATCH] add --- .../payment/manage/dev/core/impl/HfUpdateImpl.java | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/HfUpdateImpl.java b/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/HfUpdateImpl.java index 8db1c972a..e9fa6ccc4 100644 --- a/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/HfUpdateImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/dev/core/impl/HfUpdateImpl.java @@ -10,6 +10,8 @@ import au.com.royalpay.payment.tools.env.PlatformEnvironment; import com.alibaba.fastjson.JSONObject; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; import org.springframework.stereotype.Service; import java.util.List; @@ -27,6 +29,8 @@ public class HfUpdateImpl implements HfUpdateService { @Resource private RpayApi rpayApi; + private Logger logger = LoggerFactory.getLogger(getClass()); + @Override public String updateStatus() { List clientIds = clientMapper.findByhfPayUrlNotNull(); @@ -48,10 +52,15 @@ public class HfUpdateImpl implements HfUpdateService { @Override public String rpayUpdate() { List clientIds = clientMapper.findByrpayNotNull(); + StringBuffer sb = new StringBuffer(); clientIds.forEach(dbResult -> { - rpayApi.modifySurchargeConfig(dbResult); - + try { + rpayApi.modifySurchargeConfig(dbResult); + } catch (Exception e) { + sb.append("【" + dbResult.getString("client_moniker") + "】、"); + } }); + logger.info("test for update rpay clearing date,fail + " + sb.toString()); return "ok"; } }