I am trying to figure our a java class with method name which is executing a particular SQL. I am at the Database HotSpot and sorted the SQL based on the Exec Total. On selecting the SQL with highest response time, i am not seeing any useful information at the Caller BreakDown. Please refer to the attached screenshot. Is there any thing that i am missing or is there a way to know which Java class and method executed that particular SQL ?
You should be able to right click on that 'fulfillment/submit' row and then drill down into the purepath to get the code level detail (including the class and method) for that particular request.
If that specific method is indeed problematic, I would also recommend you create a measure on it to chart it for more analysis.
Hope that helps,
Right, it's not showing a Class Name since you're looking at the database call itself. Can you look at the call stack leading up to it?
Also taking a closer look at your initial screenshot, it looks like the CXFNonSpringServlet.invoke method is calling that SQL. Can you search for that method in the PurePath tree too and see if anything follows it?
CXFNonSpringServlet.invoke Is the Spring API. Call goes from this Framework class to application but unfortunately its not visible beyond this point. Will you be able to provide some suggestion if I share the Appmon session with you ?
Thanks for the help. PFA Session. The SQL that I am tracing is :-
select storesecti0_.STORE_SECTION_ID as STORE_SE1_1090_0_, storesecti1_.STORE_SECTION_CATEGORY_ID as STORE_SE1_1091_1_, itemcatego2_.ITEM_CATEGORY_ID as ITEM_CAT1_535_2_, itemfacili3_.ITEM_FACILITY_MAPPING_ID as ITEM_FAC1_542_3_, storesecti0_.STORE_SECTION_NAME1 as STORE_SE2_1090_0_, storesecti0_.STORE_SECTION_NAME2 as STORE_SE3_1090_0_, storesecti0_.TC_COMPANY_ID as TC_COMPA4_1090_0_, storesecti0_.FACILITY_ID as FACILITY5_1090_0_, storesecti0_.SECTION_SEQUENCE as SECTION_6_1090_0_, storesecti0_.CATEGORY_TY
So I took a look at your session file. I'm not sure if it is possible to find the exact method/class that is making that SQL call with the current setup. As you can tell, by default, we summarize all database calls in a 'database summary'. As a result, you can't really tell at what point a particular SQL was executed (and the method/calls leading up to it) because all database calls are summarized.
How often are these issues happening? You could consider disabling the database aggregation temporarily (I say temporarily because this is taxing on your AppMon server) and then look at the purepath again and look for the call stack leading up to the SQL call. You can do this by going into the Sensor Configuration of your agent group, clicking on the settings for the JDBC sensor and checking on "No aggregation or bind value capturing".