Results 1 to 4 of 4

Thread: Using Spring AOP module in NON-SPRING projects

  1. #1
    Join Date
    Aug 2005
    Posts
    17

    Default Using Spring AOP module in NON-SPRING projects

    We need to add some transaction logging features in our business layer which is based on EJB 2.0 (non-spring service based architecture). I was wondering if we could use the Spring AOP module to implement such a thing instead of using AspectJ. The problem is that our beans are NOT YET managed by Spring.

    Any ideas?
    Thanks,

    lucas_opara@hotmail.com

  2. #2
    Join Date
    Aug 2004
    Location
    Southampton, UK
    Posts
    826

    Default

    You can use Spring AOP outside of Spring managed projects, however, you can only do this when you have full control over object creation. For EJBs this isn't going to be the case so you would be better off using AspectJ for that. You can still use Spring to configure your AspectJ aspects if you need to supply some configuration data or some collaborating objects.

    Rob
    Rob Harrop
    Lead Engineer, dm Server
    SpringSource
    http://www.springsource.com

    Co-Author - Pro Spring

  3. #3
    Join Date
    Aug 2005
    Posts
    1

    Default

    Do u think u can drop the proxy,I think not,

  4. #4
    Join Date
    Aug 2004
    Location
    Southampton, UK
    Posts
    826

    Default

    We *could* drop the proxy but it would be very difficult to get consistent runtime proxying given the current state of Java VMs. We can configure AspectJ aspects at runtime and in 1.3 this integration will be much improved.

    Rob
    Rob Harrop
    Lead Engineer, dm Server
    SpringSource
    http://www.springsource.com

    Co-Author - Pro Spring

Similar Threads

  1. Spring MVC Web Framework versus Struts
    By biguniverse in forum Web Flow
    Replies: 27
    Last Post: Aug 29th, 2012, 03:57 AM
  2. Replies: 5
    Last Post: Aug 9th, 2008, 05:30 AM
  3. A Spring Class Loader?
    By azzoti in forum Architecture
    Replies: 8
    Last Post: May 7th, 2005, 04:02 AM
  4. Replies: 14
    Last Post: Feb 21st, 2005, 05:41 PM
  5. Replies: 7
    Last Post: Oct 20th, 2004, 08:23 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •