« Voltar

How do I cluster Liferay with Terracotta?

Staff Blogs 31 de Agosto de 2010 Por Mika Koivisto Staff

That's a question I've head many times and in this post I will show you  just how to do that. These instructions are for Liferay 6 CE GA3 Tomcat 6.0 bundle however you can use any app server supported by Terracotta but the location and some configuration might be slightly different. So to get started you need to download:

Next step is to install Liferay and Terracotta. For the purposes of this post I won't go into great detail with the installation as both Terracotta and Liferay has good documentation. Basically the installation consist of unpacking the packages to a directory. From now on I will refer to those locations as LIFERAY_HOME and TERRACOTTA_HOME and inside LIFERAY_HOME we will have tomcat directory which I will refer as TOMCAT_HOME. Normally you would also install Liferay and Terracotta in separate servers but I will post a separate post addressing the recommended architecture. For now we can install everything on the same machine and run Terracotta with default configuration for development purposes.

Normally when clustering Liferay you need to address following components: EhCache and Hibernate, Quartz Scheduler, Document Library, Search Engine and optionally Session Replication. For Document Library and Search Engine Terracotta doesn't offer anything new so you make those centrally available the same way as before. For example SAN for DL and SOLR for Search and Indexing. So we are left with EhCache and Hibernate, Quartz and Session Replication that we can address with Terracotta. 

EhCache and Hibernate Second Level Cache

  1.  Remove ehcache.jar that is bundled with Liferay (located in TOMCAT_HOME/webapps/ROOT/WEB-INF/lib)
  2. Copy all jars in TERRACOTTA_HOME/ehcache/lib to TOMCAT_HOME/webapps/ROOT/WEB-INF/lib
  3. Copy TERRACOTTA_HOME/common/terracotta-toolkit-1.0-runtime-<version>.jar to TOMCAT_HOME/webapps/ROOT/WEB-INF/lib
  4. Create my-ehcache folder to TOMCAT_HOME/webapps/ROOT/WEB-INF/classes
  5. Create a hibernate-terracotta.xml and a liferay-multi-vm-terracotta.xml.
  6. Adjust terracottaConfig in hibernate-terracotta.xml and liferay-multi-vm-terracotta.xml to point to your Terracotta servers. Like this: <terracottaConfig url="localhost:9510"/>
  7. Add following properties to your portal-ext.properties file:
    ehcache.multi.vm.config.location=/my-ehcache/liferay-multi-vm-terracotta.xml
    
net.sf.ehcache.configurationResourceName=/my-ehcache/hibernate-terracotta.xml
    
hibernate.cache.region.factory_class=net.sf.ehcache.hibernate.EhCacheRegionFactory

Quartz

  1. Remove quartz.jar that is bundled with Liferay (located in TOMCAT_HOME/webapps/ROOT/WEB-INF/lib)
  2. Copy TERRACOTTA_HOME/quartz/quartz-terracotta-<version>.jar and quartz-all-<version>.jar to TOMCAT_HOME/webapps/ROOT/WEB-INF/lib
  3. Add following properties to your portal-ext.properties:
    org.quartz.jobStore.class = org.terracotta.quartz.TerracottaJobStore
    
org.quartz.jobStore.tcConfigUrl = localhost:9510
  4. Extract portal.properties from portal-impl.jar and place it in TOMCAT_HOME/webapps/ROOT/WEB-INF/classes
  5. Comment out following properties in portal.properties
    #org.quartz.jobStore.dataSource=ds

    #org.quartz.jobStore.isClustered=false
    
#org.quartz.jobStore.misfireThreshold=60000
    
#org.quartz.jobStore.tablePrefix=QUARTZ_
    
#org.quartz.jobStore.useProperties=false

Session Replication

This is highly container specific so refer to Terracotta documentation for specific instructions. Following steps are for Tomcat 6.0.

  1. Copy TERRACOTTA_HOME/sessions/terracotta-session-<version>.jar to TOMCAT_HOME/lib
  2. Copy TERRACOTTA_HOME/common/terracotta-toolkit-1.0-runtime-<version>.jar to TOMCAT_HOME/lib
  3. Edit TOMCAT_HOME/conf/Catalina/localhost/ROOT.xml and add following line right after <Context>
    
