Hi,

I have an existing REST JAX-RS Application based on CXF mechanics. that is the 
Resources are lifecycle managed by a programmatically setup 
JAXRSServerFactoryBean, which itself gets started and stopped by an immediate 
@Component

Now I want to build new entrypoints (and eventually migrate old ones) using the 
JAX-RS whiteboard, as discussed e.g. here 
http://karaf.922171.n3.nabble.com/Aries-JAX-RS-Whiteboard-td4054440.html, and 
go full dynamically discovered declarative services with my REST API and 
application. 

The basic setup (without extensions) works very well,  now I want to replace 
all my programmatic CXF configuration with @Components annotated with 
@JaxrsExtension, use only JAX-RS/Whiteboard mechanics and no more CXF 
specialties if possible.

Now for the questions: 

1. Some of the providers I configure programmatically implement JAX-RS 
interfaces and are provided by CXF or other frameworks, e.g. 
CrossOriginResourceSharingFilter, MultipartProvider, JacksonJsonProvider, 
WebApplicationExceptionMapper. How do I make these known to my JAX-RS 
Whiteboard  (Whiteboard service) ?Just derive a new class, annotate as a 
Component and JaxrsExtension?

2. Swagger2Feature, JAASLoginInterceptor, FastInfosetFeature, GZIPFeature, 
CORSPreflightInterceptor (my code, extends AbstractPhaseInterceptor<Message>) 
are provided by CXF and implement CXF interfaces. I gather I can't use these directly 
with the Whiteboard? What do I do with those?  Reimplement/port to JAX-RS?

Best regards,

Oliver




Reply via email to