spring - Connection get/return listener? -


using hibernate , spring, app needs opportunity manipulate connection @ start , end of every database update. our first guess override transaction manager, seeming have side effects intermittent "pre-bound jdbc connection found!" error few other harder describe symptoms.

what best/easiest way oppostunity. saw suggest overriding data source , wrapping connection, best idea? wrapping connection seems dangerous, espceially since websphere has it's own version (wsconnection).

ideas?

manipulation of connection done easiest when datasource.getconnection done, way know going happen. create datasourceproxy/-wrapper (give name) this. there 1 thing have take care of , is, on close of connection, undo manipulation (if needed is).

instead of creating proxy use aop execute code (like in this answer.


Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -