增加发送信息

This commit is contained in:
王涛 2023-06-02 09:47:16 +08:00
parent 5a91d975a6
commit a3d689d80a
2 changed files with 5 additions and 0 deletions

View File

@ -148,6 +148,7 @@ public class WxMsgHandle {
String substring = monery.substring(1); String substring = monery.substring(1);
BigDecimal decimal = new BigDecimal(substring); BigDecimal decimal = new BigDecimal(substring);
log.info("扫码收款:{},付款人:{},付款备注:{}", decimal.stripTrailingZeros().toPlainString(), next.getValue(), remark); log.info("扫码收款:{},付款人:{},付款备注:{}", decimal.stripTrailingZeros().toPlainString(), next.getValue(), remark);
HttpSendUtil.发送文本(next.getValue(), StrUtil.format("扫码收款:{},备注:{}", decimal.stripTrailingZeros().toPlainString(), remark));
iterator.remove(); iterator.remove();
return false; return false;
} }
@ -182,6 +183,7 @@ public class WxMsgHandle {
String substring = monery.substring(1); String substring = monery.substring(1);
BigDecimal decimal = new BigDecimal(substring); BigDecimal decimal = new BigDecimal(substring);
log.info("收款:{},付款人:{},付款备注:{}", decimal.stripTrailingZeros().toPlainString(), receiver_username, remark); log.info("收款:{},付款人:{},付款备注:{}", decimal.stripTrailingZeros().toPlainString(), receiver_username, remark);
HttpSendUtil.发送文本(receiver_username, StrUtil.format("收到款项:{},备注:{}", decimal.stripTrailingZeros().toPlainString(), remark));
return false; return false;
} }
} }

View File

@ -22,6 +22,9 @@ import java.util.concurrent.TimeUnit;
@Component @Component
public class ArrHandle { public class ArrHandle {
/**
* 线程处理消息队列,但是必须保证核心数大于2,其中必定要有一个线程可以单独处理交易队列信息
*/
public static final ThreadPoolExecutor sub = new ThreadPoolExecutor(4, 10, 30, TimeUnit.MINUTES, new LinkedBlockingQueue<>(), new NamedThreadFactory("sub", false)); public static final ThreadPoolExecutor sub = new ThreadPoolExecutor(4, 10, 30, TimeUnit.MINUTES, new LinkedBlockingQueue<>(), new NamedThreadFactory("sub", false));
public static final ThreadLocal<PrivateChatMsg> chatMsgThreadLocal = new InheritableThreadLocal<>(); public static final ThreadLocal<PrivateChatMsg> chatMsgThreadLocal = new InheritableThreadLocal<>();
protected static final Log log = Log.get(); protected static final Log log = Log.get();