Hi, Can you please add a cxf namespace definition to your beans section and specify what cxf stands for...?
You will need to put beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:cxf="http://activemq.apache.org/camel/schema/cxfEndpoint" xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd http://activemq.apache.org/camel/schema/cxfEndpoint http://activemq.apache.org/camel/schema/cxfEndpoint/camel-cxf.xsd http://activemq.apache.org/camel/schema/spring http://activemq.apache.org/camel/schema/spring/camel-spring.xsd "> Hope this helps. Cheers, Ashwin... cmoulliard wrote: > > Hi, > > I test this option but I have an error in Spring DM server : > > [2008-12-08 12:23:54.150] async-delivery-thread-1 > catalina].[localhost].[/reportincident.web-1.0-SNAPSHOT].unknown E > Exception sending context initialized event to listener instance of class > org.springframework.web.context.ContextLoaderListener > org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: > Line 34 in XML document from class path resource [camel-context.xml] is > invalid; nested exception is org.xml.sax.SAXParseException: The prefix > "cxf" for element "cxf:cxfEndpoint" is not bound. > > Here is my camel-config file : > > <?xml version="1.0" encoding="UTF-8"?> > <beans xmlns="http://www.springframework.org/schema/beans" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:osgi="http://www.springframework.org/schema/osgi" > xsi:schemaLocation=" > http://www.springframework.org/schema/beans > http://www.springframework.org/schema/beans/spring-beans-2.5.xsd > http://activemq.apache.org/camel/schema/spring > http://activemq.apache.org/camel/schema/spring/camel-spring.xsd > http://cxf.apache.org/jaxws > http://cxf.apache.org/schemas/jaxws.xsd > http://www.springframework.org/schema/osgi > http://www.springframework.org/schema/osgi/spring-osgi-1.1.xsd > http://activemq.apache.org/camel/schema/cxfEndpoint > http://activemq.apache.org/camel/schema/cxf/cxfEndpoint.xsd"> > > <import resource="classpath:META-INF/cxf/cxf.xml"/> > <import resource="classpath:META-INF/cxf/cxf-extension-soap.xml"/> > <import resource="classpath:META-INF/cxf/cxf-servlet.xml"/> > > <!-- implementation of the webservice --> > <osgi:reference id="reportIncidentEndpoint" > interface="org.apache.camel.example.reportincident.ReportIncidentService"/> > > > <cxf:cxfEndpoint id="reportIncident" address="/incident" > wsdlURL="/WEB-INF/wsdl/report_incident.xml" > serviceClass="#reportIncidentEndpoint" > endpointName="s:ReportIncidentPort" > serviceName="s:ReportIncidentService" > > xmlns:s="http://reportincident.example.camel.apache.org" > /> > > <camelContext id="camel" > xmlns="http://activemq.apache.org/camel/schema/spring"> > <package>org.apache.camel.example.reportincident</package> > <jmxAgent id="agent" createConnector="true"/> > </camelContext> > > </beans> > > Claus Ibsen-2 wrote: >> >> Hi >> >> Can you use the # notation for the serivceClass? >> serviceClass="#myServiceToBeLookedUpInRegistry" >> >> >> >> /Claus Ibsen >> Apache Camel Committer >> Blog: http://davsclaus.blogspot.com/ >> >> >> >> On Mon, Dec 8, 2008 at 12:01 PM, cmoulliard <[EMAIL PROTECTED]> wrote: >>> >>> Hi, >>> >>> Is there a way to inject from an OSGI reference the service to be used >>> to >>> process the webservice in cxf:cxfendpoint of Camel ? >>> >>> ex : >>> >>> Using the following syntax, it is possible to inject the OSGI bundle >>> service >>> to the jaws:endpoint of cxf >>> >>> <osgi:reference id="reportIncidentEndpoint" >>> interface="org.apache.camel.example.reportincident.ReportIncidentService"/> >>> >>> <!-- export the webservice using jaxws --> >>> <jaxws:endpoint id="reportIncident" >>> implementor="#reportIncidentEndpoint" >>> address="/incident" >>> wsdlLocation="/WEB-INF/wsdl/report_incident.xml" >>> endpointName="s:ReportIncidentPort" >>> serviceName="s:ReportIncidentService" >>> xmlns:s="http://reportincident.example.camel.apache.org"/> >>> >>> but with cxf:cxfendpoint, I don't think so ? >>> >>> <cxf:cxfEndpoint id="reportIncident" address="/incident" >>> wsdlURL="/WEB-INF/wsdl/report_incident.xml" >>> >>> serviceClass="org.apache.camel.example.reportincident.ReportIncidentImpl" >>> endpointName="s:ReportIncidentPort" >>> serviceName="s:ReportIncidentService" >>> >>> xmlns:s="http://reportincident.example.camel.apache.org" >>> /> >>> >>> With cxf:cxfendpoint, the serviceClass is hardcoded and it is not >>> possible >>> to provide a bean reference. >>> >>> KR, >>> >>> Charles Moulliard >>> >>> >>> >>> ----- >>> Enterprise Architect >>> >>> Xpectis >>> 12, route d'Esch >>> L-1470 Luxembourg >>> >>> Phone +352 25 10 70 470 >>> Mobile +352 621 45 36 22 >>> >>> e-mail : [EMAIL PROTECTED] >>> web site : www.xpectis.com www.xpectis.com >>> My Blog : http://cmoulliard.blogspot.com/ >>> http://cmoulliard.blogspot.com/ >>> -- >>> View this message in context: >>> http://www.nabble.com/Cxf%3Acxfendpoint---OSGI-reference-tp20893288s22882p20893288.html >>> Sent from the Camel - Users mailing list archive at Nabble.com. >>> >>> >> >> > > ----- --- Ashwin Karpe, Principal Consultant, PS - Opensource Center of Competence Progress Software Corporation 14 Oak Park Drive Bedford, MA 01730 --- +1-972-304-9084 (Office) +1-972-971-1700 (Mobile) ---- Blog: http://opensourceknowledge.blogspot.com/ -- View this message in context: http://www.nabble.com/Cxf%3Acxfendpoint---OSGI-reference-tp20893288s22882p20894444.html Sent from the Camel - Users mailing list archive at Nabble.com.
