Apache Commons EmailValidator 和 SeamListener 异常(未部署)
通过 Maven 使用 Apache Commons EmailValidator 时,我遇到以下问题,无法部署我的应用程序:
Exception sending context initialized event to listener instance of class org.jboss.seam.servlet.SeamListener
java.lang.LinkageError: loader constraints violated when linking org/xml/sax/EntityResolver class
我在 pom.xml 中使用了以下代码:
<dependency>
<groupId>commons-validator</groupId>
<artifactId>commons-validator</artifactId>
<version>1.3.1</version>
</dependency>
有帮助吗?
When using Apache Commons EmailValidator through Maven, I have the following problem that doesn't deploy my app:
Exception sending context initialized event to listener instance of class org.jboss.seam.servlet.SeamListener
java.lang.LinkageError: loader constraints violated when linking org/xml/sax/EntityResolver class
I've used the following code at my pom.xml:
<dependency>
<groupId>commons-validator</groupId>
<artifactId>commons-validator</artifactId>
<version>1.3.1</version>
</dependency>
One help?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
commons-validator-1.3.1.jar
工件拉取xml-apis-1.0.b2.jar
,如下所示:LinkageError
表明在 JBoss 上部署时,您在类路径上有xml-apis-1.0.b2.jar
的重复版本,这是一个明显的可疑之处。也许只是尝试将其从已部署的应用程序中排除(无法以当前的详细程度给出更准确的答案)。
The
commons-validator-1.3.1.jar
artifact pullsxml-apis-1.0.b2.jar
as shown below:The
LinkageError
suggests that you have duplicate versions ofxml-apis-1.0.b2.jar
, which is an obvious suspect here, on the classpath when deploying on JBoss.Maybe simply try to exclude it from the deployed application (can't give a more precise answer with the current level of details).