• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Regarding the Connection interface

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi ,

I have been a java developer for long and yet there is one question that struck my mind today.
The java.sql.Connection is an interface. Agreed. There is a method named commit() which explicitly commits all transactions made(considering autocommit is false).
This commit() in the connection interface does not implement anything, I am very curious to know what happens when this commit() is called.

There is something called System Global Area(SGA) which is a shared random access memory (RAM) allocated by oracle to manage connection pooling, caching ,etc.
So, when we call the commit method of the connection interface, does any thing happen in the java pool in the sga I mentioned above.

This question may be trivial to many experts, but I am found searching for an answer. If anyone finding time , can you please answer this.

Regards,
nandydesikan
 
Bartender
Posts: 2661
19
Netbeans IDE C++ Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Connection is an interface,
but the class you get from your JDBC jars when you get a connection is (has the type of) a concrete Java class.
And you call the commit() method of that concrete Java class.




and then I have to admit that I know nothing whatsoever of the SGA
 
nandy desikan
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot for clarifying!!
so an object reference of type Connection interface will be type cast over the implementation class (Oracle connection)_plain old java principle
Cool!! Thanks. This was digging my mind since Friday ...

Cheers,

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is a very helpful thread..Came to know a very Important point from this..Thanks Guys..
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic