Issue Details (XML | Word | Printable)

Key: GLASSFISH-20142
Type: Bug Bug
Status: Resolved Resolved
Resolution: Cannot Reproduce
Priority: Major Major
Assignee: jjsnyder83
Reporter: myfear
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
glassfish

Accessing an @Inject JMSContext in a @ServerEndpoint leads to org.jboss.weld.context.ContextNotActiveException

Created: 03/Apr/13 07:44 AM   Updated: 17/Apr/13 06:16 PM   Resolved: 17/Apr/13 06:16 PM
Component/s: cdi
Affects Version/s: 4.0_b81
Fix Version/s: 4.0_b85

Time Tracking:
Not Specified

Environment:

Java 1.7_15
Win7 x64


Tags: fishcat
Participants: jjsnyder83 and myfear


 Description  « Hide

The example app is here: https://www.dropbox.com/s/n8uhy2uka8p5vo4/websockets-demo.zip

launch with button click from here: http://localhost:8080/websockets-demo/

org.jboss.weld.context.ContextNotActiveException: WELD-001303 No active contexts for scope type javax.enterprise.context.RequestScoped
at org.jboss.weld.manager.BeanManagerImpl.getContext(BeanManagerImpl.java:662)
at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:74)
at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:82)
at org.glassfish.jms.injection.RequestedJMSContextManager$Proxy$_$$_WeldClientProxy.getType(Unknown Source)
at org.glassfish.jms.injection.InjectableJMSContext.delegate(InjectableJMSContext.java:121)
at org.glassfish.jms.injection.ForwardingJMSContext.createProducer(ForwardingJMSContext.java:61)
at net.eisele.samples.websockets.demo.HelloEndpoint.boradcastMessage(HelloEndpoint.java:60)
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.tyrus.core.AnnotatedEndpoint.callMethod(AnnotatedEndpoint.java:431)
at org.glassfish.tyrus.core.AnnotatedEndpoint.access$100(AnnotatedEndpoint.java:83)
at org.glassfish.tyrus.core.AnnotatedEndpoint$WholeHandler$1.onMessage(AnnotatedEndpoint.java:518)
at org.glassfish.tyrus.core.SessionImpl.notifyMessageHandlers(SessionImpl.java:305)
at org.glassfish.tyrus.core.EndpointWrapper.onMessage(EndpointWrapper.java:462)
at org.glassfish.tyrus.server.TyrusEndpoint.onMessage(TyrusEndpoint.java:163)
at org.glassfish.tyrus.websockets.DefaultWebSocket.onMessage(DefaultWebSocket.java:138)
at org.glassfish.tyrus.websockets.frametypes.TextFrameType.respond(TextFrameType.java:66)
at org.glassfish.tyrus.websockets.DataFrame.respond(DataFrame.java:102)
at org.glassfish.tyrus.servlet.TyrusHttpUpgradeHandler.onDataAvailable(TyrusHttpUpgradeHandler.java:113)
at org.apache.catalina.connector.InputBuffer$ReadHandlerImpl.processDataAvailable(InputBuffer.java:472)
at org.apache.catalina.connector.InputBuffer$ReadHandlerImpl.onDataAvailable(InputBuffer.java:440)
at org.glassfish.grizzly.http.io.InputBuffer.append(InputBuffer.java:854)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:222)
at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:119)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:288)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:206)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:136)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:114)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:77)
at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:838)
at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:113)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:115)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.access$100(WorkerThreadIOStrategy.java:55)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:135)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:564)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:544)
at java.lang.Thread.run(Thread.java:722)



jjsnyder83 added a comment - 11/Apr/13 09:25 PM

Please email me the zip...I cannot open the attached zip: j.j.snyder@oracle.com


jjsnyder83 added a comment - 17/Apr/13 06:16 PM

I could not reproduce the error. When I clicked on the link I got:

Hello World!