Hi Plamen,
On Tue, 29 Aug 2017 07:46:59 +0200, Plamen Totev
<[email protected]> wrote:
Hi Robert,
Thank you for you comments.
Also I took a look at the changes in the JDK jar tool and I notice a
couple of things that it does:
1. The structure of the jar produced is such that the module info
entries are placed after the manifest and before the rest of the
files. Plexus Archiver does not handle the module info entries
differently and they are placed in random order among the rest of the
files.
IIRC Plexus Archiver is already capable to put the manifest file up
front.
The same should be possible with the module descriptor.
I double checked the changes in the Jar File Specifications [1] and
there are no requirements specifying where the module-info.class entry
should be located in regard to the rest of the entries(I mean
physically in the file). So I consider this behavior implementation
specific.
I think we need to focus on version and mainClass first, that's
probably the
first things users will ask and which is really visible to them. If the
extra checks are not required I consider them as nice to have checks and
pick them up later.
Makes sense. I created issues for them as well so we don't forget
them.[2][3][4]
Regarding the implementation. Unfortunately as you mention it will
require adjusting the byte code of the module-info.class. And I don't
have knowledge in the matter so I'll need help with that. Also I was
thinking that maybe such functionality(adding/replacing information
to the ModuleDescriptor) is good fit for the newly introduced
plexus-languages project?
I've started a bit with it, but no success yet:
https://mail.ow2.org/wws/arc/asm/2017-08/msg00004.html
Even after the suggestions from Remi no success yet.
I was hoping for a fast fix, but it'll take more time and other things are
waiting as well.
Would be great if you can pick it up from here.
I hope it won't become part of plexus-java, that would be a bad sign :)
Plexus-java contains code which are used by at least 3 or 4 other
projects/plugins. Don't think that transforming a module descriptor would
be such often used feature.
Robert
Regards,
Plamen Totev
[1] http://cr.openjdk.java.net/~mr/jigsaw/spec/jar.html
[2] https://github.com/codehaus-plexus/plexus-archiver/issues/67
[3] https://github.com/codehaus-plexus/plexus-archiver/issues/68
[4] https://github.com/codehaus-plexus/plexus-archiver/issues/69
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]