Skip to content

Instantly share code, notes, and snippets.

@sammso
Last active June 19, 2018 17:05
Show Gist options
  • Save sammso/23e6abb38f63e8e0a461ccb11da9546e to your computer and use it in GitHub Desktop.
Save sammso/23e6abb38f63e8e0a461ccb11da9546e to your computer and use it in GitHub Desktop.

Add following to portal properties

ehcache.multi.vm.config.location=/liferay-multi-vm-clustered-eternal.xml

Create new confguration file at <liferay-home>/tomcat-xx/webapps/ROOT/WEB-INF/classes/liferay-multi-vm-clustered-eternal.xml with content

<ehcache
	dynamicConfig="true"
	monitoring="off"
	name="liferay-multi-vm-clustered"
	updateCheck="false"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:noNamespaceSchemaLocation="ehcache.xsd"
>

	<!--
	Caches in this file can be clustered and are configured to be clustered.
	-->

	<defaultCache
		eternal="true"
		maxElementsInMemory="100000"
		overflowToDisk="false"
		timeToIdleSeconds="600"
	>
	</defaultCache>

	<!-- Entity cache -->

	<cache
		eternal="true"
		maxElementsInMemory="100000"
		name="com.liferay.portal.kernel.dao.orm.EntityCache.com.liferay.portal.model.impl.AccountImpl"
		overflowToDisk="false"
		timeToIdleSeconds="600"
	></cache>
</ehcache>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment