If you use the dependeny above you should not see com.github.sardine in the import statement of the generated MANIFEST.MF (you can check that in the target folder). Can you either point me to your source code or post the manifest?
Hello @J-N-K, I’ve tried to progress but with no luck. So I’m back to you.
Here’s the link to my code .
Thanks for your help. I’m completely lost between pom, features, bom, appbnd.run …
The bundle sardine @glhopital is using does not export any classes (looking into the jar’s MANIFEST.MF). From my experiences in dependency hell this could be the issue, as the class can’t be resolved. According to Buildsystem docs the solution would be to wrap the library. @J-N-K: is wrapping still possible (as the dependency handling did change)?
Modifications made (source updated), no change but BTW, right now I’m only trying to mvn -U clean install
in org.openhab.io.transport.webdav folder and I fail on :
The transport bundles now compiles & resolved, the binding complains about uncatched exceptions. I did not look into that, if there are further problems, please ping me.
@J-N-K : thanks for your elements. I restarted work with this and I’m nearly headed.
I redefined two modules : io.transport.webdav (that compiles fine),
and binding.cardbook where I still have a sardine dependency issue :
Yes, Webdav is also used by Caldav (v1 binding uses Sardine), reason why I try to do it this way. Here’s the beginning of this journey.
In my last version, I tried to isolate sardine as much as possible in the transport bundle, so I do not understand where some transitive dependency leads carddav to need Sardine.
Hello @J-N-K, I think I made some progress on this issue. Now, I successfully resolve in app.bndrun both modules. Openhab launches successfully, but I face this when accessing WebDAV :
18:17:25.095 [safeCall-1] ERROR o.e.s.c.i.c.AbstractInvocationHandler:100 - An error occurred while calling method 'ThingHandler.initialize()' on 'org.openhab.binding.cardbook.internal.handler.CardDAVHandler@473c1aca': null
java.lang.ExceptionInInitializerError: null
at com.github.sardine.impl.SardineImpl.propfind(SardineImpl.java:459)
at com.github.sardine.impl.SardineImpl.list(SardineImpl.java:409)
at com.github.sardine.impl.SardineImpl.list(SardineImpl.java:399)
at com.github.sardine.impl.SardineImpl.list(SardineImpl.java:393)
at org.openhab.io.transport.webdav.internal.WebDAVManagerImpl.list(WebDAVManagerImpl.java:60)
at org.openhab.binding.cardbook.internal.handler.CardDAVHandler.initialize(CardDAVHandler.java:58)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:152)
at org.eclipse.smarthome.core.internal.common.Invocation.call(Invocation.java:52)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.RuntimeException: javax.xml.bind.JAXBException: Provider com.sun.xml.internal.bind.v2.ContextFactory not found