我有这个问题我无法解决。我有一个ext-plugin,它覆盖了我的 portal-ext.rpoperties 文件(我不希望这个覆盖)与另一个空白的 portal-ext 文件。我的ext-plugin中没有 portal-ext.properties 文件,但每次部署时都会发生这种情况。
任何形式的帮助都将受到赞赏。
感谢。
答案 0 :(得分:4)
这是我从Liferay支持部门获得的回复,它解决了我的问题。我在这里分享,这对任何其他人都有帮助。
“您的系统中的portal-ext.properties文件在哪里?
在WEB-INF / classes或$ {liferay.home} /portal-ext.properties?“
如果它在WEB-INF / classes中,只需将portal-ext.properties移动到 $ {liferay.home} /portal-ext.properties 位置即可。如果它是相同的,您可以将 portal-ext.properties 放入EXT插件中,这样原件就会被复制到系统而不是空的。
您还可以在空的 portal-ext.properties 中添加包含和覆盖行,并在 portal-ext.properties 之后重命名要加载的原始文件,或者您可以使用不同的属性文件并将其指定给要加载的JVM。请参阅portal.properties文件中的相关部分:
属性覆盖
#
# Specify where to get the overridden properties. Updates should not be made
# on portal.properties or on portal-bundle.properties, but in
# portal-ext.properties.
#
# The default read order is: portal.properties, portal-bundle.properties,
# portal-ext.properties, and then portal-setup-wizard.properties.
#
include-and-override=portal-bundle.properties
include-and-override=${liferay.home}/portal-bundle.properties
include-and-override=portal-ext.properties
include-and-override=${liferay.home}/portal-ext.properties
include-and-override=portal-setup-wizard.properties
include-and-override=${liferay.home}/portal-setup-wizard.properties
#
# Each portal instance can have its own overriden property file following
# the convention portal-companyWebId.properties. To enable this feature, set
# the "company-id-properties" system property to true.
#
# To enable:
#
# java ... -Dcompany-id-properties=true
#
# The read order will now be: portal.properties, then portal-ext.properties,
# and then portal-liferay.com.properties.
#
# Note that not all properties can have different values per company. This
# functionality is only available for legacy reasons. The preferred way to
# configure a portal instance is through the Control Panel.
#
include-and-override=portal-${easyconf:companyId}.properties
include-and-override=${liferay.home}/portal-${easyconf:companyId}.properties
#
# Additional property files can be used by setting the "external-properties"
# system property.
#
# A common use case is to keep legacy property values when upgrading to
# newer versions of Liferay. To enable:
#
# java ... -Dexternal-properties=portal-legacy-5.1.properties
#
# The read order will now be: portal.properties, then portal-ext.properties,
# and then portal-legacy-5.1.properties.
#
include-and-override=${external-properties}
include-and-override=${liferay.home}/${external-properties}