Bug 451279 - change addMavenDescriptor default to false for features
Summary: change addMavenDescriptor default to false for features
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Tycho (show other bugs)
Version: unspecified   Edit
Hardware: All Windows All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Tobias Oberlies CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed, helpwanted
Depends on:
Blocks:
 
Reported: 2014-11-13 04:02 EST by Jan Sievers CLA
Modified: 2021-04-28 16:52 EDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Sievers CLA 2014-11-13 04:02:15 EST
maven desriptors META-INF/maven/... tend to add lengthy paths inside the jar archive being created.

For features, which are always unpacked in the installation, this can cause path length problems on Windows (hey Windows, it's 2014...) 

Maven descriptors are not really needed so if they cause potential problems we should not generate them at least for features by default.
Comment 1 Tobias Oberlies CLA 2014-11-14 11:18:10 EST
I suppose that the <archive> configuration parameter [1] is shared by several packaging-plugin goals, so I don't know if it makes sense to only change the default for features.

BTW, some site doc for the parameter would be nice :-)

[1] https://www.eclipse.org/tycho/sitedocs/tycho-packaging-plugin/package-plugin-mojo.html#archive
Comment 2 Tobias Oberlies CLA 2014-11-14 11:38:34 EST
For the apparently correct configuration syntax, see bug 401040 comment 8.
Comment 3 Martin Schreiber CLA 2014-11-20 10:29:01 EST
Pushed a patch for review: https://git.eclipse.org/r/#/c/36777/

Actually the <archive> parameter is not shared between the different packaging plugin goals, so it was easy to had 2 different defaults (leave plugin packaging as it was and setting the default for features to not include the maven stuff).

If you think that the default should be the same for both, I can change that in the plugin mojo as well.
Comment 4 Thomas Schindl CLA 2014-11-20 10:43:26 EST
I'm for having false everywhere because even bundles can be exploded on install
Comment 5 Jan Sievers CLA 2014-11-20 10:49:51 EST
(In reply to Thomas Schindl from comment #4)
> I'm for having false everywhere because even bundles can be exploded on
> install

OK with me. 

@Igor do you know anything/anyone we would break by not adding META-INF/maven descriptors by default to feature and plugin jars anymore?
Comment 6 Igor Fedorenko CLA 2014-11-21 09:23:47 EST
https://github.com/ifedorenko/com.ifedorenko.m2e.sourcelookup will break without maven metadata.
Comment 7 Tobias Oberlies CLA 2014-11-24 03:33:46 EST
(In reply to Igor Fedorenko from comment #6)
> https://github.com/ifedorenko/com.ifedorenko.m2e.sourcelookup will break
> without maven metadata.

In this case, I'd say that we should only change the default for features.
Comment 8 Tobias Oberlies CLA 2014-12-01 06:43:48 EST
Submitted Martin's patch: http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/commit/?id=2e6145f496ee9805e8292e5195709ec42683d32b

@Martin: Thank you very much for contributing this patch with excellent site doc and test coverage.
Comment 9 Andreas Sewe CLA 2015-01-05 11:40:11 EST
(In reply to Igor Fedorenko from comment #6)
> https://github.com/ifedorenko/com.ifedorenko.m2e.sourcelookup will break
> without maven metadata.

FWIW and in case this issue is ever re-opened: Eclipse Code Recommenders also tries to identify dependencies based on their metadata like META-INF/maven/... Thus, having this information available for bundles is beneficial to us as well.