2017-05-17 18:06
@JFinal
arpOracle.setTransactionLevel(8);
你好,这个应该是全局事务级别吧?如果我想给某几个方法设置不同的事务级别,应该如果配置?
//oracle 数据源
C3p0Plugin dsOracle = new C3p0Plugin(p.get("oracleJdbcUrl"), p.get("oracleUser"), p.get("oraclePassword"));
dsOracle.setDriverClass(p.get("oracleDriverClassName"));
dsOracle.setInitialPoolSize(p.getInt("oracleInitialPoolSize"));
dsOracle.setMinPoolSize(p.getInt("oracleMinPoolSize"));
dsOracle.setMaxPoolSize(p.getInt("oracleMaxPoolSize"));
dsOracle.setMaxIdleTime(p.getInt("oracleMaxIdleTime"));
dsOracle.setAcquireIncrement(p.getInt("oracleAcquireIncrement"));
// oracle ActiveRecrodPlugin 实例,并指定configName为 oracle
ActiveRecordPlugin arpOracle = new ActiveRecordPlugin("oracle", dsOracle);
arpOracle.setDevMode(p.getBoolean("devMode"));
arpOracle.setShowSql(p.getBoolean("showSql"));
arpOracle.setDialect(new OracleDialect());
arpOracle.setTransactionLevel(8);
arpOracle.setContainerFactory(new CaseInsensitiveContainerFactory());//忽略大小写
com.cedarmg.ecs.fawbtddp.timerapidb.core.models.oracle._MappingKit.mapping(arpOracle);
dsOracle.start();
arpOracle.start();
2017-05-16 16:26
@cnzzr 你好,我们站点部署了10多台服务器上,手动清理模板缓存的话,不一定会漂到哪个服务器上?
2016-10-18 15:31
/**
* TxConfig is used to configure configName for Tx interceptor
*/
@Inherited
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.TYPE, ElementType.METHOD})
public @interface TxConfig {
String value(); // configName of Config
}
加了类注解后事务好似了,谢谢
@TxConfig("oracle")
public class ReadyClueSerice {