Hi Sergey,

yes, I am using the 1.1-SNAPSHOT version of DOSGi available here:
http://cxf.apache.org/dosgi-releases.html.

I tried again to get the greeter demo run with JAX-WS and I failed again.
The results are the same. The WSDL does not include any type or operation
specifications. It seems to me that the annotations of the interface and the
service implementation are not processed.

Could you please provide the code of the working demo fix if still
available? When not, could you please do another test and provide these
sources?

Thanks a lot.


Sergey Beryozkin-2 wrote:
> 
> Actually, I think I also updated the interface, just for the purpose of
> the test, I did something like
> 
>>    @WebMethod
>>    GreetingPhrase greetMe(String name);
> 
> and removed other two methods (so I had to update the impl bundle too)
> 
> and I probably added "javax.xml.bind.annotation.*" to the Import-Package
> directive...
> 
> can you please try to update the interface for JAXB be able to generate a
> schema ?
> 
> I'll also do a test again
> 
> Sergey
> 
>>
>> Hi
>>
>> I only added 'javax.jws.*', both to the interface and impl bundles.
>> By the way, are you using 1.1-SNAPSHOT ?
>>
>> I might have to repeat the test and send the zip
>>
>> cheers, Sergey
>>
>> -----Original Message-----
>> From: FrozenQ [mailto:zickenfr...@gmx.de]
>> Sent: 27 October 2009 13:19
>> To: users@cxf.apache.org
>> Subject: Re: Problem configuring CXF DOSGi to run with JAX-WS
>>
>>
>> Hi Sergey,
>>
>> thanks for your quick reply. Unfortunately, I d'ont succeed in getting
>> the
>> greeter demo run with JAXB and JAXWS. I tried the greeter example to come
>> along and so I have modified the greeter demo maven projects as follows:
>>
>> 1. I added the options "org.apache.cxf.ws.databinding" = "jaxb" and
>> "org.apache.cxf.ws.frontend" = "jaxws" to the service activator class and
>> the remote-services.xml of the client.
>> 2. I have annotated the interface
>> (org.apache.cxf.dosgi.samples.greeter.GreeterService) with the
>> corresponding
>> annotations "@Webservice" and "@WebMethod" for the interface and the
>> interface's methods, respectively. In addition, I have added the
>> following
>> import directives to the code "javax.jws.*"
>> and "javax.xml.bind.annotation.*". The interface now looks like:
>>
>> package org.apache.cxf.dosgi.samples.greeter;
>>
>> import java.util.Map;
>> import javax.jws.*;
>> import javax.xml.bind.annotation.*;
>>
>> @WebService
>> public interface GreeterService {
>>    @WebMethod
>>    Map<GreetingPhrase, String> greetMe(String name);
>>    @WebMethod
>>    GreetingPhrase [] greetMe(GreeterData name) throws GreeterException;
>> }
>>
>> Finally, I have added the following "import-package" directives to the
>> interface bundles build with maven:
>>
>> - javax.jws
>> - javax.jws.soap
>> - javax.xml.bind.annotation
>> - javax.xml.bind.annotation.adapters
>>
>> 3. I have repeated the same steps as mentioned in 2. for the service
>> implementation class. Furthermore, I have added the mentioned
>> "import-package" directives to the client bundle.
>>
>> Now, when launching the service, the published wsdl looks like:
>>
>> <wsdl:definitions name="GreeterServiceService"
>> targetNamespace="http://greeter.samples.dosgi.cxf.apache.org/";>
>> <wsdl:portType name="GreeterService">
>>  </wsdl:portType>
>> −
>> <wsdl:binding name="GreeterServiceServiceSoapBinding"
>> type="tns:GreeterService">
>> <soap:binding style="document"
>> transport="http://schemas.xmlsoap.org/soap/http"/>
>> </wsdl:binding>
>> −
>> <wsdl:service name="GreeterServiceService">
>> −
>> <wsdl:port binding="tns:GreeterServiceServiceSoapBinding"
>> name="GreeterServicePort">
>> <soap:address location="http://localhost:9090/greeter"/>
>> </wsdl:port>
>> </wsdl:service>
>> </wsdl:definitions>
>>
>> As you can see, there are no type definitions or operation specifications
>> included in the contract.
>>
>> Do you have an idea what I am doing wrong? Could you please give me an
>> advise?
>>
>> Many thanks in advance, again.
>>
>>
>> Sergey Beryozkin-2 wrote:
>>>
>>> Hi
>>>
>>> Few weeks ago, while looking at the issue reported against deploying the
>>> jaxrs services I also tested the deployment of jaxws
>>> services and I updated the reference guide a a result.
>>>
>>> I had no problems with updating a greeter demo to use JAXWS - note that
>>> you have to ensure JAXWS and/or JAXB annotations are
>>> available at runtime by adding the right Import-Package directives. In
>>> case of the demo, I updated the greeter-client component to
>>> use JAXWS annotations and updated the pom.xml to import the annotations,
>>> and then I did update the pom for the greeter_impl as
>>> well...
>>>
>>> here's the note from the reference page which you linked to :
>>>
>>> "Note that for JAXWS to work a javax.jws.* has to be imported into the
>>> interface and/or implementation and client bundles for
>>> annotations like @WebService and @WebMethod be recognized", there's a
>>> similar note for JAXB....
>>>
>>> cheers, Sergey
>>>
>>> ----- Original Message ----- 
>>> From: "FrozenQ" <zickenfr...@gmx.de>
>>> To: <users@cxf.apache.org>
>>> Sent: Friday, October 23, 2009 1:42 PM
>>> Subject: Problem configuring CXF DOSGi to run with JAX-WS
>>>
>>>
>>>>
>>>> Hi guys,
>>>>
>>>> I have a problem configuring a DOSGi/CXF service to use JAXB
>>>> databinding
>>>> and
>>>> JAX-WS frontend. I have set the following bundle registration
>>>> properties
>>>> in
>>>> the service activator as described on the DOSGi/CXF reference page
>>>> (http://cxf.apache.org/distributed-osgi-reference.html):
>>>>
>>>> 1) org.apache.cxf.ws.databinding : "jaxb"
>>>> 2) org.apache.cxf.ws.frontend : "jaxws"
>>>>
>>>> Unfortunately, the generated WSDL does not include any type defintions
>>>> or
>>>> operation specifications. The same problem is already described in this
>>>> thread:
>>>> http://www.nabble.com/DOSGI---problem-with-jax-ws-td24514255.html
>>>> ,
>>>> but there is no working solution provided. I also have added the
>>>> imports
>>>> (javax.jws.*, javax.xml.bind.annotation.*) to the bundles as suggested
>>>> on
>>>> the reference page mentioned above.
>>>>
>>>> Does anybody know how to solve this issue?
>>>>
>>>> Many thanks in advance.
>>>> -- 
>>>> View this message in context:
>>>> http://www.nabble.com/Problem-configuring-CXF-DOSGi-to-run-with-JAX-WS-tp26025706p26025706.html
>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>
>>>
>>>
>>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Problem-configuring-CXF-DOSGi-to-run-with-JAX-WS-tp26025706p26077584.html
>> Sent from the cxf-user mailing list archive at Nabble.com.
>>
>> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Problem-configuring-CXF-DOSGi-to-run-with-JAX-WS-tp26025706p26114845.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to