0 Replies Latest reply on Feb 23, 2012 6:15 AM by Vojtěch Bartoš

    mediaOutput Null Pointer Exception

    Vojtěch Bartoš Newbie

      Hi,

       

      can anybody help me please?

       

      I use glassfish 3.1.1

      I downloaded RichFaces 4.1.0Final and folowed https://community.jboss.org/wiki/HowToAddRichFaces4xToProjectsNotBasedOnMaven

      Then I tried simple web app using component calendar just to be sure it works

       

      Now I need to draw generated image (chart by JFreeChart library) but for now I just copy example code from Documentation http://docs.jboss.org/richfaces/latest_4_1_X/Component_Reference/en-US/html/chap-Component_Reference-Resources.html#sect-Component_Reference-a4jmediaOutput-Basic_usage

       

      And now it comes - when i run my example app, I will get this error message and picture on page is just small white square with black border...

       

      WARNING: ApplicationDispatcher[] PWC1231: Servlet.service() for servlet FacesServlet threw exception

      java.lang.NullPointerException

                at com.sun.faces.config.InitFacesContext.release(InitFacesContext.java:214)

                at javax.faces.webapp.FacesServlet.service(FacesServlet.java:577)

                at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1539)

                at org.apache.catalina.core.ApplicationDispatcher.doInvoke(ApplicationDispatcher.java:787)

                at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:649)

                at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:483)

                at org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:454)

                at org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:350)

                at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:300)

                at org.glassfish.admingui.common.security.AdminConsoleAuthModule.validateRequest(AdminConsoleAuthModule.java:231)

                at com.sun.enterprise.security.jmac.config.GFServerConfigProvider$GFServerAuthContext.validateRequest(GFServerConfigProvider.java:1171)

                at com.sun.web.security.RealmAdapter.validate(RealmAdapter.java:1445)

                at com.sun.web.security.RealmAdapter.invokeAuthenticateDelegate(RealmAdapter.java:1323)

                at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:551)

                at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:623)

                at org.apache.catalina.core.StandardPipeline.doChainInvoke(StandardPipeline.java:600)

                at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:96)

                at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:91)

                at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:162)

                at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:330)

                at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:231)

                at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:232)

                at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:828)

                at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:725)

                at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1019)

                at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)

                at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)

                at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)

                at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)

                at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)

                at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)

                at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)

                at com.sun.grizzly.ContextTask.run(ContextTask.java:71)

                at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)

                at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)

                at java.lang.Thread.run(Thread.java:662)

       

      Did I forget something during instalation or what? I realy dont know, what to do.... and I will be grateful for any help!