I'm writing an app that is working with db via org.springframework.jdbc.core.JdbcTemplate
. I need to log execution of those queries. So I have methods that have some jdbctemplate logic, for example
List<Map<String, Object>> data = jdbcTemplate.queryForList(queryTables);
I need to log time of execution of this query but not of the all method. I can do that via milliseconds subtraction. But it is not the case if I have 1500 methods or even more. So is there any annotation or any other method that can help me to log execution time?