Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Oracle objects and collections with Java

lewiscSep 15 2013 — edited Oct 15 2014

Hi.

I've designed a lot of database applications in my time. I pretty much always make heavy use of objects (oracle database defined, complex types - also collections) for parameters and such to procedures. I've never had any problem with it in the past (8i, 9i, 10g or 11). I made some suggestions for improvements at my current gig and got some fear and doubt coming back at me.

I've used objects with both Java and .Net with no issue but I was not the one doing the middle tier coding. So, I don't really know how to respond to this. I can do Java coding but am nowhere near knowledgeable on connection pooling.

Specifically, the reason that the dev team does not want to do this is because, and I quote:

Java mapping for oracle type and table type is oracle.sql.STRUCT. When oracle.sql.STRUCT is used then vendor connection needs to be used. Vendor connection is not logical connection it is physical connection. So whenever we close the connection that connection gets destroyed and connection pool will create new connection.


So, the fear is that this will cause a performance issue if every call has to reconnect to the database.  I *know* this *can* work without performance issues. Is there a particular thing to look at? Type Map vs Struct? Pool configuration? Something else?


This Tomcat (and Mule) on 11g.Linux is the OS. We're using the latest Oracle drivers.


Thanks in advance for any insight.


LewisC


This post has been answered by dsurber-Oracle on Oct 2 2013
Jump to Answer

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Oct 30 2013
Added on Sep 15 2013
17 comments
1,223 views