-
1. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 18, 2010 4:23 AM (in response to heiko.braun)From what I can tell it boils down to:
- Caused by: java.lang.RuntimeException: Error getting endpoint out of container KernelControllerContext UnmodifiableKernelControllerContext@3c4d63d0{}
- at org.jboss.ejb3.nointerface.impl.invocationhandler.NoInterfaceViewInvocationHandler.getInstalledEndpoint(NoInterfaceViewInvocationHandler.java:185)[:1.0.0-alpha-6]
- at org.jboss.ejb3.nointerface.impl.invocationhandler.NoInterfaceViewInvocationHandler.invoke(NoInterfaceViewInvocationHandler.java:143)[:1.0.0-alpha-6]
- at org.jboss.ejb3.proxy.javassist.JavassistInvocationHandlerAdapter.invoke(JavassistInvocationHandlerAdapter.java:71) [:1.0.0-alpha-1]
- at com.company.foo.ejb.ImportProgressNotifier_$$_javassist_17.setDispatcher(ImportProgressNotifier_$$_javassist_17.java) [:]
- at com.company.foo.gwt.server.errai.ImportProgressService.<init>(ImportProgressService.java:41) [:]
- at com.company.foo.gwt.server.errai.ImportProgressService$$FastClassByGuice$$4a938184.newInstance(<generated>)
- at com.google.inject.internal.cglib.reflect.FastConstructor.newInstance(FastConstructor.java:40) [:]
- at com.google.inject.DefaultConstructionProxyFactory$1.newInstance(DefaultConstructionProxyFactory.java:60) [:]
- at com.google.inject.ConstructorInjector.construct(ConstructorInjector.java:85) [:]
- at com.google.inject.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:111) [:]
- at com.google.inject.InjectorImpl$4$1.call(InjectorImpl.java:758) [:]
- at com.google.inject.InjectorImpl.callInContext(InjectorImpl.java:804) [:]
- at com.google.inject.InjectorImpl$4.get(InjectorImpl.java:754) [:]
- ... 83 more
- Caused by: java.lang.UnsupportedOperationException: Cannot invoke set on unmodifiable wrapper.
- at org.jboss.dependency.spi.helpers.UnmodifiableControllerContext.setRequiredState(UnmodifiableControllerContext.java:149) [jboss-dependency.jar:2.2.0.Alpha10]
- at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:936) [jboss-dependency.jar:2.2.0.Alpha10]
- at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:654) [jboss-dependency.jar:2.2.0.Alpha10]
- at org.jboss.ejb3.nointerface.impl.invocationhandler.NoInterfaceViewInvocationHandler.getInstalledEndpoint(NoInterfaceViewInvocationHandler.java:178)[:1.0.0-alpha-6]
-
2. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 18, 2010 4:28 AM (in response to heiko.braun)Digging a little further:
- com.company.foo.ejb.ImportProgressNotifier_$$_javassist_17.setDispatcher(ImportProgressNotifier_$$_javassist_17.java) [:]
- at com.company.foo.gwt.server.errai.ImportProgressService.<init>(ImportProgressService.java:41) [:]
- at com.company.foo.gwt.server.errai.ImportProgressService$$FastClassByGuice$$4a938184.newInstance(<generated>)
- at com.google.inject.internal.cglib.reflect.FastConstructor.newInstance(FastConstructor.java:40) [:]
- at com.google.inject.DefaultConstructionProxyFactory$1.newInstance(DefaultConstructionProxyFactory.java:60) [:]
- at com.google.inject.ConstructorInjector.construct(ConstructorInjector.java:85) [:]
- at com.google.inject.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:111) [:]
- at com.google.inject.InjectorImpl$4$1.call(InjectorImpl.java:758) [:]
- at com.google.inject.InjectorImpl.callInContext(InjectorImpl.java:804) [:]
- at com.google.inject.InjectorImpl$4.get(InjectorImpl.java:754) [:]
- ... 83 more
- Caused by: java.lang.UnsupportedOperationException: Cannot invoke set on unmodifiable wrapper.
-
3. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 18, 2010 4:29 AM (in response to heiko.braun)What does the ImportProgressNotifier EJB look like?
-
4. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 18, 2010 9:07 AM (in response to heiko.braun)The EJB: http://pastebin.org/571494
-
5. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 20, 2010 6:14 PM (in response to heiko.braun)With 1.1-CR1 I'm seeing a provision error in Glassfish as well.
[#|2010-08-20T16:56:18.694-0400|INFO|glassfish3.0.1|org.jboss.errai.bus.server.service.bootstrap.LoadExtensions|_ThreadID=29;_ThreadName=Thread-1;|total extension binding: 1|#] [#|2010-08-20T16:56:18.695-0400|SEVERE|glassfish3.0.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=29;_ThreadName=http-thread-pool-8080-(1);|WebModule[/myApp]StandardWrapper.Throwable com.google.inject.ProvisionException: Guice provision errors: 1) Error injecting constructor, java.lang.RuntimeException: Bootstrap failed at org.jboss.errai.bus.server.service.ErraiServiceImpl.(ErraiServiceImpl.java:50) while locating org.jboss.errai.bus.server.service.ErraiServiceImpl while locating org.jboss.errai.bus.server.service.ErraiService 1 error at com.google.inject.InjectorImpl$4.get(InjectorImpl.java:767) at com.google.inject.InjectorImpl.getInstance(InjectorImpl.java:789) at org.jboss.errai.bus.server.servlet.AbstractErraiServlet.buildService(AbstractErraiServlet.java:96) at org.jboss.errai.bus.server.servlet.AbstractErraiServlet.init(AbstractErraiServlet.java:80) at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1428) at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:1073) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:187) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:188) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:641) at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:97) at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:85) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:185) at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:325) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:226) at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:165) at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791) at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693) at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954) at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170) at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102) at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88) at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76) at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53) at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57) at com.sun.grizzly.ContextTask.run(ContextTask.java:69) at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330) at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309) at java.lang.Thread.run(Thread.java:619) Caused by: java.lang.RuntimeException: Bootstrap failed at org.jboss.errai.bus.server.service.bootstrap.OrderedBootstrap.execute(OrderedBootstrap.java:67) at org.jboss.errai.bus.server.service.ErraiServiceImpl.boostrap(ErraiServiceImpl.java:60) at org.jboss.errai.bus.server.service.ErraiServiceImpl.(ErraiServiceImpl.java:54) at org.jboss.errai.bus.server.service.ErraiServiceImpl$$FastClassByGuice$$7879947c.newInstance() at com.google.inject.internal.cglib.reflect.FastConstructor.newInstance(FastConstructor.java:40) at com.google.inject.DefaultConstructionProxyFactory$1.newInstance(DefaultConstructionProxyFactory.java:60) at com.google.inject.ConstructorInjector.construct(ConstructorInjector.java:85) at com.google.inject.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:111) at com.google.inject.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:45) at com.google.inject.InjectorImpl.callInContext(InjectorImpl.java:811) at com.google.inject.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:42) at com.google.inject.Scopes$1$1.get(Scopes.java:54) at com.google.inject.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:48) at com.google.inject.FactoryProxy.get(FactoryProxy.java:56) at com.google.inject.InjectorImpl$4$1.call(InjectorImpl.java:758) at com.google.inject.InjectorImpl.callInContext(InjectorImpl.java:804) at com.google.inject.InjectorImpl$4.get(InjectorImpl.java:754) ... 28 more Caused by: java.lang.IllegalStateException: can not modify the task manager once it's been initialized at org.jboss.errai.bus.client.api.base.TaskManagerFactory.setTaskManagerProvider(TaskManagerFactory.java:49) at org.jboss.errai.bus.server.service.bootstrap.DefaultResources.execute(DefaultResources.java:53) at org.jboss.errai.bus.server.service.bootstrap.OrderedBootstrap.execute(OrderedBootstrap.java:54) ... 44 more |#] (repeated a few times)... [#|2010-08-20T16:56:38.413-0400|INFO|glassfish3.0.1|org.jboss.errai.bus.server.service.bootstrap.OrderedBootstrap|_ThreadID=30;_ThreadName=Thread-1;|Bootstrap Errai|#]
-
6. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 23, 2010 4:55 AM (in response to jhutton)You want to use the CDI extension, right?
In that case two config options need to be set correctly
1.) Servlet init-param (jndiName)
2.) ErraisService property (auto_scan)
1) The init-param tells the servlet service where to locate the Errai Service
(Must be installed as a container service, provided for JBoss. Needs to be implemented for glassfish)
[...] <servlet> <servlet-name>ErraiServlet</servlet-name> <servlet-class>org.jboss.errai.bus.server.servlet.DefaultBlockingServlet</servlet-class> <init-param> <param-name>jndiName</param-name> <param-value>java:/Errai</param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> [...]
2) Since the service is installed a shared component and component discovery delegated to the CDI container,
you need to tell errai not to run the auto discovery.
ErraiService.properties: # # Disable service auto discovery # It's the CDI container responsibility # errai.auto_discover_services=false
One general thing. I would suggest we try to make it run on JBoss first, because it's act's as the reference for the CDI integration.
Once this works, we can talk about other containers.
-
7. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 23, 2010 4:57 AM (in response to heiko.braun)You can consult configuration files the CDI archetype creates, for all required configuration changes.
-
8. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 23, 2010 6:31 PM (in response to heiko.braun)Heiko,
Just to follow up, I didn't create my app with an errai archetype, but I did reference one when getting errai integrated. M2 has been working well for me in Glassfish, but I'm getting the error above with CR1.
I tried pulling in bits from the CDI archetype to get that running, but have not been successful. Even compiling the CDI archetype with no changes (with the jboss6 profile) and deploying to JBoss fails with this error: http://pastebin.org/750022
I'm not so much in need of the whole CDI + client integration thing. All I really want is to be able to access my @Service classes (or the ErraiBus itself) from some of my other backend components: ejbs or managed beans. BTW, are there lifecycle callbacks, eg. @PostConstruct, for @Service classes? If so, that might help me work around the original Guice provisioning error I was getting with JBoss. However, I think there are bigger problems, because as I said, I'm getting the provisioning error with Glassfish and CR1, and that's even if I comment out all the initialization code in my service classes.
One final data point regarding this: Installing a vanilla errai archetype (referencing the CR1 docs), ie no cdi, compiling and packaging with no changes at all gets me this on JBoss 6 M4: http://pastebin.org/750775.
Jesse
-
9. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 24, 2010 4:39 AM (in response to jhutton)Jesse, thanks for the follow up.
What OS / JDK Version are you using?
-
10. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 24, 2010 9:07 AM (in response to heiko.braun)By day, I'm using Fedora 12 with Sun's JDK 1.6.0_20. Last night, I installed JBoss 6 M4 on Fedora 13 with I think 1.6.0_21, and I got the same error with the CDI archetype. With the regular archetype, I didn't see the provision error, but the app didn't seem to deploy all the way. There would be a line about the context path, then a few errors regarding duplicate slf4j bindings, and then that's it: no errai bootstrap stuff.
-
11. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 24, 2010 10:00 AM (in response to jhutton)Try the most recent trunk. It should be fixed now.
If that's the case I might do another CR2.
/Heiko
-
12. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 24, 2010 10:35 AM (in response to heiko.braun)Heiko,
With the current trunk (revision 1917) the archetypes are still not working working for me. With the standard one I get http://pastie.org/1112405, and with CDI (I rebuilt that branch too) I get http://pastie.org/1112413.
Jesse
-
13. Re: Guice provisioning error on JBoss 6 M4
heiko.braun Aug 24, 2010 2:43 PM (in response to jhutton)Just to make I did nuke my local maven repo and created a project from the quickstart archeytpe. It deploys without any problems.
AFAIK the most recent SNAPSHOT was build from -r1921.
Even though it takes sometime to rebuild, I would suggest you do the same.
Otherwise try with 'mvn -U' (force updates)
-
14. Re: Guice provisioning error on JBoss 6 M4
jhutton Aug 24, 2010 11:48 PM (in response to heiko.braun)Heiko,
I just tried the quickstart archetype after again updating trunk (now at -r 1921), and still no success: http://pastie.org/1114011. Also, this is a recently installed OS (F13) so there was practically nothing in the maven repo. Just to be sure, I also tried building errai with mvn -U install. Same result.
Can anyone else test this with some version of Linux and a recent Sun JDK to at least confirm the problem or tell me that I'm out of my mind?
Jesse