<Valve className="org.terracotta.session.TerracottaTomcat60xSessionValve" tcConfigUrl="localhost:9510"/>

Testing The Configuration

Testing your configuration is simple:

  1. Startup your Terracotta Server
    TERRACOTTA_HOME/bin/start-tc-server.sh
  2. Startup your Tomcat
    TOMCAT_HOME/bin/startup.sh
  3. Before Tomcat has fully started you should see following lines in your Tomcat console log:
    2010-09-01 21:35:40,059 INFO - Terracotta 3.3.0, as of 20100716-140706 (Revision 15922 by cruise@rh5mo0 from 3.3)
    2010-09-01 21:35:40,566 INFO - Successfully loaded base configuration from server at 'localhost:9510'.
  4. Now browse http://localhost:8080 to verify that your portal is running. 
  5. Now launch Terracotta Developer Console to verify that EhCache, Hibernate, Quartz and Sessions are seen by Terracotta. You can launch dev console with following command:
    TERRACOTTA_HOME/bin/dev-console.sh
  6. Once you are connected to your Terracotta you should see Ehcache, Hibernate, Quartz and Sessions under My application which indicates that all of them are connected and recognized by Terracotta. Now you can use Dev Console to see what's inside your cache or session. 

Closing Remarks

Now as you can see it is quite easy the cluster Liferay with Terracotta express installation. Now if you want to use the DSO approach it is whole another beast as it involves tedious instrumentation. If you are a Liferay EE customer and want to get supported version of both Liferay and Terracotta contact your Liferay sales rep and ask about Liferay Terracotta Edition. 

