Coherence Application Throws Java.lang.NullPointerException (Doc ID 2189791.1)

Last updated on DECEMBER 21, 2016

Applies to:

Oracle Coherence - Version 3.7.1.1 to 12.2.1.1.0 [Release AS10g to 12c]
Information in this document applies to any platform.

Symptoms

On : 3.7.1.1 version, Oracle Coherence

Coherence JavaEE Web Application example in below documentation throws a NullPointerException

Step 4: Create and Run a Basic Coherence JavaEE Web Application


ERROR
-----------------------

<03/10/2016 10h13min29s BRT> <[ServletContext@800373294[app:hello module:hello.war path:null spec-version:null]] Servlet failed with an Exception
java.lang.NullPointerException
at com.tangosol.net.CacheFactory.getCache(CacheFactory.java:204)
at com.tangosol.net.CacheFactory.getCache(CacheFactory.java:181)
at jsp_servlet.__hello._jspService(__hello.java:83)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:242)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:216)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:132)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:338)
at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:453)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:364)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3292)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3262)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:57)
at weblogic.servlet.internal.WebAppServletContext.doSecuredExecute(WebAppServletContext.java:2171)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2097)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2075)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1513)
at weblogic.servlet.provider.ContainerSupportProviderImpl$WlsRequestExecutor.run(ContainerSupportProviderImpl.java:254)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
>



Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms