cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Kulev (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CXF-3725) JAXRS must be able to expose all spring components marked with @Path
Date Mon, 21 Oct 2013 11:08:42 GMT

    [ https://issues.apache.org/jira/browse/CXF-3725?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13800550#comment-13800550
] 

Vladimir Kulev edited comment on CXF-3725 at 10/21/13 11:07 AM:
----------------------------------------------------------------

Sergey, I don't think @Provider autodiscovery is a good idea, for example Jackson has JacksonJsonProvider
and JacksonJaxbJsonProvider, which are both marked as @Provider but should not be used together.
Also "scan-packages" name implies that CXF will do some class scanning, but in fact we want
it to search spring context (not classpath!) for beans annotated with @Path. These beans can
be defined both by Spring XML or @Component. Class with @Path annotation which is not a spring
bean will be useless. So "scan-packages" naming seems confusing to me.


was (Author: lightoze):
Sergey, I don't think @Provider autodiscovery is a good idea, for example Jackson has JacksonJsonProvider
and JacksonJaxbJsonProvider, which are both marked as @Provider but should not be used together.
Also "scan-packages" name implies that CXF will do some class scanning, but in fact we want
it to search spring context (not classpath!) for beans annotated with @Path. These beans can
be defined both by Spring XML or @Component. Class with @Path annotation which is not a spring
bean will be useless.

> JAXRS must be able to expose all spring components marked with @Path
> --------------------------------------------------------------------
>
>                 Key: CXF-3725
>                 URL: https://issues.apache.org/jira/browse/CXF-3725
>             Project: CXF
>          Issue Type: New Feature
>          Components: JAX-RS
>            Reporter: Olivier Lamy (*$^¨%`£)
>
> To ease dev and not to have to declare all beans.
> See sample :
> {code}
> not   
> <jaxrs:server id="bookservice" address="/">
>   <jaxrs:serviceBeans>
>     <ref bean="bookstore"/>
>     <ref bean="bookstoreInterface"/>
>   </jaxrs:serviceBeans>
> </jaxrs:server>
> but 
> <jaxrs:server id="bookservice" address="/">
>   <jaxrs:serviceBeans all-beans="true">
>     
>   </jaxrs:serviceBeans>
> </jaxrs:server>
> All spring components marked with @Path as it will be exposed
> @Path( "/userService/" )
> @Service("userService#rest")
> public class DefaultUserService
>     implements UserService
> {code}



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message