Respostas do tópico Autor Data
Nice post! Thank you, Mika. Jonas Yuan 1 de Setembro de 2010 16:04
excellent post! James Min 1 de Setembro de 2010 20:12
Mika, this is good stuff! Thanks. Sampsa Sohlman 2 de Setembro de 2010 08:03
Hi Mika, Nice Post. Looks like the two file... Shagul Khajamohideen 2 de Setembro de 2010 12:47
Should be accessible now. Thanks for letting me... Mika Koivisto 2 de Setembro de 2010 13:30
Great post but ... I ran into a problem that... James Denmark 2 de Setembro de 2010 16:04
Looks like you configured... Mika Koivisto 2 de Setembro de 2010 16:10
Hello again Mika. I'm sorry to ask this... James Denmark 9 de Setembro de 2010 20:21
Hello do you successfully run clustered liferay... Eric Grandjean 10 de Setembro de 2010 02:16
So the first time around I had a working... James Denmark 10 de Setembro de 2010 07:23
Have you done this setup with everything on one... Mika Koivisto 10 de Setembro de 2010 02:23
These were separate servers - two... James Denmark 10 de Setembro de 2010 07:24
James, did you manage to resolve the... Stuart Hirst 14 de Setembro de 2010 00:52
No. I still haven't resolved it and have moved... James Denmark 14 de Setembro de 2010 06:18
Hey Guys, sorry it took so long but I've now... Mika Koivisto 16 de Setembro de 2010 07:42
Thanks for looking into this Mika. To make... James Denmark 16 de Setembro de 2010 08:15
That is correct. Mika Koivisto 16 de Setembro de 2010 08:17
Hi Mike, I am also facing the problem, can... satish M 12 de Dezembro de 2010 23:06
The serializable problem might have been fixed... Urban Lindberg 26 de Janeiro de 2011 05:34
I am also experiencing the same problem. I... Stuart Hirst 10 de Setembro de 2010 02:30
very cool! something for me to try when I have... Wilson Man 2 de Setembro de 2010 17:36
You write "Extract portal.properties from... Sampsa Sohlman 3 de Setembro de 2010 07:51
Yeah, that is correct. You must disable those... Mika Koivisto 3 de Setembro de 2010 08:20
Thanks for the excellent post. I have come... Stuart Hirst 9 de Setembro de 2010 07:17
Hmm. I've usually seen this if Terracotta... Mika Koivisto 9 de Setembro de 2010 07:31
Mika, Thanks for your advice. I have managed... Stuart Hirst 10 de Setembro de 2010 02:17
Its good, Thank you, Mika. N K Rao 20 de Outubro de 2010 01:48
Hi Mika, i am also facing the above... N K Rao 20 de Outubro de 2010 01:57
I can't get this to work. Using a plain... Keith Scott 8 de Fevereiro de 2011 05:00
Hi Mika, I am getting following error while... Ankit Srivastava 12 de Abril de 2012 23:17
To solve the above problem, in... Danil Mironov 21 de Agosto de 2013 02:42
Storing the session in terracotta works fine... Tom Mahy 30 de Maio de 2012 01:24
Are there any plans to update/post instructions... Keith O'Connell 28 de Junho de 2012 07:48
[...] I have 2 server. - Server1: OS is Ubuntu... Anônimo 3 de Julho de 2012 22:08
Not work with Liferay 6.1 :( Nguyen Trong Tri 4 de Julho de 2012 05:30
[...] In our project based o Liferay running on... Anônimo 20 de Novembro de 2013 08:42
Hi All I am facing the issue when integrating... Hari babu 24 de Maio de 2014 05:35

Nice post! Thank you, Mika.
Postado em 01/09/10 16:04.
excellent post!
Postado em 01/09/10 20:12.
Mika, this is good stuff! Thanks.
Postado em 02/09/10 08:03.
Hi Mika,
Nice Post. Looks like the two file links are not accessible. Can you please verify that?
Postado em 02/09/10 12:47.
Should be accessible now. Thanks for letting me know.
Postado em 02/09/10 13:30 em resposta a Shagul Khajamohideen.
Great post but ... I ran into a problem that hopefully you help with.

Followed instructions as above except I have the terracotta server running on a different box. Made the ip address changes as appropriate and created the tc-config.xml file on the terracotta server.

Now when I fire up Liferay, everything looks good through the terracotta startup and then I start getting exceptions:

2010-09-02 18:52:11,606 INFO - Terracotta 3.3.0, as of 20100716-140706 (Revision 15922 by cruise@rh5mo0 from 3.3)
2010-09-02 18:52:12,034 INFO - Successfully loaded base configuration from server at '10.109.206.10:9510'.
2010-09-02 18:52:12,080 INFO - Successfully loaded base configuration from file at '/usr/local/liferay/liferay-portal-6.0.5/tomcat-6.0.26/temp/tc-config40885335344­94940638.xml'.
2010-09-02 18:52:12,208 INFO - Log file: '/root/terracotta/client-logs/terracotta-client.log'.
2010-09-02 18:52:13,956 INFO - Connection successfully established to server at 10.109.206.10:9510
18:52:40,171 INFO [PortalImpl:277] Global lib directory /usr/local/liferay/liferay-portal-6.0.5/tomcat-6.0.26/lib/ext/
18:52:40,175 INFO [PortalImpl:297] Portal lib directory /usr/local/liferay/liferay-portal-6.0.5/tomcat-6.0.26/webapps/ROOT/WEB-INF/lib/
S­tarting Liferay Portal Community Edition 6.0.5 CE (Bunyan / Build 6005 / August 16, 2010)
18:52:55,917 ERROR [velocity:151] ResourceManager.getResource() load exception
18:52:55,919 ERROR [velocity:151] net.sf.ehcache.CacheException: java.io.NotSerializableException: org.apache.velocity.Template
at org.terracotta.modules.ehcache.store.ValueModeHandlerSerialization.createTimesta­mpedValue(ValueModeHandlerSerialization.java:56)

etc..... any suggestions?
Postado em 02/09/10 16:04.
Looks like you configured ehcache.single.vm.config.location=/ehcache/liferay-single-vm.xml to use Terracotta. This is definite no no! Single VM cache is not distributable as the objects are not Serializable.
Postado em 02/09/10 16:10 em resposta a James Denmark.
very cool! something for me to try when I have some time! =)
Postado em 02/09/10 17:36.
You write "Extract portal.properties from portal-impl.jar and place it in TOMCAT_HOME/webapps/ROOT/WEB-INF/classes Comment out following properties in portal.properties"

