开发者

Retrieving SQL queries with Spring

开发者 https://www.devze.com 2023-03-03 18:55 出处:网络
I was hoping to make a little analytics plugin for Spring, a bit similar to the Spring Tool Suite.It was easy to use AOP to stick proxies between most beans and get timing information, but one thing I

I was hoping to make a little analytics plugin for Spring, a bit similar to the Spring Tool Suite. It was easy to use AOP to stick proxies between most beans and get timing information, but one thing I'm stuck on is how to get ahold of all of the SQL statements that go out through Hibernate or JDBC. I'd love to see exactly what SQL was sent out with e开发者_如何学编程xactly what parameters, but I can't figure out how to inject myself into the process easily. Suggestions?


I recommend you to test this tool.

http://code.google.com/p/datasource-proxy/

It looks like you can integrate it as part of the Spring framework,

0

精彩评论

暂无评论...
验证码 换一张
取 消