FrancisS commented on PR #57:
URL: https://github.com/apache/velocity-engine/pull/57#issuecomment-2875043962

   XPosting from the jira issue:
   I updated the PR with a fix that I don't love but I can't find a way to do 
it differently without changing the API of DatabaseObjectsFactory. I updated 
the factory to return a proxy of Statement and ResultSet that guarantees 
Statement.getConnection and ResultSet.getStatement behave in a way that will 
not cause issues.
   
   However I would prefer to change DatabaseObjectsFactory.prepareStatement and 
DatabaseObjectsFactory.releaseStatement to use an explicit wrapper object 
instead. This would avoid the somewhat hard to follow proxy code and would be a 
bit more obvious to anyone writing custom implementations of 
DatabaseObjectsFactory that the original connection and statement are needed 
rather then relying on Statement.getConnection or ResultSet.getStatement.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@velocity.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@velocity.apache.org
For additional commands, e-mail: dev-h...@velocity.apache.org

Reply via email to