From: Bill H. <bi...@lo...> - 2004-03-23 20:28:04
|
Hi all, Just an update for everyone. Following Bertrand's recommendation, I've changed the ProxyFactory so that when we proxy a connection or a statement we also implement the same public interfaces as the original object. The upshot of this is that you can now do: Connection c = DriverManager.getConnection(url, properties); OracleConnection oc = (OracleConnection) c; This means we can probably deprecate the old ProxoolFacade.getDelegateConnection and getDelegateStatement methods. I say "probably" because the new proxy solution only works for interfaces. All well written drivers should be written to interfaces but if anyone is using a connection object that provides public methods that aren't declared in an interface then they won't be accessible. I'm tempted to live with that limitation. Remember, exposing the delegate connection is a weakness since it allows people to close the delegate instead of the proxy thereby not returning it to the pool. All this is uncommitted at the moment. Committing very soon. - Bill |