Documentation
Liferay provides a rich store of resources and knowledge to help our community better use and work with our technology.
Properties Override
This property specifies where to get the overridden properties. By default, it is portal-ext.properties. Updates should not be made in portal.properties or in portal-bundles.properties, but in portal-ext.properties. Furthermore, each portal instance can have its own overridden property file following the convention portal-companyid.properties. For example, one read order might be: portal.properties, then portal-ext.properties, and then portal-test.properties.
The default read order is: portal.properties, portal-bundle.properties, portal-ext.properties, and then portal-setup-wizard.properties.
Examples:
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:
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}