So just to confirm. there is something that normal portal-ext.properties override does not work?
Postado em 03/09/10 07:51.
Yeah, that is correct. You must disable those properties and you can't do that in portal-ext.properties. When using TerracottaJobStore it will throw errors if those properties are present.
Postado em 03/09/10 08:20 em resposta a Sampsa Sohlman.
Thanks for the excellent post.

I have come across a problem where the Terracotta client log shows:


2010-09-09 14:14:29,874 [ConnectionEstablisher] WARN com.tc.net.protocol.transport.ClientMessageTransport - ConnectionID(1.50c199aa5ce84e0ca28d03b4e6e5d99d): Timeout of 10000 milliseconds occured [lossy interval: 10000ms]
2010-09-09 14:14:29,907 [L1_L2:TCComm Main Selector Thread_R (listen 0:0:0:0:0:0:0:0:53896)] WARN com.tc.net.protocol.transport.ClientMessageTransport - ConnectionID(1.50c199aa5ce84e0ca28d03b4e6e5d99d): CLOSE EVENT : com.tc.net.core.TCConnectionJDK14@775009342: connected: false, closed: true local=127.0.0.1:60631 remote=127.0.0.1:9510 connect=[Thu Sep 09 14:14:19 GMT 2010] idle=10015ms [0 read, 84 write]. STATUS : START
2010-09-09 14:14:29,908 [L1_L2:TCComm Main Selector Thread_R (listen 0:0:0:0:0:0:0:0:53896)] WARN com.tc.net.protocol.transport.ClientMessageTransport - ConnectionID(1.50c199aa5ce84e0ca28d03b4e6e5d99d): closing down connection - com.tc.net.core.TCConnectionJDK14@775009342: connected: false, closed: true local=127.0.0.1:60631 remote=127.0.0.1:9510 connect=[Thu Sep 09 14:14:19 GMT 2010] idle=10038ms [0 read, 84 write]
2010-09-09 14:14:30,881 [ConnectionEstablisher] INFO com.tc.net.protocol.transport.ClientMessageTransport - ConnectionID(1.50c199aa5ce84e0ca28d03b4e6e5d99d): Attaching new connection: com.tc.net.core.TCConnectionJDK14@425034011: connected: true, closed: false local=127.0.0.1:60633 remote=127.0.0.1:9510 connect=[Thu Sep 09 14:14:30 GMT 2010] idle=5ms [0 read, 0 write]

and the Terracotta console show:

2010-09-09 15:23:22,431 INFO - "Client Cannot Reconnect ConnectionID(0.50c199aa5ce84e0ca28d03b4e6e5d99d) not found. Connection attempts from the Terracotta node at 127.0.0.1:48718 are being rejected by the Terracotta server array. Restart the Client to allow it to rejoin the cluster. Many Client reconnection failures can be avoided by configuring the Terracotta server array for "permanent-store" and tuning reconnection parameters. For more information, see http://www.terracotta.org/kit/reflector?kitID=default&pageID=HA"

I have tried it with persistence set to "permanent-store" and it made no difference.

Any advice would be much appreciated.
Postado em 09/09/10 07:17.
Hmm. I've usually seen this if Terracotta server is restarted while Liferay is running. Like the error message suggest you might need to tune the reconnection timeout settings. If you have not restarted your Terracotta server then there might have been some sort of network outage. If the problem persists I would ask help from Terracotta forums describing your setup and providing your tc-config.xml.
Postado em 09/09/10 07:31 em resposta a Stuart Hirst.
Hello again Mika. I'm sorry to ask this question again but I have followed these instructions to the letter with two completely fresh installs and I'm still getting the same errors I indicated earlier. I agree with your assessment but as far as I can tell, I haven't done anything to tell single-vm cache to use Terracotta. Can you give me some more guidance on how this might have happened and how to isolate it as it seems improbable that this would happen without me messing it up somehow but I can't figure out how? To be clear this is a fresh install and the only things in portal-ext.properties are the mysql parameters and the entries from your post. The my-ehcache folder only contains the two files downloaded from your post with the terracottaConfig url parameter updated so.
Postado em 09/09/10 20:21 em resposta a James Denmark.
Hello do you successfully run clustered liferay portal 6 without terracotta but with "basic" configuration of ehcache and jgroups ?
Postado em 10/09/10 02:16 em resposta a James Denmark.
Mika, Thanks for your advice.

