Link to home
Start Free TrialLog in
Avatar of AXISHK
AXISHK

asked on

Setup GlassFish

What does the "Wrap JDBC Objects " mean in GlassFish under Navigate to JDBC -> Connection Pools -> Derby Pool In the advanced tab ? When should it be enabled  ?

Thx
Avatar of Bart Cremers
Bart Cremers
Flag of Belgium image

The "Wrap JDBC Objects" means that Glassfish will provide a wrapper for all JDBC objects (Statement, PreparedStatement, Resultset, ...) instead of only for the Connection. This ensures that no application can get the physical connection object by calling the #getConnection() method on those objects an mess up the Derby pool by calling close on that physical connection.
So, unless you really trust all applications using the pool for not calling close on those objects, I would always turn the setting on. Probably this might have a very slight performance penalty (extra object creation), but I think that can be neglected.
Avatar of AXISHK
AXISHK

ASKER

"This ensures that no application can get the physical connection object by calling the #getConnection() method on those objects an mess up the Derby pool by calling close on that physical connection. "

Do you mean that "disable" will disallow any application to either getConnection() method call or close the Derby pool connection ?

If yes, how does application connect to Derby pool ?

Thx again.
ASKER CERTIFIED SOLUTION
Avatar of Bart Cremers
Bart Cremers
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of AXISHK

ASKER

Thx