{"action":"created","issue":{"url":"https://api.github.com/repos/oasp/oasp4j/issues/267","labels_url":"https://api.github.com/repos/oasp/oasp4j/issues/267/labels{/name}","comments_url":"https://api.github.com/repos/oasp/oasp4j/issues/267/comments","events_url":"https://api.github.com/repos/oasp/oasp4j/issues/267/events","html_url":"https://github.com/oasp/oasp4j/issues/267","id":89954967,"number":267,"title":"JAX-RS: Auto-discovery of root resources and providers","user":{"login":"amarinso","id":9352103,"avatar_url":"https://avatars.githubusercontent.com/u/9352103?v=3","gravatar_id":"","url":"https://api.github.com/users/amarinso","html_url":"https://github.com/amarinso","followers_url":"https://api.github.com/users/amarinso/followers","following_url":"https://api.github.com/users/amarinso/following{/other_user}","gists_url":"https://api.github.com/users/amarinso/gists{/gist_id}","starred_url":"https://api.github.com/users/amarinso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amarinso/subscriptions","organizations_url":"https://api.github.com/users/amarinso/orgs","repos_url":"https://api.github.com/users/amarinso/repos","events_url":"https://api.github.com/users/amarinso/events{/privacy}","received_events_url":"https://api.github.com/users/amarinso/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-06-21T20:14:51Z","updated_at":"2015-06-22T12:09:29Z","closed_at":null,"body":"From the CXF documentation:\r\n> Starting from CXF 3.0.0 it is possible to enable the auto-discovery of JAX-RS roots and providers with the regular CXF JAX-RS endpoint declarations done in XML \r\n\r\n> If you prefer doing a pure Spring-based auto-discovery you can have @Component added to JAX-RS application classes and do\r\n\r\n```\r\n<beans xmlns=\"http://www.springframework.org/schema/beans\"\r\n      xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\r\n      xmlns:jaxrs=\"http://cxf.apache.org/jaxrs\"\r\n      xsi:schemaLocation=\"\r\n         http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd\r\n         http://cxf.apache.org/jaxrs http://cxf.apache.org/schemas/jaxrs.xsd\">\r\n \r\n     <import resource=\"classpath:META-INF/cxf/cxf.xml\" />\r\n      \r\n     <!-- \r\n         Discover all root resources and providers in packages starting from \"a.b.c\" \r\n     -->\r\n     <jaxrs:server address=\"/customers\"/>\r\n     <context:component-scan base-package=\"a.b.c\"/>\r\n \r\n </beans>\r\n```\r\n\r\nI've tried and seems to work ok, I think is a good addition as it simplifies the configuration for the programmer and allows for an easier integration of OASP \"plugins\". Think of a module that provides its own JAX-RS endpoints (for example a module for monitoring) without having to add them manually to the `<jaxrs:server>` bean"},"comment":{"url":"https://api.github.com/repos/oasp/oasp4j/issues/comments/114080982","html_url":"https://github.com/oasp/oasp4j/issues/267#issuecomment-114080982","issue_url":"https://api.github.com/repos/oasp/oasp4j/issues/267","id":114080982,"user":{"login":"lgoerlach","id":12272186,"avatar_url":"https://avatars.githubusercontent.com/u/12272186?v=3","gravatar_id":"","url":"https://api.github.com/users/lgoerlach","html_url":"https://github.com/lgoerlach","followers_url":"https://api.github.com/users/lgoerlach/followers","following_url":"https://api.github.com/users/lgoerlach/following{/other_user}","gists_url":"https://api.github.com/users/lgoerlach/gists{/gist_id}","starred_url":"https://api.github.com/users/lgoerlach/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lgoerlach/subscriptions","organizations_url":"https://api.github.com/users/lgoerlach/orgs","repos_url":"https://api.github.com/users/lgoerlach/repos","events_url":"https://api.github.com/users/lgoerlach/events{/privacy}","received_events_url":"https://api.github.com/users/lgoerlach/received_events","type":"User","site_admin":false},"created_at":"2015-06-22T12:09:29Z","updated_at":"2015-06-22T12:09:29Z","body":"> also CobiGen should be updated to avoid the insertion on beans-services.xml. I think @dsanche2 can take that if he modifies also CobiGen for the simplification of the component facade.\r\n\r\nI have just done that. The latest templates can be pushed to the repository soon (as Malte has started working on the issue preventing me from doing that).\r\n@dsanche2: If you need them right away for working on the component facade, let me know."}}