| Author |
Direct JDBC Connection Vs DataSource Connection
|
m prabhu
Ranch Hand
Joined: Jan 29, 2008
Posts: 79
|
|
what is the difference when
1.a web application uses a direct JDBC connection to interact with the RDBMS.
2.a web applciation uses a datasource functionality provided by the application server to interact with the RDBMS.
Please let me know the advantages and the disadvantages.
Regards,
Prabhu
|
 |
Joe Harry
Ranch Hand
Joined: Sep 26, 2006
Posts: 8795
|
|
|
With the first approach, you have to manually manage transactions, database connection pooling and stuff but with the latter, you get that from the container.
|
SCJP 1.4, SCWCD 1.4 - Hints for you, SCBCD Hints - Demnachst, SCDJWS - Auch Demnachst
Did a rm -R / to find out that I lost my entire Linux installation!
|
 |
Seetharaman Venkatasamy
Ranch Hand
Joined: Jan 28, 2008
Posts: 5575
|
|
Jothi Shankar Kumar wrote:With the first approach, you have to manually manage transactions, database connection pooling and stuff but with the latter, you get that from the container.
either direct jdbc connection(type1) nor datasource support implicit transaction, thats is your own logic.
and read this why ConnectionPooling is prefer over JDBC connection
|
 |
Lucas Smith
Ranch Hand
Joined: Apr 20, 2009
Posts: 804
|
|
|
This question is not about SCWCD. It should be moved to different place.
|
SCJP6, SCWCD5, OCE:EJBD6.
BLOG: http://leakfromjavaheap.blogspot.com
|
 |
 |
|
|
subject: Direct JDBC Connection Vs DataSource Connection
|
|
|