openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Reiner Lott (Created) (JIRA)" <j...@apache.org>
Subject [jira] [Created] (OPENJPA-2112) NPE during eager-fetching of simple m:n (ManyToMany) relation
Date Wed, 18 Jan 2012 10:29:39 GMT
NPE during eager-fetching of simple m:n (ManyToMany) relation
-------------------------------------------------------------

                 Key: OPENJPA-2112
                 URL: https://issues.apache.org/jira/browse/OPENJPA-2112
             Project: OpenJPA
          Issue Type: Bug
          Components: jpa
    Affects Versions: 2.1.1
            Reporter: Reiner Lott
         Attachments: Eager_Bug.zip

Hi,

in case of ManyToMany eager join unidirectional join, a nullpointer exception is thrown:

Exception in thread "main" <openjpa-2.1.1-r422266:1148538 nonfatal general error> org.apache.openjpa.persistence.PersistenceException:
null
FailedObject: select t from Itemlist t [java.lang.String]
	at org.apache.openjpa.kernel.BrokerImpl.find(BrokerImpl.java:1008)
	at org.apache.openjpa.kernel.BrokerImpl.find(BrokerImpl.java:907)
	at org.apache.openjpa.jdbc.kernel.JDBCStoreManager.load(JDBCStoreManager.java:1041)
	at org.apache.openjpa.jdbc.sql.AbstractResult.load(AbstractResult.java:280)
	at org.apache.openjpa.jdbc.sql.SelectImpl$SelectResult.load(SelectImpl.java:2381)
	at org.apache.openjpa.jdbc.sql.AbstractResult.load(AbstractResult.java:274)
	at org.apache.openjpa.jdbc.kernel.InstanceResultObjectProvider.getResultObject(InstanceResultObjectProvider.java:59)
	at org.apache.openjpa.lib.rop.EagerResultList.<init>(EagerResultList.java:36)
	at org.apache.openjpa.kernel.QueryImpl.toResult(QueryImpl.java:1251)
	at org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:1007)
	at org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:863)
	at org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:794)
	at org.apache.openjpa.kernel.DelegatingQuery.execute(DelegatingQuery.java:542)
	at org.apache.openjpa.persistence.QueryImpl.execute(QueryImpl.java:315)
	at org.apache.openjpa.persistence.QueryImpl.getResultList(QueryImpl.java:331)
	at de.meyerwerft.test.ItemTester.getItemlist_Items(ItemTester.java:102)
	at de.meyerwerft.test.ItemTester.main(ItemTester.java:19)
Caused by: java.lang.NullPointerException
	at org.apache.openjpa.jdbc.kernel.JDBCStoreManager.setInverseRelation(JDBCStoreManager.java:480)
	at org.apache.openjpa.jdbc.kernel.JDBCStoreManager.initializeState(JDBCStoreManager.java:440)
	at org.apache.openjpa.jdbc.kernel.JDBCStoreManager.initialize(JDBCStoreManager.java:333)
	at org.apache.openjpa.kernel.DelegatingStoreManager.initialize(DelegatingStoreManager.java:112)
	at org.apache.openjpa.kernel.ROPStoreManager.initialize(ROPStoreManager.java:57)
	at org.apache.openjpa.kernel.BrokerImpl.initialize(BrokerImpl.java:1027)
	at org.apache.openjpa.kernel.BrokerImpl.find(BrokerImpl.java:985)
	... 16 more


Given relations:

- Itemlist 
- Item 
- Itemlist_Item


Properties set:

			<property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema" />
			<property name="openjpa.RuntimeUnenhancedClasses" value="supported" />




--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message