Uploaded image for project: 'XBean'
  1. XBean
  2. XBEAN-38

XFire initialisation problem with spring 2.0-rc2

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 2.5
    • Component/s: spring
    • Labels:
      None
    • Environment:

      Description

      I have attempted to configure a simple jsr181 web service using XFire and am getting the following stack trace when the web service is accessed.

      I'm assuming the only unusual aspect of my setup is using spring version 2.0-rc2.

      <!DOCTYPE web-app
      PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
      "http://java.sun.com/dtd/web-app_2_3.dtd">

      <web-app>
      <servlet>
      <servlet-name>XFire</servlet-name>
      <display-name>XFire Servlet</display-name>
      <servlet-class>
      org.codehaus.xfire.transport.http.XFireConfigurableServlet
      </servlet-class>

      <!--
      The servlet will by default look for the configuration on
      the classpath in "META-INF/xfire/services.xml". You can
      override it with this parameter. Seperate multiple configuration files with a comma.
      -->
      <init-param>
      <param-name>config</param-name>
      <param-value>services.xml</param-value>
      </init-param>
      </servlet>

      <servlet-mapping>
      <servlet-name>XFire</servlet-name>
      <url-pattern>/servlet/XFireServlet/*</url-pattern>
      </servlet-mapping>

      <servlet-mapping>
      <servlet-name>XFire</servlet-name>
      <url-pattern>/services/*</url-pattern>
      </servlet-mapping>
      </web-app>

      <beans xmlns="http://xfire.codehaus.org/config/1.0">
      <service>
      <serviceClass>com.effacy.alm.remote.user.RemoteUserFacade</serviceClass>
      <serviceFactory>jsr181</serviceFactory>
      </service>
      </beans>

      [ INFO: XmlBeanDefinitionReader.java: 330] - Loading XML bean definitions from class path resource [org/codehaus/xfire/spring/xfire.xml]
      [ERROR: XFireServlet.java: 51] - Error initializing XFireServlet.
      org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from class path resource [org/codehaus/xfire/spring/xfire.xml]; nested exception is java.lang.IllegalArgumentException: ClassLoader must not be null
      Caused by:
      java.lang.IllegalArgumentException: ClassLoader must not be null
      at org.springframework.util.Assert.notNull(Assert.java:113)
      at org.springframework.beans.factory.xml.DefaultNamespaceHandlerResolver.<init>(DefaultNamespaceHandlerResolver.java:82)
      at org.springframework.beans.factory.xml.DefaultNamespaceHandlerResolver.<init>(DefaultNamespaceHandlerResolver.java:74)
      at org.apache.xbean.spring.context.v2.XBeanNamespaceHandlerResolver.<init>(XBeanNamespaceHandlerResolver.java:26)
      at org.apache.xbean.spring.context.v2.XBeanXmlBeanDefinitionReader.createDefaultNamespaceHandlerResolver(XBeanXmlBeanDefinitionReader.java:81)
      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.createReaderContext(XmlBeanDefinitionReader.java:496)
      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:476)
      at org.apache.xbean.spring.context.v2.XBeanXmlBeanDefinitionReader.registerBeanDefinitions(XBeanXmlBeanDefinitionReader.java:77)
      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:386)
      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:340)
      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:315)
      at org.codehaus.xfire.spring.XFireConfigLoader.getXFireApplicationContext(XFireConfigLoader.java:75)
      at org.codehaus.xfire.spring.XFireConfigLoader.loadContext(XFireConfigLoader.java:39)
      at org.codehaus.xfire.transport.http.XFireConfigurableServlet.loadConfig(XFireConfigurableServlet.java:75)
      at org.codehaus.xfire.transport.http.XFireConfigurableServlet.createXFire(XFireConfigurableServlet.java:51)
      at org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:45)
      at javax.servlet.GenericServlet.init(GenericServlet.java:211)
      at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1068)
      at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:725)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:131)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
      at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
      at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
      at java.lang.Thread.run(Unknown Source)
      [ERROR: StandardWrapperValve.java: 146] - Allocate exception for servlet XFire
      javax.servlet.ServletException: Error initializing XFireServlet.
      at org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:52)
      at javax.servlet.GenericServlet.init(GenericServlet.java:211)
      at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1068)
      at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:725)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:131)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
      at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
      at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
      at java.lang.Thread.run(Unknown Source)

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              sbaker3 Steve Baker
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: