2 Replies Latest reply on Mar 31, 2004 12:21 AM by oz59

    Is anyone debugging with AOP?

    brainjava

      I've been wanting to get into AOP, but I have so many questions. I guess the main question is how does debugging work? Usually a debugger loads the class and the ide then steps through the code based on the source files it has available. IDE's figure this out by the class name, so does this all work out the same way? I mean, say I'm using Netbeans and I have included a bunch of Aspects. Can I then step through the Aspects as well as my code? It seems like the code the debugger thinks it has would be way out of sync with the code in the source files. Does anyone have a clear answer?

      Thank you,

      Wade

        • 1. Re: Is anyone debugging with AOP?
          bill.burke

          With JBoss-AOP you write your aspects/advices/interceptors as Plain java classes. There is only a tiny bit of bytecode manipulation that happens. When using a debugger, you may have to hit StepInto a few times before you get to your advice/aspect code, and/or your real methods.

          In short, debuggers should work fine.

          Bill

          • 2. Re: Is anyone debugging with AOP?

             

            "Bill Burke" wrote:

            In short, debuggers should work fine.

            I just verified this with some mods made to the JBossIDE. At this point in my prototype, breakpoints needed to literally be set on the Interceptor(s) to enable debug functionality. I haven't looked too deeply into stepping from constructor/method callers to yield Interceptor src yet, but as stated, explicit Interceptor breakpoints work.

            env:
            win2k pro.
            jdk 1.4.2_03 using -server -Xms128m -Xmx512m
            eclipse 2.1.3
            jboss-4.0.0DR3

            thanks and best regards.