You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Karl Heinz Marbaise (JIRA)" <ji...@apache.org> on 2015/12/19 22:53:46 UTC

[jira] [Closed] (MJAR-134) Provide the ability to generate multiple jar files rather than one huge jar file.

     [ https://issues.apache.org/jira/browse/MJAR-134?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Karl Heinz Marbaise closed MJAR-134.
------------------------------------
    Resolution: Won't Fix
      Assignee: Karl Heinz Marbaise

> Provide the ability to generate multiple jar files rather than one huge jar file.
> ---------------------------------------------------------------------------------
>
>                 Key: MJAR-134
>                 URL: https://issues.apache.org/jira/browse/MJAR-134
>             Project: Maven JAR Plugin
>          Issue Type: New Feature
>    Affects Versions: 2.3
>            Reporter: Ron Gallagher
>            Assignee: Karl Heinz Marbaise
>         Attachments: MJAR-multijar-002.patch, MJAR-multijar.patch
>
>
> In the environment I work in, we have a Maven project that uses the XMLBeans plugin to 'compile' over 1,300 schema files.  The jar file that's generated by the JAR plugin contains well over 167,000 individual entries.  While it is a 'valid' jar file, the tremendous number of entries in that file are causing some obscure runtime errors.  We have determined that the number of entries in the jar file is the cause of these errors because the errors do not occur if we manually break up that one massive jar file into several smaller jar files.
> The attached patch file contains updates to the maven-jar-plugin that provide this jar-splitting capability within the Maven build environment.  This patch basically adds a new parameter (jarFileCount) to the JarMojo.  If that parameter is 1 or less, then the existing jar-creation logic is used.  However, if that parameter is greater than 1, then multiple jar files are created, each with about the same number of files in them.  The classifier is used to differentiate the various jar files that are crated when the jarFileCount parameter is greater than one.  The sizes of these smaller jar files may vary greatly, but the number of files in them will be relatively consistent.
> The attached patch also contains several integration tests which exercise this new capability.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)