You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by Sergey Beryozkin <sb...@gmail.com> on 2012/11/23 10:59:46 UTC

Re: svn commit: r1412802

Hi Christian

What is the auto-detection and is there any reason JAX-RS endpoints can 
not benefit of this possible enhancement ?

Thanks, Sergey

On 23/11/12 09:50, cschneider@apache.org wrote:
> Author: cschneider
> Date: Fri Nov 23 09:50:25 2012
> New Revision: 1412802
>
> URL: http://svn.apache.org/viewvc?rev=1412802&view=rev
> Log:
> DOSGI-128 Small refactoring in preparation of the auto detection of jaxws and jaxb services
>

Re: svn commit: r1412802

Posted by Sergey Beryozkin <sb...@gmail.com>.
Hi,

I'll probably stay away for a moment from getting JAX-RS endpoints 
auto-detected given that the default context path will not be really 
user friendly in such cases (ex, 'my_company_Books', etc) though this 
can work ok in a end-to-end WS case...

However supporting JAX-RS Application OSGI services will make sense, 
something I can work upon in time...

The question is, are we prepared to get DSW depending on JAX-WS & JAX-RS 
API ? I don't see any major issues at the moment, it probably will do OK

Thanks, Sergey

On 23/11/12 12:24, Christian Schneider wrote:
> In the DOSGI-128 issue I do not plan to support a default address.
>
> There is anothe issue for it though:
> https://issues.apache.org/jira/browse/DOSGI-127
>
> I planned to use the servlet transport by default and somehow create the
> default address from the Service interface. Not sure how to support more
> than one instance of a service endpoint for the same interface though.
> Still we could simply start with that.
>
> Christian
>
> Am 23.11.2012 11:52, schrieb Sergey Beryozkin:
>> Hi
>> On 23/11/12 10:15, Christian Schneider wrote:
>>> Hi Sergey,
>>>
>>> the idea is to auto detect if a service is a JAXWS service by detecting
>>> the @WebService annotation.
>>> So if this annotation is found then the service would default to
>>> JAXWS/JAXB instead of Simple/Aegis if no intent overrides this.
>>>
>>> The corresponding issue is:
>>> https://issues.apache.org/jira/browse/DOSGI-128
>>>
>>
>> OK, see what you mean, thanks
>>
>>> This may also be possible for JAXRS. Can you open an issue and document
>>> how a jaxrs service should be detected and what the settings then
>>> should be?
>>>
>> In case of JAX-RS, it has to be '@javax.ws.rs.Path' annotation that
>> can identify a service bean as a JAX-RS root resource
>> class...Alternatively the service bean itself can be
>> 'javax.ws.rs.core.Application'. I guess
>>
>> I can definitely get the code enhanced to manage 'Application' OSGI
>> services, however, what about the auto-detection and the actual
>> endpoint address ?
>>
>> Will the endpoint be bound to HTTP Service or will it be an absolute
>> (default) URI and thus Jetty will do an internal HTTP support ?
>>
>> Thanks, Sergey
>>
>>
>


-- 
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com

Re: svn commit: r1412802

Posted by Christian Schneider <ch...@die-schneider.net>.
In the DOSGI-128 issue I do not plan to support a default address.

There is anothe issue for it though:
https://issues.apache.org/jira/browse/DOSGI-127

I planned to use the servlet transport by default and somehow create the 
default address from the Service interface. Not sure how to support more 
than one instance of a service endpoint for the same interface though.
Still we could simply start with that.

Christian

