-
Apr 26th, 2011, 04:28 AM
#1
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.
-
Apr 26th, 2011, 05:43 AM
#2
Please try with the latest 1.1.4.BUILD-SNAPSHOT
-
Apr 26th, 2011, 06:17 AM
#3
Actually, I recall "Employee" was accidentally hard-coded in in JavaBeanMetadata and was resolved in https://jira.springsource.org/browse/ROO-1983. Thus 1.1.2, 1.1.3 or snapshots of 1.1.4 (I recommend) will resolve your problem
-
Apr 27th, 2011, 04:08 AM
#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.
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
-
Forum Rules