I have managed to address the problem by adding the following into tc-properties in the terracotta config:

<property name="l2.l1reconnect.enabled" value="true" />
<property name="l2.l1reconnect.timeout.millis" value="600000" />

Unfortunatly I am now experiencing the same problem as James Denmark below. I will add to that issue next.

Thanks again Stuart
Postado em 10/09/10 02:17 em resposta a Mika Koivisto.
Have you done this setup with everything on one physical server or do you have separate servers for each Liferay and Terracotta? I will do some experimenting to try to reproduce that issue.
Postado em 10/09/10 02:23 em resposta a James Denmark.
I am also experiencing the same problem. I orginally had timeout issues with Terracotta which I resolved with Mika's help.

I have tried this with both Liferay and Terracotta running both on a single host and have tried with Terracotta server on a separate host with the same results. The output from catalina.out shows :
Starting Liferay Portal Community Edition 6.0.5 CE (Bunyan / Build 6005 / August 16, 2010)
09:54:22,225 ERROR [velocity:151] ResourceManager.getResource() load exception
09:54:22,227 ERROR [velocity:151] net.sf.ehcache.CacheException: java.io.NotSerializableException: org.apache.velocity.Template
at org.terracotta.modules.ehcache.store.ValueModeHandlerSerialization.createTimesta­mpedValue(ValueModeHandlerSerialization.java:56)
etc.......
Postado em 10/09/10 02:30 em resposta a James Denmark.
So the first time around I had a working ehcache cluster for sessions and document library when Mika's posting came out so I converted that and ran into the problem I originally posted. After Mika's response, I assumed there might be some complicating factor from my original config so I created new installs from scratch but ran into the same issue. The common element in both configurations was the Terracotta server.
Postado em 10/09/10 07:23 em resposta a Eric Grandjean.
These were separate servers - two Centos/Tomcat/Liferay - one Centos/Terracotta.
Postado em 10/09/10 07:24 em resposta a Mika Koivisto.
James, did you manage to resolve the java.io.NotSerializableException issue ? I have been trying various configurations without success and I am approaching the point where I will need to choose a different solution.

Any feedback would be useful. Thanks, Stuart
Postado em 14/09/10 00:52 em resposta a James Denmark.
No. I still haven't resolved it and have moved onto other parts of my configuration hoping to get an update from Mika's test in the interim. Hoping to see an update soon as I am sure this must be something simple in the cache configuration and I too need to get this working or choose an alternative. If I uncover anything new I will post it.
Postado em 14/09/10 06:18 em resposta a Stuart Hirst.
Hey Guys, sorry it took so long but I've now been able to reproduce your issue. It's caused by the use of MultiVMPoolUtil in com.liferay.portal.velocity.LiferayResourceCacheUtil. If you switch it to SingleVMPoolUtil you should be able to get past that error. Now this will reintroduce the issue described in http://issues.liferay.com/browse/LPS-8105.
Postado em 16/09/10 07:42 em resposta a James Denmark.
Thanks for looking into this Mika.

To make sure I'm understanding this correctly. I run an 'out-of-the-box' Liferay instalation so I can't use Terracotta with Liferay 6 unless I customize the portal core as suggested above and run it in the EXT environment. Is that right?
Postado em 16/09/10 08:15 em resposta a Mika Koivisto.
That is correct.
Postado em 16/09/10 08:17 em resposta a James Denmark.
Its good, Thank you, Mika.
Postado em 20/10/10 01:48.
Hi Mika,

i am also facing the above problem(java.io.NotSerializableException).can you please give any suggestions?

Caused by: java.io.notserializableexception org.apache.velocity.Template
Postado em 20/10/10 01:57 em resposta a Narasimha Rao.
Hi Mike,

I am also facing the problem, can you plese let me know what changes to be made.

