I am not importing the cxf bean definitions in my spring configuration.

Here is my cxf.xml file.


<beans xmlns="http://www.springframework.org/schema/beans";
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
     xmlns:simple="http://cxf.apache.org/simple";
     xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/simple
http://cxf.apache.org/schemas/simple.xsd";>

<simple:server id="Test" address="/hello"
   serviceBean="#helloService" serviceClass="
com.ironmountain.digital.erm.irmrap.cl.soap.util.Hello">
 </simple:server>

</beans>

The relevant portions of my web.xml is below.


<context-param>
       <param-name>contextConfigLocation</param-name>
       <param-value>
           classpath:configuration-sprcfg.xml,
           classpath:version-configuration-sprcfg.xml,
           classpath:jmx-sprcfg.xml,
           classpath:storage-common-sprcfg.xml,
           classpath:services-authorization-sprcfg.xml,
           classpath:services-sprcfg.xml,
           classpath:cl-http-security-sprcfg.xml,
           classpath:soap-sprcfg.xml
       </param-value>
   </context-param>

<servlet>
   <servlet-name>CXFServlet</servlet-name>
   <display-name>CXF Servlet</display-name>
   <servlet-class>
       org.apache.cxf.transport.servlet.CXFServlet
   </servlet-class>
   <load-on-startup>3</load-on-startup>
 </servlet>

 <servlet-mapping>
   <servlet-name>CXFServlet</servlet-name>
   <url-pattern>/cxfservices/*</url-pattern>
 </servlet-mapping>

   <listener>
       <listener-class>
           org.springframework.web.context.ContextLoaderListener
       </listener-class>
   </listener>


On 7/17/07, Dan Diephouse <[EMAIL PROTECTED]> wrote:

Can you show me what your web.xml and whole cxf.xml look like? How are you
importing the CXF bean definitions?

Thanks,
- Dan

On 7/16/07, Jacob Marcus <[EMAIL PROTECTED]> wrote:
>
> Thanks Dan. That worked.
>
> from the cxf.xml I would like to refer to a bean defined else where
like,
>
> <simple:server id="Test" address="
> http://localhost:8081/tes/cxfservices/HelloWorld";
>     serviceClass="com.test.HelloWorld">
>     <simple:serviceBean>#helloService</simple:serviceBean>
>   </simple:server>
>
> This is giving me an error saying the bean with id helloService cannot
be
> found. It appears that the SpringBusFactory does not have the bean
> definition. Is there a way I can instruct the server to use a specific
> bus?
>
> My spring application context is defined in the web.xml and I use the
> ContextLoaderListener.
> My problem is that the cxf.xml does not seem to be able to refer to
beans
> in
> my application context.
>
> Thanks in advance for your help,
> Jacob
>
> On 7/14/07, Dan Diephouse <[EMAIL PROTECTED]> wrote:
> >
> > Hi Jacob,
> >
> > I would go with something like:
> >
> >         <dependency>
> >                 <groupId>org.apache.cxf</groupId>
> >                 <artifactId>cxf-rt-frontend-jaxws</artifactId>
> >                 <version>2.0-incubator</version>
> >         </dependency>
> >         <dependency>
> >                 <groupId>org.apache.cxf</groupId>
> >                 <artifactId>cxf-rt-transports-http</artifactId>
> >                 <version>2.0-incubator</version>
> >         </dependency>
> >         <!-- Jetty is needed if you're are not using the CXFServlet
-->
> >         <dependency>
> >                 <groupId>org.apache.cxf</groupId>
> >                 <artifactId>cxf-rt-transports-http-jetty</artifactId>
> >                 <version>2.0-incubator</version>
> >         </dependency>
> >
> >
> > That will set you up to use the JAX-WS style annotated web services
with
> > JAXB. Spring is included by default.
> >
> > Let us know if you have more questions. I'll try to add this to the
> xfire
> > user's guide.
> >
> > - Dan
> >
> > On 7/13/07, Jacob Marcus <[EMAIL PROTECTED]> wrote:
> > >
> > > I am an XFire user planning to evaluate CXF for my project. What is
> the
> > > maven dependency for CXF to be used? While using XFire, I had the
> > > following
> > > dependencies.
> > >
> > > <dependency>
> > >             <groupId>org.codehaus.xfire</groupId>
> > >             <artifactId>xfire-jaxb2</artifactId>
> > >             <version>1.2.5</version>
> > >         </dependency>
> > >         <dependency>
> > >             <groupId>org.codehaus.xfire</groupId>
> > >             <artifactId>xfire-spring</artifactId>
> > >             <version>1.2.5</version>
> > >             <exclusions>
> > >                 <exclusion>
> > >                     <groupId>org.springframework</groupId>
> > >                     <artifactId>spring</artifactId>
> > >                 </exclusion>
> > >             </exclusions>
> > >         </dependency>
> > >         <dependency>
> > >             <groupId>org.codehaus.xfire</groupId>
> > >             <artifactId>xfire-java5</artifactId>
> > >             <version>1.2.5</version>
> > >         </dependency>
> > >
> > > Do we have something similar for CXF? I use spring.
> > >
> >
> >
> >
> > --
> > Dan Diephouse
> > Envoi Solutions
> > http://envoisolutions.com | http://netzooid.com/blog
> >
>



--
Dan Diephouse
Envoi Solutions
http://envoisolutions.com | http://netzooid.com/blog

Reply via email to