Issue Details (XML | Word | Printable)

Key: NUCENHANCER-43
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Andy Jefferson
Reporter: Skyer Tu
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
DataNucleus Enhancer (ARCHIVED)

Support JPA enhancement for JDK1.6 Enhancer Processor

Created: 27/Aug/09 09:39 AM   Updated: 13/Nov/10 12:19 PM   Resolved: 08/Nov/10 10:22 AM
Component/s: None
Affects Version/s: 2.0.0.m1
Fix Version/s: 2.1.2

File Attachments: 1. Java Source File EnhancerProcessor.java (8 kB)

Environment: jdk1.6.0_07

Severity: Development


 Description  « Hide
The JDK1.6 Enhancer Processor always use JDO as Enhancer API, so it cannot be used for JPA annotations.
This is because EnhancerProcessor always creates a default DataNucleusEnhancer("JDO", "ASM")

I suggest to use a processor option ( "enhanceAPI" ) to specify the API.

for example:
 javac -AenhanceAPI=JPA ....


Sort Order: Ascending order - Click to sort in descending order
Skyer Tu added a comment - 27/Aug/09 09:42 AM
Sample fix based on 1.1.4 source code.

Here I also specified the SupportedAnnotationTypes so that only annotationed classes will be enhanced.

Andy Jefferson added a comment - 08/Nov/10 10:22 AM
SVN trunk has the option for enhancer api. Thx