Have you used Perf4J to collect and analyze performance metrics in Java app?

Viewed 7518

Did you use Perf4J in your Java application to collect and analyze performance stats?

What was the typical pattern (using log files, utilities, UI, JMX, etc.)?

Did you use annotations and AOP-based features?

Did you use any JMX integration?

How did you handle production configuration?

Did you include performance stats views/reports as a feature in your application?

Please tell if and why you decided on alternative library/approach.

3 Answers

I've used Perf4J, and eventually ditched it because I was already using Spring AOP. I would love to simply integrate the two , but was having trouble with it (because of the Perf4J appenders).

I tried to use Perf4j through annotations and AOP without JMX. You can handle production cfg through configuration files.

Overall, I liked the Perf4j approach but since I was already using Spring for performance monitoring I didn't need perf4j. One thing that Perf4j gives for free is the min/max/standard dev; with other libs you would have to do the math yourself.

I thing perf4j is nice if you don't have any other lib that can provides interception (aspectJ or AOP), but since I already had spring it was easier to implement performance measurement. You can easily expose bean properties through JMX with Spring.

Related