Announcement Announcement Module
Collapse
No announcement yet.
Run time advice for non spring managed beans Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Run time advice for non spring managed beans

    This is a cross post, as I put it originally in the core forum.

    I have a service that loads an object that models a hierarchical tree (i.e. a Tree
    object, with Nodes on it).

    Once the object is loaded I call a method on it and it recurses through nodes, calling methods on the nodes.

    Say that each node has a method called "process()" on it.

    Is there any easy way of adding advice at run time to each of these nodes, so that I can add logging before each call to process() or any other method I want to run on the node ?

  • #2
    Yes you can or create this nodes with a ProxyFactory or a simple none intrusive approach that is using RegExp Pointcuts

    http://static.springframework.org/sp...ntcuts-aspectj

    Comment


    • #3
      Originally posted by Paul Newport View Post
      This is a cross post, as I put it originally in the core forum.

      I have a service that loads an object that models a hierarchical tree (i.e. a Tree
      object, with Nodes on it).

      Once the object is loaded I call a method on it and it recurses through nodes, calling methods on the nodes.

      Say that each node has a method called "process()" on it.

      Is there any easy way of adding advice at run time to each of these nodes, so that I can add logging before each call to process() or any other method I want to run on the node ?
      What do you mean by "non spring managed beans"?

      Comment

      Working...
      X