OpenXava4.6でポートレットを作成しました。ただし、Liferay 6.1.1 CE GAでデプロイすると、正しく実行されません。
これらは問題です:
a。)OX 4.5.1および4.6で作成されたweb.xmlは、Liferay6.1で認識されません。
15:23:28,665 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:182] Processing <..>.war. This is attempt 2.
15:23:28,673 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][PortletAutoDeployListener:77] Copying portlets for ../liferay-portal-6.1.1-ce-ga2/deploy/<..>.war
15:23:28,676 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][BaseDeployer:1674] ../liferay-portal-6.1.1-ce-ga2/deploy/<..>.war does not have a WEB-INF/liferay-plugin-package.xml or WEB-INF/liferay-plugin-package.properties
15:23:28,677 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][BaseDeployer:763] Deploying <..>.war
15:23:33,110 ERROR [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:210] com.liferay.portal.kernel.deploy.auto.AutoDeployException: com.liferay.portal.kernel.deploy.auto.AutoDeployException: web.xml must be updated to the Servlet 2.4 specification
b。)web.xmlファイルには次のヘッダーが必要です。
<?xml version="1.0" encoding="UTF-8"?>
<web-app id=".." version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
<http://java.sun.com/xml/ns/j2ee%5C>" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance\
<http://www.w3.org/2001/XMLSchema-instance%5C>"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd\
<http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd%5C>">
<display-name>...</display-name>
...
c。)上記のように「web.xml」ファイルを変更した後(および新しいWARファイルを作成した後でも)、Liferayはポートレットをロードでき、使用可能なポートレットのリストに表示されます。ただし、ポートレットは機能しません。
15:35:01,457 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][PortletAutoDeployListener:87] Portlets for ../liferay-portal-6.1.1-ce-ga2/deploy/<..>.war copied successfully. Deployment will start in a few seconds.
15:35:04,651 INFO [pool-2-thread-2][HotDeployImpl:178] Deploying <..> from queue
15:35:04,653 INFO [pool-2-thread-2][PluginPackageUtil:1033] Reading plugin package for <..>
15:35:04,653 WARN [pool-2-thread-2][PluginPackageUtil:1131] Plugin package on context <..> cannot be tracked because this WAR does not contain a liferay-plugin-package.xml file
d。)ファイル「liferay-plugin-package.xml」をWARファイルに手動で追加しましたが、Liferayはまだポートレットを正しく表示しません。
どんな提案も歓迎します。ありがとう。