Thanks in Advance.
RK
Postado em 12/12/10 23:06 em resposta a Mika Koivisto.
The serializable problem might have been fixed in trunk, have a look at
http://issues.liferay.com/browse/LPS-13429
Postado em 26/01/11 05:34 em resposta a satish M.
I can't get this to work. Using a plain liferay-tomcat-6.0.5 bundle with mysql and the latest build of terracotta. I don't know if we have to configure terracotta but we have just started as described above and it seems to start ok but when we start liferay we keep getting the following in the logs.

2011-02-08 10:42:03,847 INFO - Terracotta 3.4.1, as of 20110130-210115 (Revision 17072 by cruise@su10mo4 from 3.4)
2011-02-08 10:42:04,716 INFO - Successfully loaded base configuration from server at 'localhost:9510'.
2011-02-08 10:42:04,773 INFO - Successfully loaded base configuration from file at '/liferay/liferay-portal-6.0.5/tomcat-6.0.26/temp/tc-config29604913327303$
2011-0­2-08 10:42:04,993 INFO - Log file: '/root/terracotta/client-logs/terracotta-client.log'.
2011-02-08 10:42:07,242 INFO - Connection successfully established to server at 192.168.1.169:9510
10:42:36,467 INFO [PortalImpl:277] Global lib directory /liferay/liferay-portal-6.0.5/tomcat-6.0.26/lib/ext/
10:42:36,469 INFO [PortalImpl:297] Portal lib directory /liferay/liferay-portal-6.0.5/tomcat-6.0.26/webapps/ROOT/WEB-INF/lib/
10:42:57,86­9 ERROR [QuartzSchedulerEngineImpl:73] Unable to initialize engine
java.lang.RuntimeException: Problem obtaining node id from TerracottaJobStore.
at org.quartz.impl.StdSchedulerFactory.instantiate(StdSchedulerFactory.java:1180)
at org.quartz.impl.StdSchedulerFactory.getScheduler(StdSchedulerFactory.java:1465)
at com.liferay.portal.scheduler.quartz.QuartzSchedulerEngineImpl.afterPropertiesSet­(QuartzSchedulerEngineImpl.java:70)

Can any help.
Thanks
Keith
Postado em 08/02/11 05:00.
Hi Mika,

I am getting following error while integrating liferay 6 sp1 to terracotta 3.6 :

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'counterHibernateSessionFactory' defined in class path resource [META-INF/hibernate-spring.xml]: Invocation of init method failed; nested except
heManager in the config or do one of following:
1. Use one of the CacheManager.create() static factory methods to reuse same CacheManager with same name or create one if necessary
2. Shutdown the earlier cacheManager before creating new one with same name.

Please help me to resolve this.
Postado em 12/04/12 23:17.
Storing the session in terracotta works fine but the cache doesnt work.


