openejb-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <rmannibu...@gmail.com>
Subject Re: WebService cannot be Stateless? - ServletException
Date Sun, 12 Aug 2012 18:03:16 GMT
Hi,

can you share your sample?

do you use tomee 1.0.0 or the snapshot (1.1.0-SNAPSHOT)?

- Romain


2012/8/12 membersound <membersound@web.de>

> Can someone explain the following?
>
> Setup: basic webservice in a Dynamic Web Project with tomEE+. Index.xhtml
> as
> testsite.
>
> @Stateless
> @WebService...
> public class MyWS implements MyWSInterface
>
> @WebService
> public interface MyWSInterface
>
> If I now deploy the app, I'm getting following error:
>
>
>
> HTTP Status 500
>
> javax.servlet.ServletException: WebBeans context with scope type annotation
> @RequestScoped does not exist within current thread
>         javax.faces.webapp.FacesServlet.service(FacesServlet.java:229)
>
>
> root cause
>
> javax.enterprise.context.ContextNotActiveException: WebBeans context with
> scope type annotation @RequestScoped does not exist within current thread
>
>
> org.apache.webbeans.container.BeanManagerImpl.getContext(BeanManagerImpl.java:342)
>
>
> org.apache.webbeans.intercept.NormalScopedBeanInterceptorHandler.getContextualInstance(NormalScopedBeanInterceptorHandler.java:148)
>
>
> org.apache.webbeans.intercept.NormalScopedBeanInterceptorHandler.invoke(NormalScopedBeanInterceptorHandler.java:119)
>
>
> org.apache.webbeans.conversation.ConversationImpl_$$_javassist_0.isTransient(ConversationImpl_$$_javassist_0.java)
>
>
> org.apache.webbeans.jsf.WebBeansPhaseListener.beforePhase(WebBeansPhaseListener.java:103)
>
>
> org.apache.myfaces.lifecycle.PhaseListenerManager.informPhaseListenersBefore(PhaseListenerManager.java:77)
>
>
> org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:158)
>
> org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
>         javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
>
>
>
> It is solved my removing the @Stateless annotation. But I'd like to have it
> there.
> What am I doing wrong? Or how could I anyhow annoted my webservice
> Stateless?
>
> web.xml:
>     <servlet>
>         <servlet-name>Faces Servlet</servlet-name>
>         <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
>     </servlet>
>
>         <servlet-mapping>
>                 <servlet-name>Faces Servlet</servlet-name>
>                 <url-pattern>*.xhtml</url-pattern>
>         </servlet-mapping>
>
>     <welcome-file-list>
>        <welcome-file>index.xhtml</welcome-file>
>     </welcome-file-list>
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/WebService-cannot-be-Stateless-ServletException-tp4656815.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message