On Tue, Aug 25, 2009 at 3:15 PM, Asankha C. Perera <[email protected]>wrote: hi again, I think I need to give more details about this. This attribute was introduced to disable the commit operation of the DBReport mediator as I described earlier. Since we use this in a distributed transaction we can't use the con.setAutoCommit(false) ( where con is an object of java.sql.Connection) since that'd be a JDBC spec. violation. The patch should provide more clarifications. What I want to say is autocommit and useTransaction are two things. Setting autocommit will let you execute several SQL quries in a single DB transaction [1] where as useTransaction will let you to disable the commit operation in a distributed transaction so that commit operation of the distributed transaction will be manage by the container.
-Rajika [1] - http://java.sun.com/j2se/1.4.2/docs/api/java/sql/Connection.html#setAutoCommit(boolean) Hi Rajika > > I just submitted a patch for this(SYNAPSE-574). I added a attribute > > for DBReport mediator configuration which specify the use of DBReport > > mediator in a distributed transaction. I only added this to DBReport > > mediator since only it'll be affect in a distributed transaction. > > > > <dbreport useTransaction="true|false"> > > .... > > </dbreport> > I haven't seen the patch yet.. but I think it would be better to name > the attribute "autocommit" - since thats exactly what setting it to > true/false will do. So the default should also preserve backwards > compatibility (i.e. true). > > cheers > asankha > > -- > Asankha C. Perera > AdroitLogic, http://adroitlogic.org > > http://esbmagic.blogspot.com > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > -- http://wso2.org http://llvm.org http://www.minix3.org/
