Re: Re: Re: Re: Re: Re: JAX-RS support for JOnAS ?

Frederic Dang Tran <[email protected]>
Newsgroups gmane.comp.java.objectweb.jonas
Message-ID <[email protected]>
I tried the trick and it works fine (I also had to add the Jettison bundle required by CXF for JSON handling).
Thanks
F.


On Jan 5, 2011, at 11:53 AM, Guillaume Sauthier wrote:

> Hi Frederic
> 
> In fact, it's an ordering issue.
> CXF bundles are installed and resolved before the jax-rs bundle is made available, so the OSGi framework consider the jax-rs dependency as unavailable (leading to CNFE).
> What you can do is tweaking a little the jaxws-cxf.xml deployment plan (look somewhere in the repositories/internal/ directory) and add the reference (using the maven coordinates) to the jax-rs bundle *before* the cxf-bundle.
> 
> That should do the trick
> 
> Thanks
> --Guillaume
> 
> Le 05/01/2011 11:02, Frederic Dang Tran a écrit :
>> 
>> 
>> On Jan 4, 2011, at 10:16 PM, S. Ali Tokmen wrote:
>> 
>>> Hello
>>> 
>>> Happy new year, Frédéric.
>>> 
>>> How did you add the JAX-RS bundle? There is ow2-bundles-externals-jaxrs-1.0 that works well with JOnAS - CAMEL.
>> 
>> I just copied the jar file in  $JONAS_BASE/deploy.
>> Instead should I update or add a deployment plan in JONAS_ROOT to make sur that the JAX-RS bundle is deployed before  cxf-bundle ?
>> 
>>> 
>>> @François: do you have any answers for the JOnAS roadmap part?
>>> 
>>> Cheers
>>> 
>>> S. Ali Tokmen
>>> http://ali.tokmen.com/
>>> 
>>> GSM (fr): +33 66 43 00 555 [Orange]
>>> GSM (tr): +90 555 266 52 73 [Avea]
>>> 
>>> My AIM, ICQ, MSN Messenger and Yahoo IM
>>> contact details are on http://contact.ali.tokmen.com
>>> 
>>> On 04.01.2011 18:56, Frederic Dang Tran wrote:
>>>> 
>>>> Hello Ali and Happy New Year :-)
>>>> 
>>>> I now switched to JOnAS 5.2.0 M3 and you are right: it comes with CXF 2.2.11 (cxf-bundle).
>>>> However not all dependencies required to run a RESTfull web service are included.
>>>> I am currently stuck with this exception:
>>>> 
>>>> Caused by: java.lang.ClassNotFoundException: javax.ws.rs.ext.MessageBodyReader not found by org.apache.cxf.bundle [121]
>>>>  at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:780)
>>>> 
>>>> The javax.ws.rs package is exported by the jsr311-api  bundle. I tried to add  this bundle (within the war or in $JONAS_BASE/deploy) but to no avail.
>>>> This is not blocking for me since I can revert to my previous setup which was to bundle everything in the WAR.
>>>> Actually I just came across the JOnAS roadmap which claims that JOnAS 5.2 will feature support for JAX-RS.
>>>> Does it mean that my issue will be moot very soon ?
>>>> 
>>>> Regards,
>>>> Frederic
>> 
>> 
>> *******************************************
>> Frederic Dang Tran
>> 
>> France Telecom R&D MAPS/MEP
>> 38-40 rue du General Leclerc
>> 92794 Issy Moulineaux Cedex 9
>> FRANCE
>> 
>> Tel: (+33) 1 45 29 60 88
>> Fax: (+33) 1 45 29 69 13
>> *******************************************
>> 
>> 
>> 
>> 
> <Guillaume_Sauthier.vcf>


*******************************************
Frederic Dang Tran

France Telecom R&D MAPS/MEP
38-40 rue du General Leclerc
92794 Issy Moulineaux Cedex 9
FRANCE

Tel: (+33) 1 45 29 60 88
Fax: (+33) 1 45 29 69 13
*******************************************
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.