Hi,

> On 5 Jul 2017, at 17:17, Thomas Mortagne <[email protected]> wrote:
> 
> Hi devs,
> 
> So we now have the concept of optional dependencies at Extension
> Manager level. This are dependencies that are installed by default
> (but if they fail they don't fail the whole install) and which can be
> uninstalled without any impact on what is no longer it's backward
> dependency.
> 
> On Maven -> EM side what I did is reuse <optional>true</optional>
> mostly the following reason: there is no way in pom.xml to put custom
> stuff in <dependency> so it would be a huge pain to maintain a list of
> optional dependencies from a property at general pom level.
> 
> The issue is that the behavior of this <optional> is not exactly the
> same in EM and Maven: in Maven those dependencies are NOT triggered by
> default. Still, apart from this it's supposed to be the same meaning
> and it should not be an issue to install this dependency (if it is
> then it means you should have used something else like
> <scope>provided</scope>) but as usually since there is no official way
> in Maven to say "I just want to use that during the build and it does
> not make any sens to get this dependency" some projects may have used
> it that way.
> 
> So do you think it is OK ? It's not acceptable and we absolutely need
> to move this kind of information in some general property in the pom
> <properties> ?

I don’t really know. I hope it’s fine. We already have usages of the maven 
optional keyword in our POMs; will it work for those use cases? (haven’t 
checked but AFAIR it should work the same since we used those for optional deps 
in XAR modules but probably needs a closer look).

Thanks
-Vincent

> 
> -- 
> Thomas Mortagne

Reply via email to