Am 23.11.2012 11:52, schrieb Sergey Beryozkin:
> Hi
> On 23/11/12 10:15, Christian Schneider wrote:
>> Hi Sergey,
>>
>> the idea is to auto detect if a service is a JAXWS service by detecting
>> the @WebService annotation.
>> So if this annotation is found then the service would default to
>> JAXWS/JAXB instead of Simple/Aegis if no intent overrides this.
>>
>> The corresponding issue is:
>> https://issues.apache.org/jira/browse/DOSGI-128
>>
>
> OK, see what you mean, thanks
>
>> This may also be possible for JAXRS. Can you open an issue and document
>> how a jaxrs service should be detected and what the settings then 
>> should be?
>>
> In case of JAX-RS, it has to be '@javax.ws.rs.Path' annotation that 
> can identify a service bean as a JAX-RS root resource 
> class...Alternatively the service bean itself can be 
> 'javax.ws.rs.core.Application'. I guess
>
> I can definitely get the code enhanced to manage 'Application' OSGI 
> services, however, what about the auto-detection and the actual 
> endpoint address ?
>
> Will the endpoint be bound to HTTP Service or will it be an absolute 
> (default) URI and thus Jetty will do an internal HTTP support ?
>
> Thanks, Sergey
>
>

-- 
  
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
Talend Application Integration Division http://www.talend.com


Re: svn commit: r1412802

Posted by Sergey Beryozkin <sb...@gmail.com>.
Hi
On 23/11/12 10:15, Christian Schneider wrote:
> Hi Sergey,
>
> the idea is to auto detect if a service is a JAXWS service by detecting
> the @WebService annotation.
> So if this annotation is found then the service would default to
> JAXWS/JAXB instead of Simple/Aegis if no intent overrides this.
>
> The corresponding issue is:
> https://issues.apache.org/jira/browse/DOSGI-128
>

OK, see what you mean, thanks

> This may also be possible for JAXRS. Can you open an issue and document
> how a jaxrs service should be detected and what the settings then should be?
>
In case of JAX-RS, it has to be '@javax.ws.rs.Path' annotation that can 
identify a service bean as a JAX-RS root resource class...Alternatively 
the service bean itself can be 'javax.ws.rs.core.Application'. I guess

I can definitely get the code enhanced to manage 'Application' OSGI 
services, however, what about the auto-detection and the actual endpoint 
address ?

Will the endpoint be bound to HTTP Service or will it be an absolute 
(default) URI and thus Jetty will do an internal HTTP support ?

Thanks, Sergey



> Christian
>
> On 11/23/2012 10:59 AM, Sergey Beryozkin wrote:
>> Hi Christian
>>
>> What is the auto-detection and is there any reason JAX-RS endpoints
>> can not benefit of this possible enhancement ?
>>
>> Thanks, Sergey
>>
>> On 23/11/12 09:50, cschneider@apache.org wrote:
>>> Author: cschneider
>>> Date: Fri Nov 23 09:50:25 2012
>>> New Revision: 1412802
>>>
>>> URL: http://svn.apache.org/viewvc?rev=1412802&view=rev
>>> Log:
>>> DOSGI-128 Small refactoring in preparation of the auto detection of
>>> jaxws and jaxb services
>>>
>



Re: svn commit: r1412802

Posted by Christian Schneider <ch...@die-schneider.net>.
Hi Sergey,

the idea is to auto detect if a service is a JAXWS service by detecting
the @WebService annotation.
So if this annotation is found then the service would default to
JAXWS/JAXB instead of Simple/Aegis if no intent overrides this.

The corresponding issue is:
https://issues.apache.org/jira/browse/DOSGI-128

This may also be possible for JAXRS. Can you open an issue and document
how a jaxrs service should be detected and what the settings then should be?

Christian

On 11/23/2012 10:59 AM, Sergey Beryozkin wrote:
> Hi Christian
>
> What is the auto-detection and is there any reason JAX-RS endpoints
> can not benefit of this possible enhancement ?
>
> Thanks, Sergey
>
> On 23/11/12 09:50, cschneider@apache.org wrote:
>> Author: cschneider
>> Date: Fri Nov 23 09:50:25 2012
>> New Revision: 1412802
>>
>> URL: http://svn.apache.org/viewvc?rev=1412802&view=rev
>> Log:
>> DOSGI-128 Small refactoring in preparation of the auto detection of
>> jaxws and jaxb services
>>