i have strange scenario. have spring mvc ( no ui though) services support uploading xml files database. but, database connection provided legacy code (no "datasource" available directly) helper methods such getconnection(), createcallablestatement(), executebatch() etc... code deployed on weblogic (very tricky , decision made way) required have transactions these files have many scenarios need rollback if needed. now, how do using spring transaction support? need make work junits. not using orm framework plain jdbc ( specialcase again).
can please give me pointers on how implement this. have created profile "weblogic" in srring context , created bean transactionmanager transaction not being rolled exceptions transaction manager doesn't have datasource monitor , roll back.i not able figure out way how junits also.
sample context.xml follows:
<beans profile="weblogic"> <bean id="transactionmanager"class="org.springframework.transaction.jta.weblogicjtatransactionmanager"></bean> </beans>
Comments
Post a Comment