Announcement Announcement Module
No announcement yet.
Roo will not regenerate AspectJ files. No error logged. Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Roo will not regenerate AspectJ files. No error logged.

    We recently upgraded from Roo 1.1.5 to 1.2.1 .

    Roo will not regenerate AspectJ files unless you explicetly tell it to. That is I have to add a dummy field as a work around for Roo to start tracking the entity for future updates.

    For example if went into my project and did:

    bash$ find . -name "*.aj" | xargs rm
    And then boot up roo. Nothing will happen. For new projects it works fine but for my existing project nothing gets updated even if I do:

    roo>poll now
    Whats most annoying is I have seen this behavior before where Roo will just stop updating the aspectj files with no error logged.
    In the past I have to manually delete code till it worked and its usually been either an abstract class or some weird inner class that's caused the problem. It would be nice if Roo just told me which class it was barfing on.

    Is there anyway to turn on debugging for Roo?

  • #2
    Did you change the @RooEntity annotations to @RooJpaActiveRecord ?


    • #3
      Yep I changed all of them. And it still did not work.

      Presumably there is a logger (slf4j or similar) for Roo?

      I am wonder if its trying to report an error but cannot because of the already filed NPE exception:

      at org.springframework.roo.process.manager.internal.D efaultProcessManager.logException(DefaultProcessMa
      at org.springframework.roo.process.manager.internal.D efaultProcessManager.backgroundPoll(DefaultProcess
      at org.springframework.roo.process.manager.internal.D efaultProcessManager.timerBasedPoll(DefaultProcess
      at org.springframework.roo.process.manager.internal.D efaultProcessManager$ ava:83)
      Last edited by agentgt; Apr 7th, 2012, 01:50 PM.


      • #4
        This is getting ridiculous.

        I deleted all of the code. That is I did rm -rf src/main/java
        Now the only thing in my project is my original pom file which does get upgraded and my spring config files.

        Now I create an entity.

        roo> entity jpa --class com.stuff.domain.Blah
        Created src|ROOT/main/java/com/stuff/domain/
        ~.domain.Blah roo> field string stuff
        The type specified, 'com.stuff.domain.Blah'doesn't exist
        ~.domain.Blah roo>

        I tried this on the nightly and release build.


        • #5
          Finally figured it out. There were 3 issues that were causing the problem.

          * We had a pom.xml file in a subdirectory. For some reason this caused most of the pain.
          * We also had a class with three levels of inner classes. Roo did not like this.
          * Finally the NPE bug was also keeping the logging of the previous problems hidden.