Tomcat 理解 amq:broker 但 Eclipse 在模式中标记错误
在 Eclipse 中使用 ActiveMQ 时,有时可能会遇到如下模式解析错误:
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.c:
The matching wildcard is strict, but no declaration can be found for element 'amq:broker'.
但是,该项目在 Tomcat 中部署成功。
When working with ActiveMQ in Eclipse, you might sometimes get a schema parsing error as such:
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.c:
The matching wildcard is strict, but no declaration can be found for element 'amq:broker'.
However, the project deploys successfully in Tomcat.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要解决此问题,您必须将 ActiveMQ XSD URL 与架构相关联。
转到“首选项”中的“XML”->“XML 目录”,然后添加“用户指定的条目”。
然后添加第二个:
点击“确定”。
如果您遇到同样的错误并且 Tomcat 失败,请打开触发该错误的 applicationContext-jms.xml 文件并将:替换
为
To fix this, you must associate the ActiveMQ XSD URL with the schema.
Go to XML->XML Catalog in Preferences, and add a User Specified Entry.
Then add a second one:
Hit OK.
If you have this same error and Tomcat fails, open the applicationContext-jms.xml file which triggers the error and replace:
with