I'm trying to get started with a JUnit4 test of a simple Entity bean and SLSB.
I'm using JARs from the JBoss AS 4.20, Seam 1.2.1, Hibernate 3.2, Hibernate
Annotations 3.3.0, and the Microcontainer 1.02.
Everything works okay when I use the class level sequence generator annotation
on the EB. However, I then tried making an orm.xml file to declare the
sequence generator as an application level sequence. I've had nothing but
trouble with the XML parsing being done when
EJB3StandaloneBootstrap.deployXmlResource() is invoked, like this:
| EJB3StandaloneBootstrap.boot(null);
| EJB3StandaloneBootstrap.deployXmlResource("META-INF/orm.xml");
| EJB3StandaloneBootstrap.scanClasspath("production/EJB");
|
If the XML file looks like this:
| <?xml version="1.0" encoding="UTF-8"?>
| <entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm"
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| version="1.0">
| <sequence-generator name="app_sequence" sequence-name="APP_SEQ"/>
| </entity-mappings>
|
I get the following RuntimeException when deployXmlResource is called:
| java.lang.RuntimeException: org.jboss.xb.binding.JBossXBException: Failed
to parse source: file:/E:/data/.../classes/production/EJB/META-INF/[EMAIL
PROTECTED],68
|
I tried using a non-XSD form of the XML like I've seen in many examples:
| <?xml version="1.0" encoding="UTF-8"?>
| <entity-mappings>
| <sequence-generator name="app_sequence" sequence-name="APP_SEQ"/>
| </entity-mappings>
|
But I get the same RuntimeException when deployXmlResource is called.
The XML is just so simple, I'm amazed there's a problem with it. I'm hoping
someone can point me to the right path to look for the cause of the problem and
possible workarounds.
TIA
--
jack
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4046970#4046970
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4046970
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user