btw.. just personal taste I guess but I think the URI would have looked nicer if instead of: cxf://CxfEndpointBean=routerPoint it was something like: cxf:bean://routerPoint
On 9/28/07, Willem Jiang <[EMAIL PROTECTED]> wrote: > Hi Guillaume, > > Oh, I got your means. > > I don't want to instantiate the Service from Spring , I just want to > pass enough endpoint information to build the CXF Service. I check the > server object code, and I know I can't set the invoker of a already > created server . > So I changed my proposal to use a customized CxfEndpointBean instead > of the already instantiate server object or client object. > Here is the changed example: > > <cxf:CxfEndpointBean id= "routerPoint" > serviceClass="org.apache.cxf.service.factory.HelloService" > address="http://localhost:8000/router" > serviceName="s:XMLService" > xmlns:s="http://apache.org/hello_world_soap_http" > endpointName="s:XMLPort" /> > > <cxf:CxfEndpointBean id= "externalPoint" > serviceClass="org.apache.cxf.service.factory.HelloService" > address="http://localhost:8000/RealService" > wsdlURL = "wsdl/hello_world" > serviceName="s:XMLService" > xmlns:s="http://apache.org/hello_world_soap_http" > endpointName="s:XMLPort" /> > > <camelContext id="camel" > xmlns="http://activemq.apache.org/camel/schema/spring"> > <route> > <from uri="cxf://CxfEndpointBean=routerPoint"/> > <to uri="cxf://CxfEndpointBean=externalPoint"/> > </route> > </camelContext> > > I will add the ServerFactoryBean and ClientFactoryBean configuration with > CxfEndpointBean code into the cxf component. So we still instantiate the > server or the client as we always do in the CXF component . > > Thanks, > > Willem. > > Guillaume Nodet wrote: > > I'm still very concerned about the fact that we have to instanciate > > the service on the server side if it is not actually used (requests > > are just forwarded). Can we configure the server to just use a WSDL > > instead ? > > > > On 9/28/07, Willem Jiang <[EMAIL PROTECTED]> wrote: > > > >> Guillaume Nodet wrote: > >> > >>> On 9/28/07, Willem Jiang <[EMAIL PROTECTED]> wrote: > >>> > >>> > >>>> Here is an example: > >>>> ... > >>>> <simple:client id="client1" > >>>> serviceClass="org.apache.cxf.service.factory.HelloService" > >>>> address="http://localhost:9000/foo2" > >>>> serviceName="s:XMLService" > >>>> xmlns:s="http://apache.org/hello_world_soap_http" > >>>> endpointName="s:XMLPort" > >>>> bindingId="http://cxf.apache.org/bindings/xformat"> > >>>> </simple:client> > >>>> > >>>> <simple:server id="server1" > >>>> address="http://localhost:8080/simpleWithAddress"> > >>>> <simple:serviceBean> > >>>> <bean class="org.apache.cxf.service.factory.HelloServiceImpl"/> > >>>> </simple:serviceBean> > >>>> </simple:server> > >>>> > >>>> <camelContext id="camel" > >>>> xmlns="http://activemq.apache.org/camel/schema/spring"> > >>>> <route> > >>>> <from uri="cxf://SpringBean=server1"/> > >>>> <to uri="cxf://SpringBean=client1"/> > >>>> </route> > >>>> </camelContext> > >>>> > >>>> > >>>> > >>> Can you explain a bit what this route is supposed to do ? > >>> Is this supposed to accept requests on > >>> http://localhost:8080/simpleWithAddress > >>> and route them to an external service on > >>> http://localhost:9000/foo2 > >>> > >>> > >>> > >>> > >> Yes , it is exactly working as your said. > >> I just omitted the address information from the endpoint URI , because > >> they are already in the Spring bean's configuration. > >> > >> Willem. > >> > >> > >> > >> > > > > > > > > -- Regards, Hiram Blog: http://hiramchirino.com
