Bug 384848 - After the Refractor=>PushIn in Eclipse, AspectJ will apply multiple times for the 'declare parents' action.
Summary: After the Refractor=>PushIn in Eclipse, AspectJ will apply multiple times for...
Status: NEW
Alias: None
Product: AJDT
Classification: Tools
Component: Core (show other bugs)
Version: 2.2.0   Edit
Hardware: PC Linux
: P3 major (vote)
Target Milestone: 2.2.4   Edit
Assignee: AJDT-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-11 13:00 EDT by Wai-Tak Wong CLA
Modified: 2013-07-03 15:41 EDT (History)
2 users (show)

See Also:


Attachments
project before push in the inter type (430.00 KB, application/octet-stream)
2012-07-11 13:00 EDT, Wai-Tak Wong CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Wai-Tak Wong CLA 2012-07-11 13:00:25 EDT
Created attachment 218583 [details]
project before push in the inter type

After using Spring Roo to generate the entities, there are some AspectJ files.
According to the Spring instruction, we perform the Push in in the Spring STS (Eclipse), the "declare parents" action will apply multiple times. It seems to be a nested matching because of other 'declare type' statements in other Aspect j file.

The content of the file with the 'declare parents' 
privileged aspect RoleprivilegePK_Roo_Serializable {
    
    declare parents: RoleprivilegePK implements Serializable;
    
    private static final long RoleprivilegePK.serialVersionUID = 1L;
    
}

The result after the Push in
public final class RoleprivilegePK implements Serializable implements Serializable implements Serializable implements Serializable {
。。。。。
}

If I apply the push in for the AspectJ file with the 'declar parents' first, and other next. Then there is no issue for the pushed-in file.
It seems to be a AspectJ issue instead of the Spring Roo issue.

Since this step is needed to be performed quite frequently due to the database schema modification, please count as a major bug.

Project with the sample source file is attached.
Comment 1 Andrew Eisenberg CLA 2012-09-21 14:00:07 EDT
Consider for 2.2.2.
Comment 2 Andrew Eisenberg CLA 2013-02-22 13:56:35 EST
Moving to 2.2.3.
Comment 3 Andrew Eisenberg CLA 2013-07-03 15:41:45 EDT
Consider for the 2.2.4 release.