繁体   English   中英

无法在Liferay中部署WAR文件

[英]Unable to deploy WAR file in liferay

有一个WAR文件。

我可以将其部署到tomcat7,而不会出现任何错误。 但是,当尝试将其部署到与tomcat捆绑在一起的Liferay时,会发生此错误:

11:04:37,739 ERROR [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:210] com.liferay.portal.kernel.deploy.auto.AutoDeployException: com.liferay.portal.kernel.xml.Docume
ntException: Error on line 1 of document  : The value following "version" in the XML declaration must be a quoted string. Nested exception: The value following "version" in the XML declaratio
n must be a quoted string.
com.liferay.portal.kernel.deploy.auto.AutoDeployException: com.liferay.portal.kernel.xml.DocumentException: Error on line 1 of document  : The value following "version" in the XML declaration
 must be a quoted string. Nested exception: The value following "version" in the XML declaration must be a quoted string.
        at com.liferay.portal.tools.deploy.BaseDeployer.autoDeploy(BaseDeployer.java:201)
        at com.liferay.portal.deploy.auto.PortletAutoDeployListener.deploy(PortletAutoDeployListener.java:84)
        at com.liferay.portal.kernel.deploy.auto.AutoDeployDir.processFile(AutoDeployDir.java:193)
        at com.liferay.portal.kernel.deploy.auto.AutoDeployDir.scanDirectory(AutoDeployDir.java:235)
        at com.liferay.portal.kernel.deploy.auto.AutoDeployScanner.run(AutoDeployScanner.java:54)
Caused by: com.liferay.portal.kernel.xml.DocumentException: Error on line 1 of document  : The value following "version" in the XML declaration must be a quoted string. Nested exception: The 
value following "version" in the XML declaration must be a quoted string.
        at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:399)
        at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:378)
        at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:409)
        at com.liferay.portal.kernel.xml.SAXReaderUtil.read(SAXReaderUtil.java:155)
        at com.liferay.portal.tools.WebXMLBuilder.organizeWebXML(WebXMLBuilder.java:60)
        at com.liferay.portal.tools.deploy.BaseDeployer.updateWebXml(BaseDeployer.java:2078)
        at com.liferay.portal.tools.deploy.BaseDeployer.deployDirectory(BaseDeployer.java:576)
        at com.liferay.portal.tools.deploy.BaseDeployer.deployFile(BaseDeployer.java:957)
        at com.liferay.portal.tools.deploy.BaseDeployer.deployFile(BaseDeployer.java:889)
        at com.liferay.portal.tools.deploy.BaseDeployer.autoDeploy(BaseDeployer.java:198)

在解压缩的WAR归档文件根目录中执行以下命令:$ grep version = [^ \\“] -r提供以下结果:

WEB-INF/i3-label.properties:file.reversion=Version History
WEB-INF/classes/web/zssapp/labels/i3-label.properties:file.reversion=Version History
WEB-INF/classes/web/zssapp/labels/i3-label_zh_TW.properties:file.reversion=版本歷史
WEB-INF/i3-label_zh_TW.properties:file.reversion=版本歷史
WEB-INF/liferay-plugin-package.properties:module-incremental-version=1

有想法吗?

尝试打开LR部署过程使用的所有XML文件(例如portlet.xml,liferay-portlet.xml等),并验证第一行。 它应该有一些错误(引号,双引号,属性或其他内容...)。

尝试将其与新的LR项目(或LR SVN存储库中的某些示例)进行比较。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM