]
Trong Tran updated GTNPORTAL-3472:
----------------------------------
Affects Version/s: 3.7.0.Final
NPE in PicketLinkIDMServiceImpl.getIdentitySession during startup
when eXo MBeans are invoked
---------------------------------------------------------------------------------------------
Key: GTNPORTAL-3472
URL:
https://issues.jboss.org/browse/GTNPORTAL-3472
Project: GateIn Portal
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 3.7.0.Final
Reporter: Trong Tran
We can't monitor eXo Platform health in a clean way because if we invoke eXo MBeans
during GateIn portal startup, we have dozens of the following NPE which pollute the logs:
{code}
[jmxtrans-collect-5] ERROR
org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl - null
java.lang.NullPointerException
at
org.exoplatform.services.organization.idm.PicketLinkIDMServiceImpl.getIdentitySession(PicketLinkIDMServiceImpl.java:211)
at
org.exoplatform.services.organization.idm.PicketLinkIDMOrganizationServiceImpl.endRequest(PicketLinkIDMOrganizationServiceImpl.java:189)
at org.exoplatform.container.component.RequestLifeCycle.doEnd(RequestLifeCycle.java:71)
at
org.exoplatform.container.component.RequestLifeCycleStack.end(RequestLifeCycleStack.java:101)
at org.exoplatform.container.component.RequestLifeCycle.end(RequestLifeCycle.java:163)
at
org.exoplatform.container.management.ManagementContextImpl.afterInvoke(ManagementContextImpl.java:381)
at org.exoplatform.management.jmx.impl.ExoModelMBean.invoke(ExoModelMBean.java:75)
at
javax.management.modelmbean.RequiredModelMBean.getAttribute(RequiredModelMBean.java:1441)
at
javax.management.modelmbean.RequiredModelMBean.getAttributes(RequiredModelMBean.java:1657)
at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getAttributes(DefaultMBeanServerInterceptor.java:725)
at com.sun.jmx.mbeanserver.JmxMBeanServer.getAttributes(JmxMBeanServer.java:675)
at org.jmxtrans.embedded.Query.collectMetrics(Query.java:165)
at org.jmxtrans.embedded.EmbeddedJmxTrans$1.run(EmbeddedJmxTrans.java:145)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:180)
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:204)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:695)
{code}
*MBeans which seem to cause this problem :*
-
exo:portal=portal,repository=\*,workspace=system,cache-type=JCR_CACHE,jmx-resource=CacheMgmtInterceptor
-
exo:portal=portal,repository=\*,workspace=system,cache-type=LOCK_CACHE,jmx-resource=CacheMgmtInterceptor
- exo:portal=portal,repository=*,service=SessionRegistry
- exo:portal=portal,repository=\*,workspace=\*,service=Cache
- exo:portal=portal,repository=\*,workspace=\*,service=lockmanager
- exo:portal=portal,service=cache,name=*
*How to reproduce :*
- unzip eXo Platform 4.0.x (or 4.1-M1) tomcat distribution (Community or Express or
Enterprise)
- copy the jmxtrans-addon.war war in <PLATFORM_DIR>/webapps/ directory
- start your portal and watch the starup logs