openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dain Sundstrom <d...@iq80.com>
Subject Mappings for non-existant classes
Date Tue, 30 Jan 2007 20:27:33 GMT
I have a mapping file that contains mappings for some classes that  
don't exist (at least in my current testcase).  I expect that openjpa  
would ignore these mappings (maybe print a warning) but instead I get  
an exception:

Caused by: org.xml.sax.SAXException: file:/Users/dain/work/openejb/ 
trunk/openejb3/itests/openejb-itests-beans/target/classes/META-INF/ 
jpa.mapping.xml [Location: Line: 69, C: 93]: Type  
"org.apache.openejb.test.entity.cmp.BasicCmp2Bean_JPA" could not be  
instantiated.
	at org.apache.openjpa.lib.meta.XMLMetaDataParser.getException 
(XMLMetaDataParser.java:649)
	at org.apache.openjpa.lib.meta.CFMetaDataParser.classForName 
(CFMetaDataParser.java:281)
	at  
org.apache.openjpa.persistence.XMLPersistenceMetaDataParser.classForName 
(XMLPersistenceMetaDataParser.java:1632)
	at  
org.apache.openjpa.persistence.XMLPersistenceMetaDataParser.startClass 
(XMLPersistenceMetaDataParser.java:708)
	at org.apache.openjpa.lib.meta.CFMetaDataParser.startElement 
(CFMetaDataParser.java:102)
	at org.apache.openjpa.lib.meta.XMLMetaDataParser.startElement 
(XMLMetaDataParser.java:426)
	at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown  
Source)
	at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown  
Source)
	at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement 
(Unknown Source)
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl 
$FragmentContentDispatcher.dispatch(Unknown Source)
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument 
(Unknown Source)
	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
	at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
	at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
	at org.apache.openjpa.lib.meta.XMLMetaDataParser.parseNewResource 
(XMLMetaDataParser.java:370)
	... 62 more


Is this the way it is supposed to work?

-dain

Mime
View raw message