I think you removed some elements of the stack. Can you supply them as
well? Also, have you tried using adminService directly in
postConstruct() method? Does it result in same exception?
Sahoo
On Thursday 02 June 2011 06:58 PM, forums_at_java.net wrote:
> [quote=Sahoo]What happens if you replace @Inject private MyServiceBean
> adminService; by @EJB private MyServiceBean adminService;[/quote]
>
> When I invoke the ServiceListener with pseudo event, I get an exception:
>
> javax.ejb.EJBException: Attempt to invoke when container is in
> Undeployed at
> com.sun.ejb.containers.BaseContainer.postInvoke(BaseContainer.java:1995)
> at
> com.sun.ejb.containers.BaseContainer.postInvoke(BaseContainer.java:1990)
> at
> com.sun.ejb.containers.EJBLocalObjectInvocationHandler.invoke(EJBLocalObjectInvocationHandler.java:222)
>
> at
> com.sun.ejb.containers.EJBLocalObjectInvocationHandlerDelegate.invoke(EJBLocalObjectInvocationHandlerDelegate.java:88)
>
> at $Proxy254.installService(Unknown Source) at
> com.test.InstallServicesBean$MyServiceListener.serviceChanged(InstallServicesBean.java:72)
>
> at
> org.apache.felix.framework.util.EventDispatcher.invokeServiceListenerCallback(EventDispatcher.java:871)
>
> at
> org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:733)
>
> at
> org.apache.felix.framework.util.EventDispatcher.fireServiceEvent(EventDispatcher.java:662)
>
> at org.apache.felix.framework.Felix.fireServiceEvent(Felix.java:3769) at
> org.apache.felix.framework.Felix.access$000(Felix.java:80) at
> org.apache.felix.framework.Felix$2.serviceChanged(Felix.java:722) at
> org.apache.felix.framework.ServiceRegistry.registerService(ServiceRegistry.java:107)
>
> at org.apache.felix.framework.Felix.registerService(Felix.java:2854)
> thanks
>
>
> --
>
> [Message sent by forum member 'okna2000']
>
> View Post: http://forums.java.net/node/808455
>
>