Skip to content
Snippets Groups Projects
Commit 5a6c108e authored by Joe Freeman's avatar Joe Freeman
Browse files

Added comments when CallMonitoringAspect called

CallMonitoringAspect is not invoked when spring-data-jpa is used.  Spent
4 hours trying to understand why jmx bean wasn't showing message counts.
Use JPA or JDBC if you want call counts exposed via JMX / AOP
parent e8c944f6
No related branches found
No related tags found
No related merge requests found
...@@ -88,10 +88,6 @@ ...@@ -88,10 +88,6 @@
<artifactId>taglibs-standard-jstlel</artifactId> <artifactId>taglibs-standard-jstlel</artifactId>
</dependency> </dependency>
<!-- JSon --> <!-- JSon -->
<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
</dependency>
<dependency> <dependency>
<groupId>com.jayway.jsonpath</groupId> <groupId>com.jayway.jsonpath</groupId>
<artifactId>json-path</artifactId> <artifactId>json-path</artifactId>
......
...@@ -26,6 +26,8 @@ import org.springframework.util.StopWatch; ...@@ -26,6 +26,8 @@ import org.springframework.util.StopWatch;
/** /**
* Simple aspect that monitors call count and call invocation time. It uses JMX annotations and therefore can be * Simple aspect that monitors call count and call invocation time. It uses JMX annotations and therefore can be
* monitored using any JMX console such as the jConsole * monitored using any JMX console such as the jConsole
*
* This is only useful if you use JPA or JDBC. Spring-data-jpa doesn't have any correctly annotated classes to join on
* *
* @author Rob Harrop * @author Rob Harrop
* @author Juergen Hoeller * @author Juergen Hoeller
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
<display-name>Spring PetClinic</display-name> <display-name>Spring PetClinic</display-name>
<description>Spring PetClinic sample application</description> <description>Spring PetClinic sample application</description>
<!-- When using Spring jpa, use the following: -->
<context-param> <context-param>
<param-name>spring.profiles.active</param-name> <param-name>spring.profiles.active</param-name>
<param-value>jpa</param-value> <param-value>jpa</param-value>
...@@ -19,6 +20,7 @@ ...@@ -19,6 +20,7 @@
<param-value>jdbc</param-value> <param-value>jdbc</param-value>
</context-param> --> </context-param> -->
<!-- the CallMonitoringAspect counts invocations on classes with @Repository on them. Classes in spring-data-jpa don't have that annotation -->
<!-- When using Spring Data JPA, uncomment the following: --> <!-- When using Spring Data JPA, uncomment the following: -->
<!-- <!--
<context-param> <context-param>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment