2 Replies Latest reply on Jul 20, 2015 2:37 AM by Frank Henry

    WF8.1 occasional deployment issues with Weld

    Frank Henry Novice

      I am currently having a really strange problem with my deployments in a WF8.1 environment. We are running on an ARMv7 with Java HF version 1.8.0_33

      The problem is, if I start the service manually when the box is running it works 100% of the time. But when it comes out of a cold standby, I get randomly deployment issues on 1 or 2 (yeah, sometimes the 2nd also complains) EAR packages. Though it is always the same 2.

       

      Looking into the log files (see below) I can see that weld is complaining about the WAR not finding a service that is being supplied by an EJB, though both are in the same EAR.

      In the logs it mentions a remote interface for EAR 1, but that is simply the interface to it, in case EAR 2, it looks for the local interface. Changing the remote to local is on my to-do list, but it was never a problem so far.

      The wars are just basic servlets that use the @EJB annotation to inject the services.

       

      If I simply restart the service manually, everything is fine again. Putting the logging on debug yields no additional information, as far as I can tell. The lines below are the ONLY errors I get.

       

      Anyone have any clues why this is happening? Currently I am locked in to WF 8.1 so upgrade is currently not an option.

       

      I have only found a pull request for an issue regarding Weld dependencies: [WFLY-2561] Subdeployment DeploymentUnitPhaseService.INSTALL and WeldStartService dependency deadlock resulting in faile…

      But am unsure if this is releated.

       

      Thanks

       

      Relevant log entries (names have been obfuscated):

      2015-07-10 14:21:29,944 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC000001: Failed to start service jboss.deployment.unit."sensor-services.ear".WeldStartService: org.jboss.msc.service.StartException in service jboss.deployment.unit."sensor-services.ear".WeldStartService: Failed to start service

          at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]

          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_33]

          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_33]

          at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_33]

      Caused by: org.jboss.msc.service.ServiceNotFoundException: Service service jboss.deployment.subunit."sensor-services.ear"."sensor-services.jar".component.SensorServiceRemoteBean.VIEW."my.company.sensor.repository.facade.SensorServiceRemote".REMOTE not found

          at org.jboss.msc.service.ServiceContainerImpl.getRequiredService(ServiceContainerImpl.java:668) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]

          at org.jboss.as.weld.services.bootstrap.WeldEjbInjectionServices.getComponentView(WeldEjbInjectionServices.java:149)

          at org.jboss.as.weld.services.bootstrap.WeldEjbInjectionServices.handleServiceLookup(WeldEjbInjectionServices.java:124)

          at org.jboss.as.weld.services.bootstrap.WeldEjbInjectionServices.registerEjbInjectionPoint(WeldEjbInjectionServices.java:106)

          at org.jboss.weld.injection.ResourceInjectionFactory$EjbResourceInjectionProcessor.getResourceReferenceFactory(ResourceInjectionFactory.java:243)

          at org.jboss.weld.injection.ResourceInjectionFactory$EjbResourceInjectionProcessor.getResourceReferenceFactory(ResourceInjectionFactory.java:238)

          at org.jboss.weld.injection.ResourceInjectionFactory$ResourceInjectionProcessor.createSetterResourceInjection(ResourceInjectionFactory.java:219)

          at org.jboss.weld.injection.ResourceInjectionFactory$ResourceInjectionProcessor.createResourceInjections(ResourceInjectionFactory.java:190)

          at org.jboss.weld.injection.ResourceInjectionFactory.discoverType(ResourceInjectionFactory.java:405)

          at org.jboss.weld.injection.ResourceInjectionFactory.getResourceInjections(ResourceInjectionFactory.java:92)

          at org.jboss.weld.injection.producer.ResourceInjector.<init>(ResourceInjector.java:52)

          at org.jboss.weld.injection.producer.BeanInjectionTarget.initInjector(BeanInjectionTarget.java:55)

          at org.jboss.weld.injection.producer.BasicInjectionTarget.<init>(BasicInjectionTarget.java:68)

          at org.jboss.weld.injection.producer.BeanInjectionTarget.<init>(BeanInjectionTarget.java:49)

          at org.jboss.weld.manager.InjectionTargetFactoryImpl.chooseInjectionTarget(InjectionTargetFactoryImpl.java:126)

          at org.jboss.weld.manager.InjectionTargetFactoryImpl.createInjectionTarget(InjectionTargetFactoryImpl.java:88)

          at org.jboss.weld.bean.ManagedBean.<init>(ManagedBean.java:91)

          at org.jboss.weld.bean.ManagedBean.of(ManagedBean.java:71)

          at org.jboss.weld.bootstrap.AbstractBeanDeployer.createManagedBean(AbstractBeanDeployer.java:264)

          at org.jboss.weld.bootstrap.BeanDeployer.createClassBean(BeanDeployer.java:248)

          at org.jboss.weld.bootstrap.ConcurrentBeanDeployer$2.doWork(ConcurrentBeanDeployer.java:74)

          at org.jboss.weld.bootstrap.ConcurrentBeanDeployer$2.doWork(ConcurrentBeanDeployer.java:72)

          at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:60)

          at org.jboss.weld.executor.IterativeWorkerTaskFactory$1.call(IterativeWorkerTaskFactory.java:53)

          at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0_33]

          ... 3 more

       

      .... a few lines later ...

       

      2015-07-10 14:21:44,362 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) JBAS014613: Operation ("deploy") failed - address: ([("deployment" => "sensor-services.ear")]) - failure description: {

          "JBAS014671: Failed services" => {"jboss.deployment.unit.\"sensor-services.ear\".WeldStartService" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"sensor-services.ear\".WeldStartService: Failed to start service

          Caused by: org.jboss.msc.service.ServiceNotFoundException: Service service jboss.deployment.subunit.\"sensor-services.ear\".\"sensor-services.jar\".component.SensorServiceRemoteBean.VIEW.\"my.company.sensor.repository.facade.SensorServiceRemote\".REMOTE not found"},

          "JBAS014771: Services with missing/unavailable dependencies" => ["jboss.deployment.unit.\"sensor-services.ear\".deploymentCompleteService is missing [jboss.deployment.subunit.\"sensor-services.ear\".\"sensor-services-facade.war\".deploymentCompleteService]"]

      }

      2015-07-10 14:21:45,933 ERROR [org.jboss.as] (Controller Boot Thread) JBAS015875: WildFly 8.1.0.Final "Kenny" started (with errors) in 125932ms - Started 8046 of 8512 services (27 services failed or missing dependencies, 665 services are lazy, passive or on-demand)

      20