Newbie-question. No bean named 'cfx' is defined.

Newbie-question. No bean named 'cfx' is defined.

During startup of my application which is just a simple jax-ws service I get the message

org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'cxf' is defined

So the obvious question was first if there was a context file within my classpath with a bean named 'cfx'?

My lib directory differs a little from the samples. I build my sample with maven and used the
suggested pom file (building your cfx project with maven) to define my dependencies.
This means my WEB-INF/lib folder contains a whole set of cfx-libs.

But all this aside, sure, there is such a bean defined in the cfx-rt-core-2.0.2-incubator jar
under META-INF/cfx/cfx.xml.

> Hello,
>
> During startup of my application which is just a simple jax-ws service I get
> the message
>
> org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean
> named 'cxf' is defined
>
> So the obvious question was first if there was a context file within my
> classpath with a bean named 'cfx'?
>
> My lib directory differs a little from the samples. I build my sample with
> maven and used the
> suggested pom file (building your cfx project with maven) to define my
> dependencies.
> This means my WEB-INF/lib folder contains a whole set of cfx-libs.
>
> But all this aside, sure, there is such a bean defined in the
> cfx-rt-core-2.0.2-incubator jar
> under META-INF/cfx/cfx.xml.
>
> What am I missing here?
>
>
>

Re: Newbie-question. No bean named 'cfx' is defined.

Yea, I see that I missed those import statements now.
The reason why I have been having problems with this is probably that I am trying to
mix the setup shown in the sample java_first_jaxws with an existing spring setup.
The java_first_jaxws sample does not contain any spring context files and just defines
the CXF servlet and the annotated service is picked up and exposed automatically
just as the JAX-WS specification specifies.

Should I take it then that this is not possible if I am already using spring
in a web-app?

>
> Yea, I see that I missed those import statements now.
> The reason why I have been having problems with this is probably that I am
> trying to
> mix the setup shown in the sample java_first_jaxws with an existing spring
> setup.
> The java_first_jaxws sample does not contain any spring context files and
> just defines
> the CXF servlet and the annotated service is picked up and exposed
> automatically
> just as the JAX-WS specification specifies.
>
> Should I take it then that this is not possible if I am already using spring
> in a web-app?
>
> Thanks for the quick answers btw
>
>