[ROO-3587] Entity implementing interface with getId(): double generation Created: 15/Jan/15  Updated: 22/Feb/16  Resolved: 24/Jun/15

Status: Resolved
Project: Spring Roo
Affects Version/s: 1.3.1.RC2, 1.3.1.RELEASE
Fix Version/s: 2.0.0.M2

Type: Bug Priority: Critical
Reporter: Markus Strenn Assignee: Juan Carlos García del Canto
Resolution: Complete Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Java 7


it's me again, annother bug joining ROO-3585 and ROO-3584...


public interface DemoInterface {
	public Long getId();

Entity Bean:

public class DemoEntity implements DemoInterface {

    private String name;

results in getId() generated in DemoEntity_Roo_Jpa_Entity.aj AND in DemoEntity_Roo_JavaBean.aj, too. (of course resulting in an compile error.

Comment by Frank Spies [ 09/Mar/15 ]

the getId()-method in DemoEntity_Roo_Java.aj always returns null:

 public Long DemoEntity.getId() {
        return null;
Comment by Frank Spies [ 09/Mar/15 ]

FWIW, I think this should be a blocker - anyone who has anntated their classes with both @RooJavaBean
and @RooJpaActiveRecord won't be able to use them.

Comment by Markus Strenn [ 16/Jun/15 ]

@jcagarcia you wanted to take care of this issue in a fix-version 1.3.2... any plans to fix this error - it's very critical - in our project a blocker!

Comment by Juan Carlos García del Canto [ 24/Jun/15 ]

Hi Markus,

This issue was fixed and will be available on Spring Roo 2.0.0.M2 version.

I've tested that changes made in on ROO-3584 and ROO-3585 are still working!

Here's is the commit with the applied changes:


And here's the build process that tests that is working correctly:


If you have some other question or bug report.. let me know!!

Best regards and thanks for your contributions!!

Comment by Markus Strenn [ 14/Dec/15 ]

hi juan,

I can confirm that this issue is fixed on 1.3.2.RELEASE

best regards!

Comment by Juan Carlos García del Canto [ 15/Dec/15 ]

Thank you Markus for your reported issues.


Generated at Wed Oct 23 00:25:17 UTC 2019 using Jira 7.13.8#713008-sha1:1606a5c1e7006e1ab135aac81f7a9566b2dbc3a6.