能否根据方法(GET/HEAD/POST等)以及数据库类型或者datasource设置隔离级别
我需要连接多个数据源,且是不同的数据库,目前主要有tidb、sqlserver。 目前没有找到根据方法和数据库类型两个条件设置隔离级别的参数。
parser中只能根据方法设置 executor中只能根据数据库类型设置
有没有什么方法能同时根据方法、数据库类型设置隔离级别
目前可以重写方法自定义实现。 DemoSQLExecutor 重写 begin 或 getConnection https://github.com/Tencent/APIJSON/blob/master/APIJSONORM/src/main/java/apijson/orm/AbstractSQLExecutor.java#L1037
DemoSQLExecutor 中的begin或者getConnection无法判断当前执行的 是get还是post方法吧? 我需要的是get方法隔离级别设置为read uncommit,其他的不变
DemoSQLExecutor 中的begin或者getConnection无法判断当前执行的 是get还是post方法吧? 我需要的是get方法隔离级别设置为read uncommit,其他的不变
getConnection 内 config.getMethod 拿到方法,用于判断 https://github.com/Tencent/APIJSON/blob/master/APIJSONORM/src/main/java/apijson/orm/AbstractSQLExecutor.java#L1015