<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>Override liferay-multi-vm.xml</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=119077182" />
  <subtitle>Override liferay-multi-vm.xml</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=119077182</id>
  <updated>2026-04-04T21:48:16Z</updated>
  <dc:date>2026-04-04T21:48:16Z</dc:date>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119111609" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119111609</id>
    <updated>2020-05-06T19:18:23Z</updated>
    <published>2020-05-06T19:18:23Z</published>
    <summary type="html">&lt;div class="quote-title"&gt;Pankaj Kumar:&lt;/div&gt;&lt;blockquote&gt;&lt;br /&gt;3.Add the replicatePutsViaCopy=true value we can check from PortalCacheReplicator.java base on requirement.&lt;br /&gt; &lt;br /&gt;&lt;/blockquote&gt;Rarely (read: never) have I seen a justification for &amp;#34;replicatePut&amp;#34; based on actual necessity. Always, in what I&amp;#39;ve seen so far, it was a bad idea: If you need an entity on one server, that doesn&amp;#39;t have any effect on the other server. In fact, you limit the capacity of the whole cluster by assuming that you have the same objects in all caches. &lt;br /&gt;If you need an object on another server, it will be fetched from the regular storage (database) anyway -  and flushed from the cache if it&amp;#39;s modified on any other cluster machine.</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2020-05-06T19:18:23Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119108107" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119108107</id>
    <updated>2020-05-06T15:15:32Z</updated>
    <published>2020-05-06T15:15:32Z</published>
    <summary type="html">Sorry for late response.I was able to replicate cache  in clustered environment .1.Create module-multi-vm.xml and placed  under respective module /resource/META-INF/ folder.2. Insted of using MutliVMPoolUtil we should use @Reference&lt;br /&gt;    private MultiVMPool _multiVMPool;3.Add the replicatePutsViaCopy=true value we can check from PortalCacheReplicator.java base on requirement.&lt;br /&gt; </summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-06T15:15:32Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119094544" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119094544</id>
    <updated>2020-05-04T12:12:27Z</updated>
    <published>2020-05-04T12:12:27Z</published>
    <summary type="html">&lt;div class="quote-title"&gt;Pankaj Kumar:&lt;/div&gt;&lt;blockquote&gt;&lt;br /&gt;As we are using Liferay Portal in clustered  environment and there are certain complex  rules  based on some rules we include ,exclude content and after that we show final content to accomplish this every  30 min a scheduler  runs which refresh  the cache and final result shown to user.&lt;/blockquote&gt;&lt;br /&gt;&amp;#34;Complex caching rules&amp;#34; - if that&amp;#39;s what you wanted to say - indeed sound like a bad idea. Caches should be dead simple.&lt;br /&gt;From the ticket mentioned above, I&amp;#39;ve clicked through to &lt;a href="https://github.com/dantewang/liferay-docs/pull/7/commits/978ad4e4c22797f0c7c2613a79e670319c9f81a2"&gt;https://github.com/dantewang/liferay-docs/pull/7/commits/978ad4e4c22797f0c7c2613a79e670319c9f81a2&lt;/a&gt; (in some indirections). In general: The regular clustered cache-invalidation (e.g. server[1] changes an object and signals server[2..n] that the object in question should be flushed from the cache) is fine - and if you need to configure your cache size accordingly: That&amp;#39;s fine. &lt;br /&gt;Complex caching rules that span the cluster sound like a solution on the wrong level of abstraction (without further explanation).</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2020-05-04T12:12:27Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119087444" />
    <author>
      <name>David H Nebinger</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119087444</id>
    <updated>2020-05-04T05:06:52Z</updated>
    <published>2020-05-04T05:06:52Z</published>
    <summary type="html">This already sounds like a disaster.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;First, if they need to make a change, it may not take effect for 30 minutes under this plan. That means for 30 minutes someone will see something they shouldn&amp;#39;t or won&amp;#39;t see something they should.&lt;br /&gt;&lt;br /&gt;Second, the Liferay permission system is already established which handles visibility on assets. I&amp;#39;m not sure what you&amp;#39;re doing, but if you were using permission assignments (either changing permissions on assets or changing roles for the users), the regular Liferay functionality would just work, it applies across the cluster and doesn&amp;#39;t require some kind of whacky multi-vm pool usage.&lt;br /&gt;&lt;br /&gt;I don&amp;#39;t know what these &amp;#34;complex rules&amp;#34; actually are, but if they are processed when they are changed and either modify permissions on assets or adjust user roles, it would apply immediately and would leverage the normal Liferay OOTB functionality to determine who has permission to see what.</summary>
    <dc:creator>David H Nebinger</dc:creator>
    <dc:date>2020-05-04T05:06:52Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119086380" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119086380</id>
    <updated>2020-05-02T18:17:36Z</updated>
    <published>2020-05-02T18:17:36Z</published>
    <summary type="html">As we are using Liferay Portal in clustered  environment and there are certain complex  rules  based on some rules we include ,exclude content and after that we show final content to accomplish this every  30 min a scheduler  runs which refresh  the cache and final result shown to user.</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-02T18:17:36Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119084546" />
    <author>
      <name>David H Nebinger</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119084546</id>
    <updated>2020-05-02T13:32:02Z</updated>
    <published>2020-05-02T13:32:02Z</published>
    <summary type="html">I know you guys are both still plowing forward with this, but again I have to ask...&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Why?&lt;br /&gt;&lt;br /&gt;I can&amp;#39;t tell you how many times I&amp;#39;ve gone in to tune a Liferay deployment only to undo this kind of thing. It is absolutely not a &amp;#34;go-to&amp;#34; mechanism, it is only good in certain limited scenarios which many developers don&amp;#39;t understand.</summary>
    <dc:creator>David H Nebinger</dc:creator>
    <dc:date>2020-05-02T13:32:02Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119080409" />
    <author>
      <name>Eric DARIEL</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119080409</id>
    <updated>2025-10-21T05:12:37Z</updated>
    <published>2020-05-01T19:24:13Z</published>
    <summary type="html">Have you seen this post ?&lt;br /&gt;&lt;br /&gt;&lt;a href="https://help.liferay.com/hc/en-us/articles/360035581471-Overriding-Cache"&gt;https://help.liferay.com/hc/en-us/articles/360035581471-Overriding-Cache&lt;/a&gt;</summary>
    <dc:creator>Eric DARIEL</dc:creator>
    <dc:date>2020-05-01T19:24:13Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082985" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082985</id>
    <updated>2020-05-01T18:16:34Z</updated>
    <published>2020-05-01T18:16:34Z</published>
    <summary type="html">private static final PortalCache&amp;lt;String,Sring&amp;gt;  TEST_CACHE= MultiVMPoolUtil.getPortalCache(Test.class.getClasse()));&lt;br /&gt;I followed the approach define  here &lt;a href="https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering"&gt;https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering&lt;/a&gt;when i debug  found its still picks the  default location of liferay-mutli-vm.xml instead of mine which is override-liferay-multi-vm-clustered.xml</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-01T18:16:34Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082639" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082639</id>
    <updated>2020-05-01T17:22:42Z</updated>
    <published>2020-05-01T17:22:42Z</published>
    <summary type="html">Thanks Eric,Let me try with this approach.I am using Liferay 7.2&lt;br /&gt;Look like this class is deprecated in 7.2.I will try and  let  my finding.</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-01T17:22:42Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082216" />
    <author>
      <name>Eric DARIEL</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119082216</id>
    <updated>2025-10-21T05:12:37Z</updated>
    <published>2020-05-01T17:01:28Z</published>
    <summary type="html">I had a similar problem in 7.1.&lt;br /&gt;I have done a new module to do that.&lt;br /&gt;&lt;br /&gt;You can follow this link :&lt;br /&gt;&lt;a href="https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering"&gt;https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering"&gt;&lt;/a&gt;Look at the bottom of the page (&lt;strong&gt;&lt;a href="https://help.liferay.com/hc/en-us/articles/360018175191-Liferay-DXP-Clustering#modifying-the-cache-configuration-with-a-module"&gt;MODIFYING THE CACHE CONFIGURATION WITH A MODULE&lt;/a&gt;&lt;/strong&gt;)&lt;br /&gt;Eric.</summary>
    <dc:creator>Eric DARIEL</dc:creator>
    <dc:date>2020-05-01T17:01:28Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119081618" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119081618</id>
    <updated>2020-05-01T15:34:23Z</updated>
    <published>2020-05-01T15:34:23Z</published>
    <summary type="html">After giving the location ehcache.multi.vm.config.location={Liferay_home}\custom\liferay-multi-vm.xml  i am getting  below exception&lt;br /&gt;FrameworkEvent ERROR &lt;br /&gt;com.liferay.portal.kernel.exception.SystemException: Unable to instantiate cache event listener factory com.liferay.portal.cache.ehcache.LiferayCacheEventListenerFactory&lt;br /&gt;    at com.liferay.portal.cache.ehcache.internal.event.EhcachePortalCacheListenerFactory.create(EhcachePortalCacheListenerFactory.java:94)&lt;br /&gt;    at com.liferay.portal.cache.BasePortalCacheManager._initPortalCacheListeners(BasePortalCacheManager.java:348)&lt;br /&gt;    at com.liferay.portal.cache.BasePortalCacheManager.reconfigPortalCache(BasePortalCacheManager.java:317)&lt;br /&gt;    at com.liferay.portal.cache.ehcache.internal.EhcachePortalCacheManager.reconfigurePortalCaches(EhcachePortalCacheManager.java:92)&lt;br /&gt;Can any body  do i need to  any addition change.&lt;br /&gt;Thanks,Pankaj Semwal</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-01T15:34:23Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119079137" />
    <author>
      <name>Eric DARIEL</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119079137</id>
    <updated>2025-10-21T05:12:37Z</updated>
    <published>2020-05-01T13:17:27Z</published>
    <summary type="html">But now we can do this without restarting our Liferay :&lt;br /&gt;&lt;a href="https://issues.liferay.com/browse/LPS-88547"&gt;https://issues.liferay.com/browse/LPS-88547&lt;/a&gt;&lt;br /&gt;Anyone know if we can do this in 7.1 ?  If yes can we do this with Fixpack 11 ? (I never see this LPS-88547 in the change logs of Liferay 7.1 or 7.2)&lt;br /&gt;&lt;br /&gt;Thanks,&lt;br /&gt;Eric.</summary>
    <dc:creator>Eric DARIEL</dc:creator>
    <dc:date>2020-05-01T13:17:27Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077890" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077890</id>
    <updated>2020-05-01T04:01:15Z</updated>
    <published>2020-05-01T04:01:15Z</published>
    <summary type="html">Thanks David for response.You mean i need to create one folder in Liferay home and add liferay-multi-vm.xml file there  and read the file as below.ehcache.multi.vm.config.location={Liferay_home}\custom\liferay-multi-vm.xml</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-05-01T04:01:15Z</dc:date>
  </entry>
  <entry>
    <title>RE: Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077533" />
    <author>
      <name>David H Nebinger</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077533</id>
    <updated>2020-04-30T20:31:25Z</updated>
    <published>2020-04-30T20:31:25Z</published>
    <summary type="html">Same way it has always been done...&lt;br /&gt;&lt;br /&gt;Create the xml file and then set the ehcache.multi.vm.config.location property in portal-ext.properties as the full path to the file.&lt;br /&gt;&lt;br /&gt;Note, however, that I&amp;#39;m guessing you&amp;#39;re about to misuse multi-vm caching. Generally there is very little that you want to push in here.&lt;br /&gt;&lt;br /&gt;Why? Well the contents are replicated around the entire cluster. Often times you do not need or want this, especially if a node isn&amp;#39;t asking for it. Unused but cached data sits in the memory of the application server, consuming resources that you would often be better served using in other ways.&lt;br /&gt;&lt;br /&gt;I rarely want to use multi-vm caching. Single-vm is a good bet, if you needed a value on a node, you&amp;#39;re likely going to need it on that node again sometime soon. But even then, you have to understand the probability of a cache hit just as much as the impact of a cache miss.</summary>
    <dc:creator>David H Nebinger</dc:creator>
    <dc:date>2020-04-30T20:31:25Z</dc:date>
  </entry>
  <entry>
    <title>Override liferay-multi-vm.xml</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077181" />
    <author>
      <name>Pankaj Kumar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=119077181</id>
    <updated>2020-04-30T20:13:44Z</updated>
    <published>2020-04-30T20:13:44Z</published>
    <summary type="html">Hi All,&lt;br /&gt;I am using Liferay DXP 7.2 .I want  to override liferay-multi-vm.xml so that i can add my custom entity configuration and replication can happen in cluster environment I tried to write Fragment using  com.liferay.portal.cache.ehcache.impl-2.0.5  module but not able to write.&lt;br /&gt;Can any tell me how we can override liferay-multi-vm.xml&lt;br /&gt;Thanks,Pankaj Semwal</summary>
    <dc:creator>Pankaj Kumar</dc:creator>
    <dc:date>2020-04-30T20:13:44Z</dc:date>
  </entry>
</feed>
