Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Eduardo P García
Clustering - EhCache Replication
June 3, 2011 2:00 AM
Answer

Eduardo P García

Rank: New Member

Posts: 10

Join Date: October 1, 2009

Recent Posts

Hi there,

We have displayed a clustered Liferay 6.0.4 CE installation with ehcache set in multi-vm-clustered mode. When we run performance tests (i.e. load simulation with Jmeter), we observe that:

1. There is too much traffic between the members of the cluster. We guess this is due to replication, but CPU is hight everytime. It seems replication never stops, despite we make no changes in the portal... We are using default RMI replication.

2. Having a look at Ehcache Beans status using VisualVM, we find that some beans (especially com.liferay.portal.velocity.LiferayResourceCacheUtil) have too many cache misses.

3. Adding extra nodes actually seems to decrease the overall performance of the system.

Anyone with experience in such issues could please provide some hints? Clustering documentation does not cover much troubleshooting.

Thank you very much in advance!
Michael Stratford
RE: Clustering - EhCache Replication
March 1, 2013 10:25 AM
Answer

Michael Stratford

Rank: New Member

Posts: 3

Join Date: March 1, 2013

Recent Posts

Hi,

did you find answer to your problem ?

Regards,
M
Johnathan Burbea
RE: Clustering - EhCache Replication
March 1, 2013 3:24 PM
Answer

Johnathan Burbea

Rank: Junior Member

Posts: 38

Join Date: April 5, 2012

Recent Posts

attach your portal-ext.properties
Michael Stratford
RE: Clustering - EhCache Replication
March 3, 2013 4:39 AM
Answer

Michael Stratford

Rank: New Member

Posts: 3

Join Date: March 1, 2013

Recent Posts

Hi

i have similar problem (i think).
Below my post:
http://www.liferay.com/community/forums/-/message_boards/message/22219902

Mayby you can help ?

Thanks in advance
Michael
Jack Chung
RE: Clustering - EhCache Replication
March 19, 2013 9:29 PM
Answer

Jack Chung

Rank: New Member

Posts: 19

Join Date: November 30, 2011

Recent Posts

This may not work for liferay 6.0.4 CE, but did work for Liferay 6.1.10. Note that all the files in the ehcache directory in the portal-impl.jar has to be extracted out to the myehcache directory. Have not tested performance fully, but did not find any usual issues with high CPU usage. This does use jgroups instead of RMI so that account for some of the performance differences.

portal-ext.properties:

 1
 2net.sf.ehcache.configurationResourceName=/myehcache/hibernate-clustered.xml
 3
 4net.sf.ehcache.configurationResourceName.peerProviderProperties=peerDiscovery=automatic,multicastGroupAddress=${multicast.group.address["hibernate"]},multicastGroupPort=${multicast.group.port["hibernate"]},timeToLive=1
 5
 6ehcache.multi.vm.config.location=/myehcache/liferay-multi-vm-clustered.xml
 7
 8ehcache.multi.vm.config.location.peerProviderProperties=peerDiscovery=automatic,multicastGroupAddress=${multicast.group.address["multi-vm"]},multicastGroupPort=${multicast.group.port["multi-vm"]},timeToLive=1
 9
10ehcache.bootstrap.cache.loader.factory=com.liferay.portal.cache.ehcache.JGroupsBootstrapCacheLoaderFactory
11
12ehcache.cache.event.listener.factory=net.sf.ehcache.distribution.jgroups.JGroupsCacheReplicatorFactory
13
14ehcache.cache.manager.peer.provider.factory=net.sf.ehcache.distribution.jgroups.JGroupsCacheManagerPeerProviderFactory
Gunta Dalecka
RE: Clustering - EhCache Replication
November 11, 2013 4:59 AM
Answer

Gunta Dalecka

Rank: New Member

Posts: 4

Join Date: November 7, 2013

Recent Posts

So, have you succeeded to configure Liferay cluster with working session replication?
Which Liferay version did you use? I try to do it with Liferay 6.1.2 CE.
How did you do it? I tried both with and without Terracota.
Did you use session.shared.attributes in your solution? I have troubles with it, when configuring cluster with Terracota.
I've asked related questions in another forum post. Any ideas, how to solve them?