EntityToHibernateXml: catch NPE and throw a more descriptive Exception
----------------------------------------------------------------------
Key: EJBTHREE-104
URL: http://jira.jboss.com/jira/browse/EJBTHREE-104
Project: EJB 3.0
Type: Feature Request
Versions: Preview 4
Environment: Linux, JDK 1.5, JBoss 4.0.1sp1
Reporter: Jens Elkner
Priority: Minor
jboss.log:
...
02:31:01,786 INFO [Ejb3Module] Found hibernate.properties file in EJB3 jar or
ear
02:31:01,797 ERROR [Ejb3Module] Starting failed
jboss.j2ee:service=EJB3,module=foo.ejb3
java.lang.NullPointerException
at
org.jboss.ejb3.entity.EntityToHibernateXml.handleOneToMany(EntityToHibernateXml.java:845)
at
org.jboss.ejb3.entity.EntityToHibernateXml.iterateProperties(EntityToHibernateXml.java:220)
at
org.jboss.ejb3.entity.EntityToHibernateXml.handleBasicClass(EntityToHibernateXml.java:1822)
...
Would be nice, if the NPE could be caught and re-throw a more descriptive
Exception, so that one gets a hint, what might be wrong. In my example it was a
typo in the mappedBy value, but who knows, what else might be the cause ...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
JBoss-Development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-development