Return-Path: Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: (qmail 42361 invoked from network); 31 Mar 2011 07:50:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 31 Mar 2011 07:50:50 -0000 Received: (qmail 52968 invoked by uid 500); 31 Mar 2011 07:50:50 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 52824 invoked by uid 500); 31 Mar 2011 07:50:49 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 52593 invoked by uid 99); 31 Mar 2011 07:50:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 31 Mar 2011 07:50:46 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 31 Mar 2011 07:50:43 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id C40DE8B2E2 for ; Thu, 31 Mar 2011 07:50:05 +0000 (UTC) Date: Thu, 31 Mar 2011 07:50:05 +0000 (UTC) From: "Willem Jiang (JIRA)" To: issues@cxf.apache.org Message-ID: <1625830660.23718.1301557805799.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <365806881.17622.1301348885759.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (CXF-3428) Context closed twice with Spring setup MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CXF-3428?page=3Dcom.atlassian.j= ira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D130138= 71#comment-13013871 ]=20 Willem Jiang commented on CXF-3428: ----------------------------------- @Anders, I committed a patch into CXF 2.3.x-fixes branch and I also tested the patch= with your test case, it should be OK now. Please check out the CXF 2.3.4-SNAPSHOT for verification. > Context closed twice with Spring setup > -------------------------------------- > > Key: CXF-3428 > URL: https://issues.apache.org/jira/browse/CXF-3428 > Project: CXF > Issue Type: Bug > Affects Versions: 2.3.2, 2.3.3 > Environment: Windows 7, both Java 5 and 6, and both Jetty 7.3 and= Tomcat 7. > Reporter: Anders B=C3=A5tstrand > Assignee: Willem Jiang > Labels: context, spring > Fix For: 2.3.4 > > Attachments: context-bug.zip > > > See the enclosed project (very minimal). > I have a cxf.cml and an applicationContext.xml, and loads both using Cont= extLoaderListener in my web.xml. I have also a CXFServlet. Starting this wi= th Jetty, I get the following exception when I stop the server: > {code} > 28.mar.2011 23:43:15 org.springframework.context.support.AbstractApplicat= ionContext doClose > WARNING: Exception thrown from ApplicationListener handling ContextClosed= Event > java.lang.IllegalStateException: BeanFactory not initialized or already c= losed - call 'refresh' before accessing beans via the ApplicationContext > =09at org.springframework.context.support.AbstractRefreshableApplicationC= ontext.getBeanFactory(AbstractRefreshableApplicationContext.java:171) > =09at org.springframework.context.support.AbstractApplicationContext.getB= ean(AbstractApplicationContext.java:1079) > =09at org.apache.cxf.bus.spring.BusApplicationListener.onApplicationEvent= (BusApplicationListener.java:66) > =09at org.springframework.context.event.SimpleApplicationEventMulticaster= .multicastEvent(SimpleApplicationEventMulticaster.java:97) > =09at org.springframework.context.support.AbstractApplicationContext.publ= ishEvent(AbstractApplicationContext.java:303) > =09at org.springframework.context.support.AbstractApplicationContext.doCl= ose(AbstractApplicationContext.java:1007) > =09at org.springframework.context.support.AbstractApplicationContext.clos= e(AbstractApplicationContext.java:970) > =09at org.springframework.web.context.ContextLoader.closeWebApplicationCo= ntext(ContextLoader.java:378) > =09at org.springframework.web.context.ContextLoaderListener.contextDestro= yed(ContextLoaderListener.java:78) > =09at org.eclipse.jetty.server.handler.ContextHandler.doStop(ContextHandl= er.java:683) > =09at org.eclipse.jetty.servlet.ServletContextHandler.doStop(ServletConte= xtHandler.java:143) > =09at org.eclipse.jetty.webapp.WebAppContext.doStop(WebAppContext.java:45= 8) > =09at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLif= eCycle.java:80) > =09at org.eclipse.jetty.server.handler.HandlerCollection.doStop(HandlerCo= llection.java:247) > =09at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLif= eCycle.java:80) > =09at org.eclipse.jetty.server.handler.HandlerWrapper.doStop(HandlerWrapp= er.java:108) > =09at org.eclipse.jetty.server.Server.doStop(Server.java:319) > =09at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLif= eCycle.java:80) > =09at Main.main(Main.java:19) > =09at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > =09at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImp= l.java:39) > =09at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcc= essorImpl.java:25) > =09at java.lang.reflect.Method.invoke(Method.java:597) > {code} > To replicate, simply run the Main method in the attached project. Then sw= itch the CXF version in the pom.xml, and see it works with version 2.3.1. I= therefore thinks this is related to CXF-3213. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira