On Fri, Nov 16, 2012 at 10:33 AM, Jeremie BOUSQUET <
jeremie.bousquet(a)gmail.com> wrote:
2012/11/16 Thomas Mortagne
<thomas.mortagne(a)xwiki.com>
On Thu, Nov 15, 2012 at 8:16 PM, Jeremie BOUSQUET
<
jeremie.bousquet(a)gmail.com> wrote:
Hello,
I'm testing installation of an extension with extension manager /
extension
repository, on XE 4.3-milestone-2:
- deploy my extension (xar + deps) from maven to a local nexus
- import this extension into the extension repo in my xwiki
- try to install it with EM
I get a conflict:
Dependency [javax.jcr:jcr-2.0] is not compatible with core extension
[javax.jcr:jcr-1.0]
I'm trying to understand from where this come from actually. I don't have
it when I build XE war myself but I can find it in the wars on
http://maven.xwiki.org/snapshots/org/xwiki/enterprise/xwiki-enterprise-web/…
This dependency is a transitive dependency
(runtime) of a mstor library
needed by my app. Currently, it is used in xwiki in version 1.0.
I first tried to add an <exclusion> block for it in my pom.xml,
redeployed,
reimported, reinstalled, with same result.
Yes EM does not support exclusions. It's hard to handle in such an
environment where you potentially have several extension depending on the
same thing.
Sure, but in an environment with growing number of dependencies,
transitivity, and versions, you could also say that it will be hard to
handle without those little maven tricks as optional or exclusions ...
I then added jcr 1.0 in a dependencyManagement
section in order to
override
version 2.0 brought by mstor, but again with same
result.
Same thing, right now when EM is looking at your transitive dependencies
it
lost the dependencyManagement from your pom.xml
already.
BTW, additionally, the folder targeted by
xwiki.data.dir remains empty
...
Seems a bit strange.
Maybe it's set in your xwiki.properties files.
It is, but to that same location as of xwiki.data.dir ...
How can I solve this issue ?
Not an easy one.
I can think of several things:
* upgrade the jcr version in XE (I'm trying to look at what this means
exactly)
* have a custom version of your dependency with a different version of
jcr
deployed somewhere like
http://maven.xwiki.org/externals/ (not very
nice)
Yep not nice at all ... In that case and as it would be customized, I would
even prefer to deploy it along my own extension artifacts.
* add support for a kind of exclusion/dependency
overrides in EM
You sure your dependency would fully work with jcr-1.0 ? What is this
dependency by the way ?
I use mstor as a concrete implementation to create a Javamail filesystem
Store. I understand it must use jcr to manage some metadata and structure
content. So there is a big risk that it will not work with jcr-1.0 anyway.
And depending on from where comes the jcr 1.0 in XE, then it could break on
XE side to switch to jcr 2.0.
That being said, I just checked on a local XE 3.5.1, that I could make use
of mstor (for my needs of course) in this instance with manually added
mstor 0.9.13, and with the jcr 1.0 that came from XE (already).
I could also try to find another provider for such Store, but as far as I
searched mstor was the easiest to use and the one most fitting my need.
I could also make it an "optional" feature, and leave to the user the
possibility to manually add that mstor library if he wants to unlock the
feature. But I don't really like that as it's not really EM philosophy.
Would be interesting to know from where comes jcr that's in XE anyway.
Ok I found it. Not sure why I don't have it when I build the WAR. It's
triggered by xwiki-platform-legacy-oldcore.
So it's not "really" needed. It's used for the JCR/XPATH query
implementation in the old query plugin.
Thanks,
Jeremie
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
--
Thomas Mortagne
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users