[ 
https://issues.apache.org/jira/browse/CAMEL-15348?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Claus Ibsen updated CAMEL-15348:
--------------------------------
    Fix Version/s: 3.4.3
                   3.5.0

> cxfEndpoint blueprint namespace handler - problem with QName vs String
> ----------------------------------------------------------------------
>
>                 Key: CAMEL-15348
>                 URL: https://issues.apache.org/jira/browse/CAMEL-15348
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf, karaf, osgi
>    Affects Versions: 3.4.1
>         Environment: Karaf 4.2.9
> Camel 3.4.1
> CXF 3.3.6
>            Reporter: Rastislav Papp
>            Priority: Major
>             Fix For: 3.5.0, 3.4.3
>
>         Attachments: camel-reproducer-blueprint-cxf.zip
>
>
> When trying to create a {{cxfEndpoint}} in blueprint xml, using cxfEndpoint 
> element from namespace {{http://camel.apache.org/schema/blueprint/cxf}} there 
> is a problem with {{endpointName}} and {{serviceName}} parameters. This:
> {code:xml}
> <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0";
>            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>            xmlns:cxf="http://camel.apache.org/schema/blueprint/cxf";>
>     <cxf:cxfEndpoint id="fooEndpoint"
>                      address="${endpoint.url}"
>                      serviceClass="com.foo.MyService"
>                      endpointName="foo:MyService"
>                      continuationTimeout="0"
>                      xmlns:foo="http://abc.def";>
>         ...
>     </cxf:cxfEndpoint>
> </blueprint>
> {code}
> throws an exception:
> {code}
> Caused by: org.osgi.service.blueprint.container.ComponentDefinitionException: 
> Error setting property: PropertyDescriptor <name: endpointName, getter: null, 
> setter: [class 
> org.apache.camel.component.cxf.CxfEndpoint.setEndpointName(class 
> java.lang.String)]
>       at 
> org.apache.aries.blueprint.container.BeanRecipe.setProperty(BeanRecipe.java:818)
>  ~[?:?]
> ...
> Caused by: java.lang.Exception: Unable to convert value 
> {http://abc.def}MyService to type java.lang.String
>       at 
> org.apache.aries.blueprint.container.AggregateConverter.convert(AggregateConverter.java:187)
>  ~[?:?]
> {code}
> I suspect the problem is with a 
> {{org.apache.camel.component.cxf.CxfEndpoint#setEndpointName}} and 
> {{org.apache.camel.component.cxf.CxfEndpoint#setServiceName}} methods - which 
> previously accepted {{QName}}, but now accept {{String}}, and this change was 
> not reflected in 
> {{org.apache.camel.component.cxf.blueprint.EndpointDefinitionParser}}
> I'm attaching a project to reproduce the behavior -  
> [^camel-reproducer-blueprint-cxf.zip] 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to