【8.1.8】【事物】手动调整事务的AOP顺序为200

dev-8.1.9
fengshuonan 2024-06-21 11:07:20 +08:00
parent 5a6c5c25b9
commit 904ad50610
3 changed files with 48 additions and 1 deletions

View File

@ -20,6 +20,11 @@ public interface ProjectAopSortConstants {
*/
int DATA_SCOPE_AOP_ORDER = 100;
/**
* AOP
*/
int TRANSACTION_AOP_ORDER = 200;
/**
* aop
*/

View File

@ -0,0 +1,41 @@
/*
* Copyright [2020-2030] [https://www.stylefeng.cn]
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* GunsAPACHE LICENSE 2.0使
*
* 1.LICENSE
* 2.Guns
* 3.
* 4. https://gitee.com/stylefeng/guns
* 5. https://gitee.com/stylefeng/guns
* 6.
*/
package cn.stylefeng.roses.kernel.db.starter;
import cn.stylefeng.roses.kernel.rule.constants.ProjectAopSortConstants;
import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;
/**
*
*
* @author fengshuonan
* @since 2024/6/21 11:05
*/
@Configuration
@EnableTransactionManagement(order = ProjectAopSortConstants.TRANSACTION_AOP_ORDER)
public class ProjectTranAutoConfiguration {
}

View File

@ -3,6 +3,7 @@ org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
cn.stylefeng.roses.kernel.db.starter.ProjectDruidPropertiesAutoConfiguration,\
cn.stylefeng.roses.kernel.db.starter.ProjectMyBatisPlusAutoConfiguration,\
cn.stylefeng.roses.kernel.db.starter.ProjectDruidMonitorAutoConfiguration,\
cn.stylefeng.roses.kernel.db.starter.RemoveDruidAdAutoConfiguration
cn.stylefeng.roses.kernel.db.starter.RemoveDruidAdAutoConfiguration,\
cn.stylefeng.roses.kernel.db.starter.ProjectTranAutoConfiguration
org.springframework.context.ApplicationListener=\
cn.stylefeng.roses.kernel.db.api.maxsort.listener.TableMaxSortConfigListener