maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Curtis Rueden <ctrue...@wisc.edu>
Subject Re: Strange issue with generated jars
Date Wed, 13 Nov 2013 22:32:28 GMT
Hi,

org.apache.maven.user@io7m.com wrote:
> Can anyone else reproduce this problem?

OK, I ran the example ("mvn clean package") and the project builds
successfully on my system:

$ mvn -v
Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17
10:22:22-0500)
Maven home: /usr/local/Cellar/maven/3.1.1/libexec
Java version: 1.7.0_45, vendor: Oracle Corporation
Java home:
/Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "10.9", arch: "x86_64", family: "mac"

$ jar tf code/target/code-0.1.0.jar |wc
      11      11     270

$ jar tf resources/target/resources-0.1.0.jar |wc
   65547   65547 2151861

George Wilson wrote:
> the restriction is in regards to building a larger project like a
> maven build.

Well, it's 38 lines of code:

$ find . -name '*.java' | xargs wc
      10      18     157 ./code/src/main/java/com/io7m/jarbug/Main.java
      28      74     694
./resources/src/main/java/com/io7m/jarbug/MakeSources.java
      38      92     851 total

If you just look at it, you can see that it doesn't do anything bad.

> I am not sure that it is really necessary to ask people to go out of
> their way to build VM systems

I am not the OP, and was not asking you to do anything. I was merely
inquiring whether you could perhaps avoid your company's bureaucracy via
some technical means.

> It seems that since you have run this and generated errors, it would
> be easier as a first step diagnostic to post your error messages-
> output cleaned if need be of course.

I agree that it wouldn't hurt for the OP to post his error messages, too.
But that said, IMHO, posting a complete example project demonstrating the
issue is about the *best* thing you can do.

Regards,
Curtis


On Wed, Nov 13, 2013 at 4:16 PM, George Wilson <rmwscbt@gmail.com> wrote:

> A crippling restriction or not, it is company policy which I do not
> have any authority over. Its one thing to try a snippet from stack
> overflow but the restriction is in regards to building a larger
> project like a maven build. The concern is not being able to evaluate
> what the code or individual scripts do.
> I do not have time right this minute to set up a VM instance but
> perhaps could later on workload permitting. It seems that since you
> have run this and generated errors, it would be easier as a first step
> diagnostic to post your error messages- output cleaned if need be of
> course. FWIW, I am not sure that it is really necessary to ask people
> to go out of their way to build VM systems, when the error output
> might solve the problem immediately.
>
> On Wed, Nov 13, 2013 at 11:37 AM, Curtis Rueden <ctrueden@wisc.edu> wrote:
> > Hi George,
> >
> > That's a new one on me. Can you build in an isolated VM? On a personal
> > machine while at work? Not being able to try out code from the Internet
> > seems like a crippling restriction to me.
> >
> > -Curtis
> >  On Nov 13, 2013 1:34 PM, "George Wilson" <rmwscbt@gmail.com> wrote:
> >
> >> Unfortunately, my company's security policies do not allow for the
> >> downloading and building of external projects without approval from IT
> >> and security so I cannot really test your code (not without going to a
> >> committee, etc...). Any chance you can post the errors you are
> >> getting? Is this a JVM heap issue perhaps? Have you tried increasing
> >> your Java memory? Just a thought since you mentioned that javac is
> >> what seems to die here.
> >>
> >> On Wed, Nov 13, 2013 at 5:57 AM,  <org.apache.maven.user@io7m.com>
> wrote:
> >> > On Tue, 12 Nov 2013 13:02:46 +0000
> >> > <org.apache.maven.user@io7m.com> wrote:
> >> >
> >> >> Hello.
> >> >>
> >> >> I've run into a strange but easily reproduced problem with the jar
> files
> >> >> generated by Maven. Essentially, if I generate a jar file containing
> a
> >> >> large number of files (>= 65536, in practice), then javac becomes
> unable
> >> >> to resolve classes from that jar file. This only occurs with jars
> >> produced
> >> >> by the Maven jar plugin, and only when the number of files is large
> (as
> >> >> demonstrated below).
> >> >>
> >> >> An example build, using the maven exec plugin to generate a large
> >> >> number (65525) of files:
> >> >>
> >> >> http://waste.io7m.com/2013/11/12/jarbug.zip
> >> >
> >> > Can anyone else reproduce this problem? This would seem to indicate a
> >> serious
> >> > bug somewhere. I'm trying to eliminate Maven as a cause.
> >> >
> >> > M
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> >> > For additional commands, e-mail: users-help@maven.apache.org
> >> >
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: users-help@maven.apache.org
> >>
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message