You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Rizwan Merchant <ri...@alpha-it.com> on 2005/08/04 21:27:41 UTC
Maven2 help
Hi,
I'm trying to use maven2 to compile some code using the pom.xml file shown
below,.i.e., I am running the command "m2 -compile" on a certain project.
Maven2 starts up but eventually dies with a "Compilation failure" message of
the following nature:
[INFO] Reason: Compilation failure
[INFO] ---------------------------------------------------------------------
----
---
[INFO] Failure executing javac, but could not parse the error:
The system is out of resources.
Consult the following stack trace for details.
java.lang.OutOfMemoryError
Any one have any ideas as to why this may be happening?
Thanks for your help.
-Riz.
----------------------------------------------------------------------------
----------------------------
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>com.mycompany.app</groupId>
<artifactId>my-app</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>Maven Quick Start Archetype</name>
<url>http://maven.apache.org</url>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.4</source>
<target>1.4</target>
<minmemory>128m</minmemory>
<maxmemory>1024m</maxmemory>
</configuration>
</plugin>
</plugins>
<sourceDirectory>source</sourceDirectory>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven2 help
Posted by Brett Porter <br...@gmail.com>.
Sorry, I tend to write less explanation when I'd already been
discussing it in another thread :)
Maven1 has settings so you can fork the compiler in a new JVM, using
its own memory settings. Maven2 doesn't yet have that.
You can change Maven2's settigs (and hence the compilers), using
MAVEN_OPTS. This is an environment variable passed directly to the JVM
as arguments, eg:
MAVEN_OPTS=-Xmx1024m
Will set the maximum heap to 1024m.
Cheers,
Brett
On 8/5/05, Rizwan Merchant <ri...@alpha-it.com> wrote:
>
> thanks for the response Brett.
> I actually do have a lot of source to compile...around 3500 files. Is it
> possible that the compilation is generating so many errors that the compiler
> is running out of memory (make sense?)
>
> sorry for the the trivial questions, but I'm using maven for the first time.
> when you say "those settings arent supported", which settings are you
> referring to? can you show me an example of how to use the MAVEN_OPTS
> setting?
>
> thanks again,
> -Riz.
>
> -----Original Message-----
> From: Brett Porter [mailto:brett.porter@gmail.com]
> Sent: Thursday, August 04, 2005 8:33 PM
> To: Maven Users List
> Subject: Re: Maven2 help
>
>
> Those settings aren't currently supported and since the compiler isn't
> forked, you're getting the settings m2 uses (which are the JVM
> defaults). You can control this with MAVEN_OPTS.
>
> Do you really have that much source to compile, or is this happening
> on any project?
>
> - Brett
>
> On 8/5/05, Rizwan Merchant <ri...@alpha-it.com> wrote:
> >
> > Hi,
> > I'm trying to use maven2 to compile some code using the pom.xml file shown
> > below,.i.e., I am running the command "m2 -compile" on a certain project.
> > Maven2 starts up but eventually dies with a "Compilation failure" message
> of
> > the following nature:
> >
> > [INFO] Reason: Compilation failure
> >
> [INFO] ---------------------------------------------------------------------
> > ----
> > ---
> > [INFO] Failure executing javac, but could not parse the error:
> >
> > The system is out of resources.
> > Consult the following stack trace for details.
> > java.lang.OutOfMemoryError
> >
> > Any one have any ideas as to why this may be happening?
> >
> > Thanks for your help.
> > -Riz.
> >
> > --------------------------------------------------------------------------
> --
> > ----------------------------
> >
> > <project>
> > <modelVersion>4.0.0</modelVersion>
> > <groupId>com.mycompany.app</groupId>
> > <artifactId>my-app</artifactId>
> > <packaging>jar</packaging>
> > <version>1.0-SNAPSHOT</version>
> > <name>Maven Quick Start Archetype</name>
> > <url>http://maven.apache.org</url>
> > <build>
> > <plugins>
> > <plugin>
> > <groupId>org.apache.maven.plugins</groupId>
> > <artifactId>maven-compiler-plugin</artifactId>
> > <configuration>
> > <source>1.4</source>
> > <target>1.4</target>
> > <minmemory>128m</minmemory>
> > <maxmemory>1024m</maxmemory>
> > </configuration>
> > </plugin>
> >
> > </plugins>
> >
> > <sourceDirectory>source</sourceDirectory>
> > </build>
> > <dependencies>
> > <dependency>
> > <groupId>junit</groupId>
> > <artifactId>junit</artifactId>
> > <version>3.8.1</version>
> > <scope>test</scope>
> > </dependency>
> > </dependencies>
> > </project>
> >
> >
> >
> > ---------------------------------------------------------------------
> > 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
RE: Maven2 help
Posted by Rizwan Merchant <ri...@alpha-it.com>.
thanks for the response Brett.
I actually do have a lot of source to compile...around 3500 files. Is it
possible that the compilation is generating so many errors that the compiler
is running out of memory (make sense?)
sorry for the the trivial questions, but I'm using maven for the first time.
when you say "those settings arent supported", which settings are you
referring to? can you show me an example of how to use the MAVEN_OPTS
setting?
thanks again,
-Riz.
-----Original Message-----
From: Brett Porter [mailto:brett.porter@gmail.com]
Sent: Thursday, August 04, 2005 8:33 PM
To: Maven Users List
Subject: Re: Maven2 help
Those settings aren't currently supported and since the compiler isn't
forked, you're getting the settings m2 uses (which are the JVM
defaults). You can control this with MAVEN_OPTS.
Do you really have that much source to compile, or is this happening
on any project?
- Brett
On 8/5/05, Rizwan Merchant <ri...@alpha-it.com> wrote:
>
> Hi,
> I'm trying to use maven2 to compile some code using the pom.xml file shown
> below,.i.e., I am running the command "m2 -compile" on a certain project.
> Maven2 starts up but eventually dies with a "Compilation failure" message
of
> the following nature:
>
> [INFO] Reason: Compilation failure
>
[INFO] ---------------------------------------------------------------------
> ----
> ---
> [INFO] Failure executing javac, but could not parse the error:
>
> The system is out of resources.
> Consult the following stack trace for details.
> java.lang.OutOfMemoryError
>
> Any one have any ideas as to why this may be happening?
>
> Thanks for your help.
> -Riz.
>
> --------------------------------------------------------------------------
--
> ----------------------------
>
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>com.mycompany.app</groupId>
> <artifactId>my-app</artifactId>
> <packaging>jar</packaging>
> <version>1.0-SNAPSHOT</version>
> <name>Maven Quick Start Archetype</name>
> <url>http://maven.apache.org</url>
> <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-compiler-plugin</artifactId>
> <configuration>
> <source>1.4</source>
> <target>1.4</target>
> <minmemory>128m</minmemory>
> <maxmemory>1024m</maxmemory>
> </configuration>
> </plugin>
>
> </plugins>
>
> <sourceDirectory>source</sourceDirectory>
> </build>
> <dependencies>
> <dependency>
> <groupId>junit</groupId>
> <artifactId>junit</artifactId>
> <version>3.8.1</version>
> <scope>test</scope>
> </dependency>
> </dependencies>
> </project>
>
>
>
> ---------------------------------------------------------------------
> 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
Re: Maven2 help
Posted by Brett Porter <br...@gmail.com>.
Those settings aren't currently supported and since the compiler isn't
forked, you're getting the settings m2 uses (which are the JVM
defaults). You can control this with MAVEN_OPTS.
Do you really have that much source to compile, or is this happening
on any project?
- Brett
On 8/5/05, Rizwan Merchant <ri...@alpha-it.com> wrote:
>
> Hi,
> I'm trying to use maven2 to compile some code using the pom.xml file shown
> below,.i.e., I am running the command "m2 -compile" on a certain project.
> Maven2 starts up but eventually dies with a "Compilation failure" message of
> the following nature:
>
> [INFO] Reason: Compilation failure
> [INFO] ---------------------------------------------------------------------
> ----
> ---
> [INFO] Failure executing javac, but could not parse the error:
>
> The system is out of resources.
> Consult the following stack trace for details.
> java.lang.OutOfMemoryError
>
> Any one have any ideas as to why this may be happening?
>
> Thanks for your help.
> -Riz.
>
> ----------------------------------------------------------------------------
> ----------------------------
>
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>com.mycompany.app</groupId>
> <artifactId>my-app</artifactId>
> <packaging>jar</packaging>
> <version>1.0-SNAPSHOT</version>
> <name>Maven Quick Start Archetype</name>
> <url>http://maven.apache.org</url>
> <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-compiler-plugin</artifactId>
> <configuration>
> <source>1.4</source>
> <target>1.4</target>
> <minmemory>128m</minmemory>
> <maxmemory>1024m</maxmemory>
> </configuration>
> </plugin>
>
> </plugins>
>
> <sourceDirectory>source</sourceDirectory>
> </build>
> <dependencies>
> <dependency>
> <groupId>junit</groupId>
> <artifactId>junit</artifactId>
> <version>3.8.1</version>
> <scope>test</scope>
> </dependency>
> </dependencies>
> </project>
>
>
>
> ---------------------------------------------------------------------
> 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