Announcement Announcement Module
No announcement yet.
Weird error in _JavaBean.aj Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Weird error in _JavaBean.aj

    I'm so frustrated. Seems like all the time Roo saves you to begin with you spend dealing with issues.

    I had several problems in my project I started a couple days ago, so I decided to rebuild it from scratch using the roo log.

    Now an association that was working before is doing something weird. It is defined like:

    @OneToMany(cascade = CascadeType.ALL)
    private Set<Reply> replies = new HashSet<Reply>();

    But in the generated javabean .aj there is this:

    public void Conversation.setReplies(Set<Reply> replies) {
    for (Employee entity : replies) {
    if (!longIds.contains(entity.getId())) {

    which results in compilation errors since Employee is not a class in my project, and in fact the string 'Employee' doesn't appear anywhere else.

    I can fix the error, but obviously it comes back as soon as I edit my bean.

    This is a GAE/DataNucleus project.

    Thanks in advance.

  • #2
    Please try with the latest 1.1.4.BUILD-SNAPSHOT


    • #3
      Actually, I recall "Employee" was accidentally hard-coded in in JavaBeanMetadata and was resolved in Thus 1.1.2, 1.1.3 or snapshots of 1.1.4 (I recommend) will resolve your problem


      • #4
        Thanks for your prompt reply. I can't get to try your fix right now, but indeed I am using 1.1.1.RELEASE [rev 156ccd6] so you are probably correct.