From c4c09417112a385909eed3e7d32dbe9525ce0a16 Mon Sep 17 00:00:00 2001
From: Helius <wangdoubleone@gmail.com>
Date: Mon, 21 Jun 2021 11:36:45 +0800
Subject: [PATCH] modify
---
src/main/java/com/xcong/excoin/utils/ThreadPoolUtils.java | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)
diff --git a/src/main/java/com/xcong/excoin/utils/ThreadPoolUtils.java b/src/main/java/com/xcong/excoin/utils/ThreadPoolUtils.java
index ddc8c7d..166ff77 100644
--- a/src/main/java/com/xcong/excoin/utils/ThreadPoolUtils.java
+++ b/src/main/java/com/xcong/excoin/utils/ThreadPoolUtils.java
@@ -20,6 +20,7 @@
import com.xcong.excoin.rabbit.pricequeue.whole.WholePriceDataModel;
import com.xcong.excoin.rabbit.producer.OrderProducer;
import com.xcong.excoin.utils.dingtalk.DingTalkUtils;
+import lombok.SneakyThrows;
import lombok.extern.slf4j.Slf4j;
import javax.validation.constraints.NotNull;
@@ -109,13 +110,23 @@
*/
public static void sendWholePrice(@NotNull Long memberId) {
EXECUTOR.execute(new Runnable() {
+ @SneakyThrows
@Override
public void run() {
+ Thread.sleep(500);
log.info("全仓操作价格");
-
OrderProducer orderProducer = SpringContextHolder.getBean(OrderProducer.class);
orderProducer.sendWholePrice(memberId.toString());
}
});
}
+
+ public static void sendOrderMsg() {
+ EXECUTOR.execute(new Runnable() {
+ @Override
+ public void run() {
+ DingTalkUtils.sendOrderMsg();
+ }
+ });
+ }
}
--
Gitblit v1.9.1