From 9662716553db1d29ba49f57d068021d01523a960 Mon Sep 17 00:00:00 2001 From: qifanwang Date: Tue, 24 Sep 2024 11:25:34 +0800 Subject: [PATCH] add disable _DalTransactionAspect config --- .../ctrip/xpipe/redis/console/aop/DalTransactionAspect.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/redis/redis-console/src/main/java/com/ctrip/xpipe/redis/console/aop/DalTransactionAspect.java b/redis/redis-console/src/main/java/com/ctrip/xpipe/redis/console/aop/DalTransactionAspect.java index e53a86c98..f6b8d899f 100644 --- a/redis/redis-console/src/main/java/com/ctrip/xpipe/redis/console/aop/DalTransactionAspect.java +++ b/redis/redis-console/src/main/java/com/ctrip/xpipe/redis/console/aop/DalTransactionAspect.java @@ -1,5 +1,7 @@ package com.ctrip.xpipe.redis.console.aop; +import com.ctrip.xpipe.redis.checker.spring.ConsoleDisableDbCondition; +import com.ctrip.xpipe.redis.checker.spring.DisableDbMode; import com.ctrip.xpipe.redis.console.annotation.DalTransaction; import com.ctrip.xpipe.redis.console.config.ConsoleConfig; import com.ctrip.xpipe.redis.console.exception.ServerException; @@ -11,6 +13,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Conditional; import org.springframework.stereotype.Component; import org.unidal.dal.jdbc.transaction.TransactionManager; import org.unidal.lookup.ContainerLoader; @@ -25,6 +28,8 @@ */ @Aspect @Component +@Conditional(ConsoleDisableDbCondition.class) +@DisableDbMode(false) public class DalTransactionAspect { private TransactionManager transactionManager;