Class GlueDefaultTransactionDefinition
java.lang.Object
org.springframework.transaction.support.DefaultTransactionDefinition
com.poscoict.glueframework.transaction.GlueDefaultTransactionDefinition
- All Implemented Interfaces:
 Serializable,TransactionDefinition
TransactionDefinition 인터페이스의 디폴트 구현 클래스. 디폴트로 설정되는 트랜잭션 프로퍼티 값 (PROPAGATION_REQUIRES_NEW, ISOLATION_DEFAULT, TIMEOUT_DEFAULT,
 readOnly=false). org.springframework.transaction.support. DefaultTransactionDefinition을 확장한것으로 propagationBehavior의 default 값이
 PROPAGATION_REQUIRED가 아닌 PROPAGATION_REQUIRES_NEW이며 그외는 동일하다.
빈 스타일의 설정을 지원한다. (Dependency Injection)
 
디폴트로 제공되는 값을 수정하기 위해서는 다음과 같이 applicationContext.xml 파일을 수정한다.
빈 스타일의 설정을 지원한다. (Dependency Injection)
디폴트로 제공되는 값을 수정하기 위해서는 다음과 같이 applicationContext.xml 파일을 수정한다.
 <!-- Transaction Manager -->
 <bean id="tx-1" class="com.poscoict.glueframework.transaction.GlueDataSourceTransactionManager">
     <property name="dataSource" ref="ds-1"/>
     <property name="transactionDefinition" ref="txDef-1"/>
 </bean>
 <!-- Transaction Definition -->
 <bean id="txDef-1" class="com.poscoict.glueframework.transaction.GlueDefaultTransactionDefinition">
     <property name="isolationLevelName" value="ISOLATION_READ_COMMITTED"/>
     <property name="propagationBehaviorName" value="PROPAGATION_REQUIRED"/>
     <property name="readOnly" value="false"/>
     <property name="timeout" value="5000"/>
 </bean>
 
 timeout은 JDBC의 Statement.setQueryTimeout(초) 설정입니다. 디폴트는 "-1"입니다. "-1"이면 무한 Waiting이고 플러스 숫자는 해당 초만큼 Query를 Waiting 합니다. JDBC를 공급하는 벤더와
 버젼에 따라 동작할 수도 안할 수도 있습니다.- See Also:
 
- 
Field Summary
Fields inherited from class org.springframework.transaction.support.DefaultTransactionDefinition
PREFIX_ISOLATION, PREFIX_PROPAGATION, PREFIX_TIMEOUT, READ_ONLY_MARKERFields inherited from interface org.springframework.transaction.TransactionDefinition
ISOLATION_DEFAULT, ISOLATION_READ_COMMITTED, ISOLATION_READ_UNCOMMITTED, ISOLATION_REPEATABLE_READ, ISOLATION_SERIALIZABLE, PROPAGATION_MANDATORY, PROPAGATION_NESTED, PROPAGATION_NEVER, PROPAGATION_NOT_SUPPORTED, PROPAGATION_REQUIRED, PROPAGATION_REQUIRES_NEW, PROPAGATION_SUPPORTS, TIMEOUT_DEFAULT - 
Constructor Summary
ConstructorsConstructorDescription생성자(constructor).생성자(constructor). - 
Method Summary
Methods inherited from class org.springframework.transaction.support.DefaultTransactionDefinition
equals, getDefinitionDescription, getIsolationLevel, getName, getPropagationBehavior, getTimeout, hashCode, isReadOnly, setIsolationLevel, setIsolationLevelName, setName, setPropagationBehavior, setPropagationBehaviorName, setReadOnly, setTimeout, toString 
- 
Constructor Details
- 
GlueDefaultTransactionDefinition
public GlueDefaultTransactionDefinition()생성자(constructor). DefaultTransactionDefinition의 값에서 PropagationBehavior의 기본값은 PROPAGATION_REQUIRED 대신에 PROPAGATION_REQUIRES_NEW을 설정한다. 즉 PROPAGATION_REQUIRES_NEW, ISOLATION_DEFAULT, TIMEOUT_DEFAULT, readOnly=false 이다. 물론, setter method를 통한 값의 변경이 가능하다. - 
GlueDefaultTransactionDefinition
생성자(constructor). 복사 생성자- Parameters:
 txDef- TransactionDefinition 오브젝트
 
 -