javaeetutorial
  1. javaeetutorial
  2. JAVAEETUTORIAL-250

54.5 The jobs Concurrency Example missing info and won't run

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Works as designed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: examples
    • Labels:
      None
    • Environment:

      JavaEE 7.0.21, glassfish-4.0.1-b03

      Description

      I followed the tutorial http://docs.oracle.com/javaee/7/tutorial/doc/concurrency-utilities005.htm#CIHCGGEG (54.5 The jobs Concurrency Example) and there is a configuration options missing.

      • I had to set glassfish.home.prefix property in docs/javaee-tutorial/examples/pom.xml and nowhere does the Tutorial or that documentation say to do this

      And then once fixed I couldn't get to work in Netbeans or through Maven as discussed. The reasons are:

      • Firstly was due to an empty beans.xml file - /docs/javaee-tutorial/examples/concurrency/jobs/src/main/webapp/WEB-INF/beans.xml
      • Second was an error I could not work out without becoming more familiar with the code which I don't have time to do now (when all I want to do is see the examples working as described). The error is as below.

      I'm looking forward to seeing this working!

      Cheers,

      Brooke

      2013-09-23 10:47:01 .390+1000 [SEVERE] - WebModule[/jobs]StandardWrapper.Throwable
      java.lang.IllegalStateException: Error when configuring to use the EJB interceptor binding API. JAX-RS EJB integration can not be supported.
      at org.glassfish.jersey.gf.ejb.EjbComponentProvider.registerEjbInterceptor(EjbComponentProvider.java:167)
      at org.glassfish.jersey.gf.ejb.EjbComponentProvider.bind(EjbComponentProvider.java:199)
      ...
      Caused by: java.lang.reflect.InvocationTargetException
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:601)
      at org.glassfish.jersey.gf.ejb.EjbComponentProvider.registerEjbInterceptor(EjbComponentProvider.java:162)
      ... 92 more
      Caused by: java.lang.NullPointerException
      at com.sun.ejb.containers.InternalInterceptorBindingImpl.registerInterceptor(InternalInterceptorBindingImpl.java:97)
      ... 97 more
      2013-09-23 10:47:01 .391+1000 [SEVERE] - WebModule[/jobs]Servlet /jobs threw load() exception
      java.lang.NullPointerException
      at com.sun.ejb.containers.InternalInterceptorBindingImpl.registerInterceptor(InternalInterceptorBindingImpl.java:97)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      ...
      2013-09-23 10:47:01 .391+1000 [SEVERE] - Startup of context /jobs failed due to previous errors]]
      2013-09-23 10:47:01 .395+1000 [SEVERE] - ContainerBase.addChild: start:
      org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      at org.apache.catalina.core.StandardContext.start(StandardContext.java:5954)
      at com.sun.enterprise.web.WebModule.start(WebModule.java:691)
      ...
      Caused by: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5712)
      at org.apache.catalina.core.StandardContext.start(StandardContext.java:5946)
      ... 72 more
      Caused by: java.lang.NullPointerException
      at com.sun.ejb.containers.InternalInterceptorBindingImpl.registerInterceptor(InternalInterceptorBindingImpl.java:97)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:601)
      at org.glassfish.jersey.gf.ejb.EjbComponentProvider.registerEjbInterceptor(EjbComponentProvider.java:162)
      at org.glassfish.jersey.gf.ejb.EjbComponentProvider.bind(EjbComponentProvider.java:199)
      at org.glassfish.jersey.server.ApplicationHandler.bindWithComponentProvider(ApplicationHandler.java:845)
      at org.glassfish.jersey.server.ApplicationHandler.bindProvidersAndResources(ApplicationHandler.java:775)
      at org.glassfish.jersey.server.ApplicationHandler.initialize(ApplicationHandler.java:396)
      at org.glassfish.jersey.server.ApplicationHandler.access$500(ApplicationHandler.java:161)
      at org.glassfish.jersey.server.ApplicationHandler$3.run(ApplicationHandler.java:286)
      at org.glassfish.jersey.internal.Errors$2.call(Errors.java:289)
      at org.glassfish.jersey.internal.Errors$2.call(Errors.java:286)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
      at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
      at org.glassfish.jersey.internal.Errors.processWithException(Errors.java:286)
      at org.glassfish.jersey.server.ApplicationHandler.<init>(ApplicationHandler.java:283)
      at org.glassfish.jersey.servlet.WebComponent.<init>(WebComponent.java:298)
      at org.glassfish.jersey.servlet.ServletContainer.init(ServletContainer.java:167)
      at org.glassfish.jersey.servlet.ServletContainer.init(ServletContainer.java:349)
      at javax.servlet.GenericServlet.init(GenericServlet.java:244)
      at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1583)
      at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1382)
      at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5704)
      ... 73 more
      2013-09-23 10:47:01 .396+1000 [WARNING] - java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:1044)
      ...
      2013-09-23 10:47:01 .396+1000 [SEVERE] - Exception while invoking class com.sun.enterprise.web.WebApplication start method
      java.lang.Exception: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      at com.sun.enterprise.web.WebApplication.start(WebApplication.java:168)
      at org.glassfish.internal.data.EngineRef.start(EngineRef.java:122)
      ...
      2013-09-23 10:47:01 .397+1000 [SEVERE] - Exception during lifecycle processing
      java.lang.Exception: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException
      at com.sun.enterprise.web.WebApplication.start(WebApplication.java:168)
      ...
      2013-09-23 10:47:01 .397+1000 [SEVERE] - Exception while loading the app]]
      2013-09-23 10:47:01 .403+1000 [SEVERE] - Undeployment failed for context /jobs]]
      2013-09-23 10:47:01 .418+1000 [SEVERE] - Exception while loading the app : java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.apache.catalina.LifecycleException: java.lang.NullPointerException]]

        Activity

          People

          • Assignee:
            Unassigned
            Reporter:
            HankCa
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: