[jboss-cvs] JBossAS SVN: r100559 - branches/JBPAPP_5_0/connector/src/main/org/jboss/resource/deployers.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Fri Feb 5 12:47:42 EST 2010
Author: darran.lofthouse at jboss.com
Date: 2010-02-05 12:47:42 -0500 (Fri, 05 Feb 2010)
New Revision: 100559
Modified:
branches/JBPAPP_5_0/connector/src/main/org/jboss/resource/deployers/ManagedConnectionFactoryParserDeployer.java
Log:
[JBPAPP-3679] Regression - org.jboss.test.jca.test.JDBCStatementTestsConnectionUnitTestCase
Relax -ds.xml validation to previous level to only fail on 'Fatal Errors'.
Modified: branches/JBPAPP_5_0/connector/src/main/org/jboss/resource/deployers/ManagedConnectionFactoryParserDeployer.java
===================================================================
--- branches/JBPAPP_5_0/connector/src/main/org/jboss/resource/deployers/ManagedConnectionFactoryParserDeployer.java 2010-02-05 17:44:35 UTC (rev 100558)
+++ branches/JBPAPP_5_0/connector/src/main/org/jboss/resource/deployers/ManagedConnectionFactoryParserDeployer.java 2010-02-05 17:47:42 UTC (rev 100559)
@@ -28,6 +28,8 @@
import javax.xml.bind.JAXBContext;
import javax.xml.bind.JAXBElement;
import javax.xml.bind.Unmarshaller;
+import javax.xml.bind.ValidationEvent;
+import javax.xml.bind.ValidationEventHandler;
import javax.xml.transform.sax.SAXSource;
import org.jboss.deployers.spi.DeploymentException;
@@ -110,7 +112,18 @@
protected ManagedConnectionFactoryDeploymentGroup parse(VFSDeploymentUnit unit, VirtualFile file, ManagedConnectionFactoryDeploymentGroup root) throws Exception
{
//TODO do we need to this every time?
- Unmarshaller um = context.createUnmarshaller();
+ Unmarshaller um = context.createUnmarshaller();
+ um.setEventHandler(new ValidationEventHandler()
+ {
+
+ public boolean handleEvent(ValidationEvent event)
+ {
+ int severity = event.getSeverity();
+ return (severity != ValidationEvent.FATAL_ERROR);
+ }
+
+ });
+
InputStream is = file.openStream();
try
More information about the jboss-cvs-commits
mailing list