Announcement Announcement Module
No announcement yet.
AOP Benchmark on performance Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • AOP Benchmark on performance

    Dear all,

    I want to commit on Spring AOP for my projects.

    However, before I can do that, can anyone help me to
    answer the performance figures in
    which regards Spring AOP with slowest performance?


  • #2

    The first thing to consider, is exactly what you plan to use AOP for. If you want to use it system wide for a large number of fine-grained aspects, then AspectJ might be better for you.

    If you are planning to use AOP for coarse-grained services such as transaction management or security then Spring is the way to go. If you want to use AOP for both - use AspectJ and Spring. Plus, with Spring you can configure you AspectJ aspects as well as your Spring aspects.

    On the performance side of things, you should note that for Spring, the performance is not particularly important and is really only a fraction of the business processing you'll be adding using AOP. For example, consider the case of transaction management where the AOP overhead is so small as to be unnoticeable.

    In the end, Spring AOP is VERY easy to use and debug in any environment. If you are only using AOP selectively then use Spring. Be wary of setting some standard for AOP framework performance before actually measuring the performance of your application with AOP running.

    If you are really worried about performance, then you can use Spring to start with and migrate to AspectWerkz later using the same AOP Alliance aspects that you used for Spring.