Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 330603 - NPE when specifying the value of joinColumns element for JoinTable
Summary: NPE when specifying the value of joinColumns element for JoinTable
Status: RESOLVED FIXED
Alias: None
Product: Dali JPA Tools
Classification: WebTools
Component: General (show other bugs)
Version: 2.3.2   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 3.0 M2   Edit
Assignee: Neil Hauge CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-18 14:44 EST by Nan Li CLA
Modified: 2010-11-19 09:19 EST (History)
3 users (show)

See Also:


Attachments
stack trace_joinColumns_JoinTable (4.26 KB, text/plain)
2010-11-18 14:46 EST, Nan Li CLA
no flags Details
stack trace_inverseJoinColumns_JoinTable (4.28 KB, text/plain)
2010-11-18 14:48 EST, Nan Li CLA
no flags Details
stack trace_joinColumns_CollectionTable (4.33 KB, text/plain)
2010-11-18 14:49 EST, Nan Li CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nan Li CLA 2010-11-18 14:44:53 EST
Build Identifier: 20100917-0705

An NPE is thrown to Error Log view when trying to specifying the value of joinColumns for JoinTable annotation. At that moment, the annotation is like @JoinTable(joinColumns = ). 

Same issue exists with the inverseJoinColumns element of JoinTable annotation and the joinColumns element of CollectionTable annotation.

Reproducible: Always

Steps to Reproduce:
1. Apply @JoinTable annotation to an attribute of a Java entity
2. Specify the joinColumns element of JoinTable annotation
3. Trying to specifying the value of the joinColumns element
Comment 1 Nan Li CLA 2010-11-18 14:46:49 EST
Created attachment 183416 [details]
stack trace_joinColumns_JoinTable
Comment 2 Nan Li CLA 2010-11-18 14:48:15 EST
Created attachment 183417 [details]
stack trace_inverseJoinColumns_JoinTable
Comment 3 Nan Li CLA 2010-11-18 14:49:04 EST
Created attachment 183418 [details]
stack trace_joinColumns_CollectionTable
Comment 4 Neil Hauge CLA 2010-11-18 17:40:36 EST
Not able to reproduce this in head, but I can reproduce in maintenance.  My guess is this has been fixed in head.  Nan, please try to verify with the following build:

http://build.eclipse.org/webtools/committers/wtp-R3.3.0-I/20101118132500/I-3.3.0-20101118132500/
Comment 5 Brian Vosburgh CLA 2010-11-18 18:18:28 EST
I believe Karen fixed this NPE in just the last couple of months. Probably with the check-in of AnnotationContainerTools 1.8 on 10 Sep 2010. There is a similar problem in bug 323005 that was fixed in both maintenance and HEAD in August.
Comment 6 Neil Hauge CLA 2010-11-19 09:19:49 EST
Sounds good.  Marking as fixed in M2.  Please reopen if reproduced in Head.