08:01:44,701 ERROR [ContextLoader:220] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'serviceAdvice' defined in class path resource [META-INF/base-spring.xml]: Cannot resolve reference to bean 'asyncAdvice' while setting bean property 'nextMethodInterceptor'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'asyncAdvice' defined in class path resource [META-INF/base-spring.xml]: Cannot resolve reference to bean 'threadLocalCacheAdvice' while setting bean property 'nextMethodInterceptor'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'threadLocalCacheAdvice' defined in class path resource [META-INF/base-spring.xml]: Cannot resolve reference to bean 'bufferedIncrementAdvice' while setting bean property 'nextMethodInterceptor'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'bufferedIncrementAdvice' defined in class path resource [META-INF/base-spring.xml]: Cannot resolve reference to bean 'transactionAdvice' while setting bean property 'nextMethodInterceptor'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionAdvice' defined in class path resource [META-INF/base-spring.xml]: Cannot resolve reference to bean 'liferayTransactionManager' while setting bean property 'transactionManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liferayTransactionManager' defined in class path resource [META-INF/hibernate-spring.xml]: Cannot resolve reference to bean 'liferayHibernateSessionFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liferayHibernateSessionFactory' defined in class path resource [META-INF/hibernate-spring.xml]: Invocation of init method failed; nested exception is org.hibernate.cache.CacheException: net.sf.ehcache.CacheException: Error configuring from null. Initial cause was null
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveRef­erence(BeanDefinitionValueResolver.java:328)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveVal­ueIfNecessary(BeanDefinitionValueResolver.java:106)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.app­lyPropertyValues(AbstractAutowireCapableBeanFactory.java:1325)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.pop­ulateBean(AbstractAutowireCapableBeanFactory.java:1086)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doC­reateBean(AbstractAutowireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.cre­ateBean(AbstractAutowireCapableBeanFactory.java:456)
Postado em 30/05/12 01:24.
Are there any plans to update/post instructions for integrating Liferay 6.1 with Terracotta? I tried to execute using the instructions above with Liferay 6.1 EE, however, I wound up getting the same error that Ankit reported above. It seems that the hibernate-spring initialization attempts to create the same caches that are created by the hibernate-terracotta Ehcache configuration. For reference, I used the XML files stored in the 6.1 EE portal-impl.jar rather than the files referenced above; they seem to be largely similar, but I figured that it'd be safer to stick with the ones that are distributed within EE.
Postado em 28/06/12 07:48.
[...] I have 2 server. - Server1: OS is Ubuntu server 10.04 LTS. Run Liferay Portal 6.1 CE. (IP: 192.168.2.60) java version "1.6.0_20" OpenJDK Runtime Environment (IcedTea6 1.9.13)... [...] Read More
Postado em 03/07/12 22:08.
Not work with Liferay 6.1 emoticon
Postado em 04/07/12 05:30.
To solve the above problem, in portal-ext.properties ("EhCache and Hibernate Second Level Cache", step 7)
replace

hibernate.cache.region.factory_class=net.sf.ehcache.hibernate.EhCacheR­egionFactory
with
hibernate.cache.region.factory_class=net.sf.ehcache.hibernate.Si­ngletonEhCacheRegionFactory
Postado em 21/08/13 02:42 em resposta a Ankit Srivastava.
[...] In our project based o Liferay running on Tomcat7 we use Terracotta. During Tomcat restart we got Terracotta exception: 15:38:54,281 ERROR [CacheFilter:59] net.sf.ehcache.CacheException:... [...] Read More
Postado em 20/11/13 08:42.
Hi All

I am facing the issue when integrating terracotta with liferay-portal-6.2.10.1-ee-ga1

I am followed the Mika Blog http://www.liferay.com/web/mika.koivisto/blog/-/blogs/how-do-i-cluster-liferay-w­ith-terracotta-

The below is the error I am getting, Request you to please help me here.

2014-05-17 16:48:54,417 INFO – Connection successfully established to server at 192.168.0.100:9510
16:48:55,350 INFO [localhost-startStop-1][ValueModeHandlerFactory:125] Hibernate types found on the classpath : Enabling Hibernate value mode optimizations
16:48:55,912 INFO [localhost-startStop-1][ClusteredStore:125] Cache [com.liferay.portal.model.impl.UserImpl] using concurrency: 256
16:49:09,032 ERROR [localhost-startStop-1][ContextLoader:206] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘com.liferay.portal.kernel.cache.MultiVMPool’ defined in class path resource [META-INF/util-spring.xml]: Cannot resolve reference to bean ‘com.liferay.portal.kernel.cache.MultiVMPortalCacheManager’ while setting bean property ‘portalCacheManager’; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘com.liferay.portal.kernel.cache.MultiVMPortalCacheManager’ defined in class path resource [META-INF/util-spring.xml]: Cannot create inner bean ‘com.liferay.portal.cache.ehcache.EhcachePortalCacheManager#704fb2′ of type [com.liferay.portal.cache.ehcache.EhcachePortalCacheManager] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘com.liferay.portal.cache.ehcache.EhcachePortalCacheManager#704fb2′ defined in class path resource

Caused by: java.lang.NoSuchFieldException: statisticsExecutor
at java.lang.Class.getDeclaredField(Class.java:1948)
at com.liferay.portal.kernel.util.ReflectionUtil.getDeclaredField(ReflectionUtil.ja­va:66)
at com.liferay.portal.cache.ehcache.CacheManagerUtil.<clinit>(CacheManagerUtil.java­:90)
… 52 more
Postado em 24/05/14 05:35.