update 优化 异常处理器自动配置

master
疯狂的狮子Li 2 years ago
parent 14cedccaf3
commit 3ffd1e3b41

@ -11,6 +11,7 @@ import com.baomidou.mybatisplus.extension.plugins.inner.TenantLineInnerIntercept
import org.dromara.common.core.factory.YmlPropertySourceFactory;
import org.dromara.common.core.utils.SpringUtils;
import org.dromara.common.mybatis.handler.InjectionMetaObjectHandler;
import org.dromara.common.mybatis.handler.MybatisExceptionHandler;
import org.dromara.common.mybatis.interceptor.PlusDataPermissionInterceptor;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.BeansException;
@ -87,6 +88,14 @@ public class MybatisPlusConfig {
return new DefaultIdentifierGenerator(NetUtil.getLocalhost());
}
/**
*
*/
@Bean
public MybatisExceptionHandler mybatisExceptionHandler() {
return new MybatisExceptionHandler();
}
/**
* PaginationInnerInterceptor
* https://baomidou.com/pages/97710a/

@ -12,6 +12,7 @@ import lombok.extern.slf4j.Slf4j;
import org.dromara.common.core.utils.SpringUtils;
import org.dromara.common.redis.config.properties.RedissonProperties;
import org.dromara.common.redis.handler.KeyPrefixHandler;
import org.dromara.common.redis.handler.RedisExceptionHandler;
import org.redisson.client.codec.StringCodec;
import org.redisson.codec.CompositeCodec;
import org.redisson.codec.TypedJsonJacksonCodec;
@ -97,6 +98,14 @@ public class RedisConfig {
};
}
/**
*
*/
@Bean
public RedisExceptionHandler redisExceptionHandler() {
return new RedisExceptionHandler();
}
/**
* redis yml
*

Loading…
Cancel
Save