Closed col-panic closed 8 years ago
Ok, now I get what you want after reading this webdav thing. I think the approach to add the getSingleton method to the ApplicationConfiguration is wrong. This is because the publisher makes use of singletons anyway. Each service that is annotated with @Path is registered as singleton within the Jersey Application.
All the webdav extension needs as far as I see it is to register the WebDavContextResolver
and PersistenceExceptionMapper
as singletons. So, basically you have to do the same thing we did with gson, swagger ands on on. Create a new bundle and call it "...provider.webdav". In it's activator simply register the 2 classes as OSGi services. The connector registers them as singletons and you should be done.
thanks for the hint!! It worked out like that :)
In https://webdav-jaxrs.java.net/configuration.html it is required to register singletons for the jax-rs application. Within https://github.com/hstaudacher/osgi-jax-rs-connector/blob/master/bundles/com.eclipsesource.jaxrs.publisher/src/com/eclipsesource/jaxrs/publisher/ApplicationConfiguration.java you already support getProperties, could you include support for getSingletons?
thanks a lot