[
https://jira.jboss.org/jira/browse/GTNPORTAL-770?page=com.atlassian.jira....
]
Marek Posolda reopened GTNPORTAL-770:
-------------------------------------
I did another failover testing and I saw the same issue (after creating navigation node on
gateIn1, I am not seeing it on gateIn2). So I did another investigation and I founded two
issues:
1) JBoss Cache on POMSessionManager is still in local mode. Due to code in class
ExoCacheFactoryImpl.createCache() where is this:
if (customConfig != null)
{
...
}
else
{
...
if (!config.isDistributed())
{
// The cache is local
cache.getConfiguration().setCacheMode(CacheMode.LOCAL);
}
...
}
And customConfig is really null so it goes to "else". And config.isDistributed()
is also false because "distributed" property is not specified in
portal-configuration.xml in configuration of cache.config.POMSessionManager. It can be
fixed by attach customConfig for POMSessionManager (ExoCacheFactoryImpl.addConfig should
be called) or by specified "distributed" feature for POMSessionManager. I tried
the second solution and so I add this configuration for POMSessionManager cache config:
<object
type="org.exoplatform.services.cache.impl.jboss.lru.LRUExoCacheConfig">
<field name="name">
<string>POMSessionManager</string>
</field>
<field name="maxNodes">
<int>10000</int>
</field>
<field name="minTimeToLive">
<long>60000</long>
</field>
<field name="distributed">
<boolean>true</boolean>
</field>
</object>
This fixed that CacheMode issue but I ended with exception in server log when starting
GateIn "java.lang.Exception: Don't know how to marshall object of type class
org.exoplatform.portal.pom.data.PortalData"
Full stacktrace is attached. JBoss cache marshaller is having problem with this because
class PortalData is not Serializable. Maybe it will be better to use invalidation instead
of Synchronous replication for POMSessionManager cache? But I am not sure.
2) JBoss cache configuration is read from file
"classpath:/conf/jcr/jbosscache/cluster/config.xml" inside jar
exo.portal.component.common. And this is the same configuration file, which is used for
eXo JCR cache. Problem is that JGroupsStack is not configured in the file. eXo JCR is
adding it programmatically in class
org.exoplatform.services.jcr.jbosscache.ExoJBossCacheFactory based on the configuration
from 02portal.war/WEB-INF/conf/jcr/repository-configuration.xml. But this is not the case
for JBoss cache on POMSessionManager. So JGroups channel is null for POMSessionManager
cache. And cluster-name is "${jbosscache-cluster-name} POMSessionManager" (for
eXo JCR cache is cluster-name also replaced programmatically).
Enable JBoss Cache on the MOPSessionManager
-------------------------------------------
Key: GTNPORTAL-770
URL:
https://jira.jboss.org/jira/browse/GTNPORTAL-770
Project: GateIn Portal
Issue Type: Feature Request
Security Level: Public(Everyone can see)
Components: Performance
Reporter: Thomas Heute
Assignee: Thomas Heute
Fix For: 3.0.0-GA
Attachments: exception-marshaller.txt
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira