java.lang.reflect.InvocationTargetException

tip

This happens when you try to instantiate a class that can't be instantiated, either because the class object is abstract, an interface, an array class, a primitive type, void, or because the class has no nullary constructor.

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Steps to reproduce: 1. Set up two bundles. 2. In both bundles: Add the following properties to the portal-ext.properties: {noformat} cluster.link.enabled=true ehcache.cluster.link.replication.enabled=true {noformat} Add "replicatePutsViaCopy=true" under "defaultCache" section in liferay-multi-vm-clustered.xml (turn others to true also). {panel} <defaultCache eternal="false" maxElementsInMemory="10000" overflowToDisk="false" timeToIdleSeconds="600" > <cacheEventListenerFactory class="com.liferay.portal.cache.ehcache.LiferayCacheEventListenerFactory" properties="{color:red}replicatePutsViaCopy=true,replicatePuts=true,replicateUpdatesViaCopy=true{color}" propertySeparator="," /> <bootstrapCacheLoaderFactory class="com.liferay.portal.cache.ehcache.LiferayBootstrapCacheLoaderFactory" /> </defaultCache> {panel} 3. Deploy ehcache-cluster-web plugins in both bundles. 4. Start up bundles in sequence. 5. On one bundle site, go to control panel -> server administration -> script. Choose language as Groovy, put script as: {code} com.liferay.portal.kernel.cache.PortalCache pc = com.liferay.portal.kernel.cache.MultiVMPoolUtil.getCache("testCacheId"); pc.put("one", "ONE"); pc.put("two", "TWO"); pc.put("three", "THREE"); {code} then hit "Execute" button. Error Message 1: {noformat} 05:54:44,276 ERROR [Incoming-2,LIFERAY-CONTROL-CHANNEL,Shelton-14829][ClusterRequestReceiver:92] Una ble to invoke method {arguments=[{arguments=null, methodKey=com.liferay.portal.service.PortletLocalS ervice.clearCompanyPortletsPool)}, com.liferay.portal.service.PortletLocalService, , null, {}], meth odKey=com.liferay.portal.cluster.ClusterableAdvice._invoke(com.liferay.portal.kernel.util.MethodHand ler,java.lang.String,java.lang.String,java.lang.Class,java.util.Map)} java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:61) at com.liferay.portal.cluster.ClusterRequestReceiver.processClusterRequest(ClusterRequestRec eiver.java:237) at com.liferay.portal.cluster.ClusterRequestReceiver.receive(ClusterRequestReceiver.java:87) at org.jgroups.JChannel.invokeCallback(JChannel.java:749) at org.jgroups.JChannel.up(JChannel.java:710) at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1025) at org.jgroups.protocols.RSVP.up(RSVP.java:188) at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) at org.jgroups.protocols.FlowControl.up(FlowControl.java:400) at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) at org.jgroups.protocols.pbcast.GMS.up(GMS.java:896) at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:245) at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:453) at org.jgroups.protocols.pbcast.NAKACK2.handleMessage(NAKACK2.java:763) at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:574) at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:147) at org.jgroups.protocols.FD_ALL.up(FD_ALL.java:187) at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) at org.jgroups.protocols.MERGE3.up(MERGE3.java:290) at org.jgroups.protocols.Discovery.up(Discovery.java:359) at org.jgroups.protocols.TP.passMessageUp(TP.java:1263) at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1825) at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1793) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.InstantiationException: com.liferay.portal.service.PortletLocalService at java.lang.Class.newInstance0(Class.java:340) at java.lang.Class.newInstance(Class.java:308) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:58) at com.liferay.portal.cluster.ClusterableAdvice._invoke(ClusterableAdvice.java:163) ... 30 more 05:55:08,444 ERROR [Incoming-1,LIFERAY-CONTROL-CHANNEL,Shelton-14829][PortletBeanLocatorUtil:87] Bea nLocator is null for servlet context com.liferay.portal.service.PortletLocalService 05:55:08,446 ERROR [Incoming-1,LIFERAY-CONTROL-CHANNEL,Shelton-14829][ClusterRequestReceiver:92] Una ble to invoke method {arguments=[{arguments=null, methodKey=com.liferay.portal.service.PortletLocalS ervice.clearCompanyPortletsPool)}, com.liferay.portal.service.PortletLocalService, marketplace-portl et, null, {}], methodKey=com.liferay.portal.cluster.ClusterableAdvice._invoke(com.liferay.portal.ker nel.util.MethodHandler,java.lang.String,java.lang.String,java.lang.Class,java.util.Map)} java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:61) at com.liferay.portal.cluster.ClusterRequestReceiver.processClusterRequest(ClusterRequestRec eiver.java:237) at com.liferay.portal.cluster.ClusterRequestReceiver.receive(ClusterRequestReceiver.java:87) at org.jgroups.JChannel.invokeCallback(JChannel.java:749) at org.jgroups.JChannel.up(JChannel.java:710) at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1025) at org.jgroups.protocols.RSVP.up(RSVP.java:188) at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) at org.jgroups.protocols.FlowControl.up(FlowControl.java:400) at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) at org.jgroups.protocols.pbcast.GMS.up(GMS.java:896) at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:245) at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:453) at org.jgroups.protocols.pbcast.NAKACK2.handleMessage(NAKACK2.java:763) at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:574) at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:147) at org.jgroups.protocols.FD_ALL.up(FD_ALL.java:187) at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) at org.jgroups.protocols.MERGE3.up(MERGE3.java:290) at org.jgroups.protocols.Discovery.up(Discovery.java:359) at org.jgroups.protocols.TP.passMessageUp(TP.java:1263) at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1825) at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1793) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: com.liferay.portal.kernel.bean.BeanLocatorException: BeanLocator has not been set for ser vlet context com.liferay.portal.service.PortletLocalService at com.liferay.portal.kernel.bean.PortletBeanLocatorUtil.locate(PortletBeanLocatorUtil.java: 46) at com.liferay.portal.cluster.ClusterableAdvice._invoke(ClusterableAdvice.java:166) ... 30 more {noformat} Error Message 2: {noformat} 05:58:02,405 ERROR [liferay/ehcache_cluster-1][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=com.liferay.portal.kernel.dao.orm.FinderCache.com.liferay.portal.model.impl.PhoneImpl.List2 :2647133972934363004:[]:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,847 ERROR [liferay/ehcache_cluster-2][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:two:TWO:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,848 ERROR [liferay/ehcache_cluster-1][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:three:THREE:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,848 ERROR [liferay/ehcache_cluster-3][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:one:ONE:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more {noformat} Expected result: No error will be seen in the whole process. Actual result: The Error Message 1 was thrown in first bundle when start up the second one. The Error Message 2 was thrown in second bundle when clicking on "Execute" through the portal which was started first.
    via by Shitian "Shelton" Zhang,
  • Steps to reproduce: 1. Set up two bundles. 2. In both bundles: Add the following properties to the portal-ext.properties: {noformat} cluster.link.enabled=true ehcache.cluster.link.replication.enabled=true {noformat} Add "replicatePutsViaCopy=true" under "defaultCache" section in liferay-multi-vm-clustered.xml (turn others to true also). {panel} <defaultCache eternal="false" maxElementsInMemory="10000" overflowToDisk="false" timeToIdleSeconds="600" > <cacheEventListenerFactory class="com.liferay.portal.cache.ehcache.LiferayCacheEventListenerFactory" properties="{color:red}replicatePutsViaCopy=true,replicatePuts=true,replicateUpdatesViaCopy=true{color}" propertySeparator="," /> <bootstrapCacheLoaderFactory class="com.liferay.portal.cache.ehcache.LiferayBootstrapCacheLoaderFactory" /> </defaultCache> {panel} 3. Deploy ehcache-cluster-web plugins in both bundles. 4. Start up bundles in sequence. 5. On one bundle site, go to control panel -> server administration -> script. Choose language as Groovy, put script as: {code} com.liferay.portal.kernel.cache.PortalCache pc = com.liferay.portal.kernel.cache.MultiVMPoolUtil.getCache("testCacheId"); pc.put("one", "ONE"); pc.put("two", "TWO"); pc.put("three", "THREE"); {code} then hit "Execute" button. Error Message 1: {noformat} 05:54:44,276 ERROR [Incoming-2,LIFERAY-CONTROL-CHANNEL,Shelton-14829][ClusterRequestReceiver:92] Una ble to invoke method {arguments=[{arguments=null, methodKey=com.liferay.portal.service.PortletLocalS ervice.clearCompanyPortletsPool)}, com.liferay.portal.service.PortletLocalService, , null, {}], meth odKey=com.liferay.portal.cluster.ClusterableAdvice._invoke(com.liferay.portal.kernel.util.MethodHand ler,java.lang.String,java.lang.String,java.lang.Class,java.util.Map)} java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:61) at com.liferay.portal.cluster.ClusterRequestReceiver.processClusterRequest(ClusterRequestRec eiver.java:237) at com.liferay.portal.cluster.ClusterRequestReceiver.receive(ClusterRequestReceiver.java:87) at org.jgroups.JChannel.invokeCallback(JChannel.java:749) at org.jgroups.JChannel.up(JChannel.java:710) at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1025) at org.jgroups.protocols.RSVP.up(RSVP.java:188) at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) at org.jgroups.protocols.FlowControl.up(FlowControl.java:400) at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) at org.jgroups.protocols.pbcast.GMS.up(GMS.java:896) at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:245) at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:453) at org.jgroups.protocols.pbcast.NAKACK2.handleMessage(NAKACK2.java:763) at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:574) at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:147) at org.jgroups.protocols.FD_ALL.up(FD_ALL.java:187) at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) at org.jgroups.protocols.MERGE3.up(MERGE3.java:290) at org.jgroups.protocols.Discovery.up(Discovery.java:359) at org.jgroups.protocols.TP.passMessageUp(TP.java:1263) at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1825) at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1793) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.InstantiationException: com.liferay.portal.service.PortletLocalService at java.lang.Class.newInstance0(Class.java:340) at java.lang.Class.newInstance(Class.java:308) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:58) at com.liferay.portal.cluster.ClusterableAdvice._invoke(ClusterableAdvice.java:163) ... 30 more 05:55:08,444 ERROR [Incoming-1,LIFERAY-CONTROL-CHANNEL,Shelton-14829][PortletBeanLocatorUtil:87] Bea nLocator is null for servlet context com.liferay.portal.service.PortletLocalService 05:55:08,446 ERROR [Incoming-1,LIFERAY-CONTROL-CHANNEL,Shelton-14829][ClusterRequestReceiver:92] Una ble to invoke method {arguments=[{arguments=null, methodKey=com.liferay.portal.service.PortletLocalS ervice.clearCompanyPortletsPool)}, com.liferay.portal.service.PortletLocalService, marketplace-portl et, null, {}], methodKey=com.liferay.portal.cluster.ClusterableAdvice._invoke(com.liferay.portal.ker nel.util.MethodHandler,java.lang.String,java.lang.String,java.lang.Class,java.util.Map)} java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:61) at com.liferay.portal.cluster.ClusterRequestReceiver.processClusterRequest(ClusterRequestRec eiver.java:237) at com.liferay.portal.cluster.ClusterRequestReceiver.receive(ClusterRequestReceiver.java:87) at org.jgroups.JChannel.invokeCallback(JChannel.java:749) at org.jgroups.JChannel.up(JChannel.java:710) at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1025) at org.jgroups.protocols.RSVP.up(RSVP.java:188) at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) at org.jgroups.protocols.FlowControl.up(FlowControl.java:400) at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) at org.jgroups.protocols.pbcast.GMS.up(GMS.java:896) at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:245) at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:453) at org.jgroups.protocols.pbcast.NAKACK2.handleMessage(NAKACK2.java:763) at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:574) at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:147) at org.jgroups.protocols.FD_ALL.up(FD_ALL.java:187) at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) at org.jgroups.protocols.MERGE3.up(MERGE3.java:290) at org.jgroups.protocols.Discovery.up(Discovery.java:359) at org.jgroups.protocols.TP.passMessageUp(TP.java:1263) at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1825) at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1793) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: com.liferay.portal.kernel.bean.BeanLocatorException: BeanLocator has not been set for ser vlet context com.liferay.portal.service.PortletLocalService at com.liferay.portal.kernel.bean.PortletBeanLocatorUtil.locate(PortletBeanLocatorUtil.java: 46) at com.liferay.portal.cluster.ClusterableAdvice._invoke(ClusterableAdvice.java:166) ... 30 more {noformat} Error Message 2: {noformat} 05:58:02,405 ERROR [liferay/ehcache_cluster-1][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=com.liferay.portal.kernel.dao.orm.FinderCache.com.liferay.portal.model.impl.PhoneImpl.List2 :2647133972934363004:[]:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,847 ERROR [liferay/ehcache_cluster-2][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:two:TWO:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,848 ERROR [liferay/ehcache_cluster-1][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:three:THREE:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more 05:58:02,848 ERROR [liferay/ehcache_cluster-3][ParallelDestination:92] Unable to process message {de stinationName=liferay/ehcache_cluster, response=null, responseDestinationName=null, responseId=null, payload=testCacheId:one:ONE:PUT, values={CLUSTER_FORWARD_MESSAGE=true, companyId=0}} com.liferay.portal.kernel.messaging.MessageListenerException: java.lang.NullPointerException at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 32) at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener .java:72) at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:69 ) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExe cutor.java:682) at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor .java:593) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.NullPointerException at com.liferay.portal.cache.cluster.clusterlink.messaging.ClusterLinkPortalCacheClusterListe ner.doReceive(ClusterLinkPortalCacheClusterListener.java:70) at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java: 26) ... 5 more {noformat} Expected result: No error will be seen in the whole process. Actual result: The Error Message 1 was thrown in first bundle when start up the second one. The Error Message 2 was thrown in second bundle when clicking on "Execute" through the portal which was started first.
    via by Shitian "Shelton" Zhang,
  • GitHub comment 32#6733959
    via GitHub by marioosh-net
    ,
  • Getting started with ReST
    via by akhil achuthan,
  • Hibernate DAO factory cannot instantiate dao
    via Stack Overflow by m4ri0
    ,
    • java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:61) at com.liferay.portal.cluster.ClusterRequestReceiver.processClusterRequest(ClusterRequestReceiver.java:237) at com.liferay.portal.cluster.ClusterRequestReceiver.receive(ClusterRequestReceiver.java:87) at org.jgroups.JChannel.invokeCallback(JChannel.java:749) at org.jgroups.JChannel.up(JChannel.java:710) at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1025) at org.jgroups.protocols.RSVP.up(RSVP.java:188) at org.jgroups.protocols.FRAG2.up(FRAG2.java:181) at org.jgroups.protocols.FlowControl.up(FlowControl.java:400) at org.jgroups.protocols.FlowControl.up(FlowControl.java:418) at org.jgroups.protocols.pbcast.GMS.up(GMS.java:896) at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:245) at org.jgroups.protocols.UNICAST2.up(UNICAST2.java:453) at org.jgroups.protocols.pbcast.NAKACK2.handleMessage(NAKACK2.java:763) at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:574) at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:147) at org.jgroups.protocols.FD_ALL.up(FD_ALL.java:187) at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:288) at org.jgroups.protocols.MERGE3.up(MERGE3.java:290) at org.jgroups.protocols.Discovery.up(Discovery.java:359) at org.jgroups.protocols.TP.passMessageUp(TP.java:1263) at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1825) at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1793) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) Caused by: java.lang.InstantiationException: com.liferay.portal.service.PortletLocalService at java.lang.Class.newInstance0(Class.java:340) at java.lang.Class.newInstance(Class.java:308) at com.liferay.portal.kernel.util.MethodHandler.invoke(MethodHandler.java:58) at com.liferay.portal.cluster.ClusterableAdvice._invoke(ClusterableAdvice.java:163) ... 30 more

    Users with the same issue

    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor2 times, last one,
    38 more bugmates