It maybe your client servlet and server servlet share a same Application
context.
When the server servlet is refreshed, the client's Application is out of
date.

I do not read your code , I may am totally wrong.
It is just a guessing of your stack trace and notes.

Willem.


narend wrote:
> 
> Hi 
> I'm using Simple FrontEnd to expose a service deployed as a webapp. The
> client Servlet that consumes the service is in another webapp deployed on
> the same JBoss app server as the service. When I make a change to the
> service code and "hot-deploy" it & invoke the client servlet, I get the
> below error. 
> The error does not happen when I restart the app server which undeploys
> both webapps(client & service) & re-deploys both on startup. 
> Your opinions on this ?
> Is there a config setting that can be set to prevent this error? 
> One small breakthrough: (I cannot make sense of why this happens though)
> I noticed that if I accessed the WSDL url of the service from the browser
> before accessing the service itself then the error
> disappears....(sequence: hot-deploy service while client app is online,
> access wsdl url, access service)
> 
> 
> java.lang.IllegalStateException: BeanFactory not initialized or already
> closed - call 'refresh' before accessing beans via the ApplicationContext
>         at
> org.springframework.context.support.AbstractRefreshableApplicationContext.getBeanFactory(AbstractRefreshableApplicationContext.java:120)
>         at
> org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:703)
>         at
> org.apache.cxf.configuration.spring.SpringBeanMap.get(SpringBeanMap.java:193)
>         at
> org.apache.cxf.configuration.spring.SpringBeanMap.values(SpringBeanMap.java:239)
>         at
> org.apache.cxf.transport.DestinationFactoryManagerImpl.getDestinationFactoryForUri(DestinationFactoryManagerImpl.java:114)
>         at
> org.apache.cxf.frontend.AbstractEndpointFactory.createEndpointInfo(AbstractEndpointFactory.java:168)
>         at
> org.apache.cxf.frontend.AbstractEndpointFactory.createEndpoint(AbstractEndpointFactory.java:110)
>         at
> org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:50)
>         at
> org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:89)
> 

-- 
View this message in context: 
http://www.nabble.com/IllegalStateException%3A-in-client-when-CXF-service-is-hot-deployed-tf4654001.html#a13325464
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to