You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by ksv <ks...@smtp.ru> on 2005/01/24 16:25:44 UTC

[DBCP] Management of transactions... [DBCP] Management of transactions... [DBCP] Management of transactions... [DBCP] Management of transactions...

Hello ,
Interests everything, that is connected to managements of transactions at use DBCP...
Who Can will share experience or links? The database is not essential.
The principle of work with transactions through DBCP is necessary...



Best regards,
 ksv                          mailto:ksv@smtp.ru




---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: [DBCP] Management of transactions.

Posted by Dirk Verbeeck <di...@pandora.be>.
When working in a non-managed environment you have 2 main options.
1) You set autoCommit=true. In this mode all changes are automatically 
  committed.
2) autoCommit=false. You as programmer are responsible for committing 
the changes.

If you have a simple program (with simple input screens) on a well 
designed database then you can user option 1. But most of the time you 
want to manage the database transactions yourself using option2.

Most (web) frameworks have a more or less standard practice where to 
put the commit statements. Using a business and DAO layer and hide you 
database access is better of course.

You can also work in a managed environment. The application 
server/container manages the transactions for you. An EJB server is 
the most known example but there are others like spring framework.

Hope this helps
Dirk


ksv wrote:
> Hello ,
> Interests everything, that is connected to managements of transactions at use DBCP...
> Who Can will share experience or links? The database is not essential.
> The principle of work with transactions through DBCP is necessary...
> 
> 
> 
> Best regards,
>  ksv                          mailto:ksv@smtp.ru


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org