Results 1 to 5 of 5

Thread: Roo will not regenerate AspectJ files. No error logged.

  1. #1
    Join Date
    Sep 2010
    Location
    Waltham, MA
    Posts
    17

    Default 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:

    Code:
    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:

    Code:
    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. #2
    Join Date
    Dec 2005
    Posts
    930

    Default

    Did you change the @RooEntity annotations to @RooJpaActiveRecord ?
    Alan Stewart
    Spring Roo Committer
    twitter @alankstewart

  3. #3
    Join Date
    Sep 2010
    Location
    Waltham, MA
    Posts
    17

    Default

    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:


    java.lang.NullPointerException
    at org.springframework.roo.process.manager.internal.D efaultProcessManager.logException(DefaultProcessMa nager.java:264)
    at org.springframework.roo.process.manager.internal.D efaultProcessManager.backgroundPoll(DefaultProcess Manager.java:121)
    at org.springframework.roo.process.manager.internal.D efaultProcessManager.timerBasedPoll(DefaultProcess Manager.java:335)
    at org.springframework.roo.process.manager.internal.D efaultProcessManager$2.run(DefaultProcessManager.j ava:83)
    at java.lang.Thread.run(Thread.java:679)
    Last edited by agentgt; Apr 7th, 2012 at 01:50 PM.

  4. #4
    Join Date
    Sep 2010
    Location
    Waltham, MA
    Posts
    17

    Default

    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/Blah.java
    ~.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. #5
    Join Date
    Sep 2010
    Location
    Waltham, MA
    Posts
    17

    Default

    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.

Tags for this Thread

Posting Permissions

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