You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Brian Fox (JIRA)" <ji...@codehaus.org> on 2007/03/19 22:07:34 UTC

[jira] Created: (MRELEASE-206) its not possible to pass MAVEN_OPTS to the forked release build

its not possible to pass MAVEN_OPTS to the forked release build
---------------------------------------------------------------

                 Key: MRELEASE-206
                 URL: http://jira.codehaus.org/browse/MRELEASE-206
             Project: Maven 2.x Release Plugin
          Issue Type: Bug
    Affects Versions: 2.0-beta-4, 2.0-beta-3
            Reporter: Brian Fox


I need to increase my jvm size for my build. The forked release doesn't get the maven_opts. I tried the -Darguments:

mvn release:prepare -DdryRun=true -Darguments=-Xmx1024m 
gets me this:  

   [INFO] Invalid task 'mx1024m': you must specify a valid lifecycle phase, or 
 a goal in the format plugin:goal or pluginGroupId:pluginArtifactId:pluginVersion 
 :goal 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MRELEASE-206) its not possible to pass MAVEN_OPTS to the forked release build

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRELEASE-206?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=136036#action_136036 ] 

Benjamin Bentmann commented on MRELEASE-206:
--------------------------------------------

The {{-Darguments}} can only carry the arguments for Maven's {{main()}} method, not the JVM options. MAVEN_OPTS must be passed down via environment variables.

Realizing this would basically require to extend the {{ForkedMavenExecutor}} as already shown by the {{DefaultInvoker}}, i.e. pass down all envvars of the parent process to the sub process:
{code:java}
cli.addSystemEnvironment();
cli.addEnvironment( "MAVEN_TERMINATE_CMD", "on" );
{code}
This way, users should never have to bother with configuring the MAVEN_OPTS for the plugin. What works for the main build should work equally well for the forked build.

The only problem is that the Release Plugin currently uses plexus-utils 1.3 which doesn't allow to (easily) overwrite inherited envvars. Can we simply upgrade to the latest plexus-utils, thereby bumbing the prerequisite to Maven 2.0.6, or should we just workaround the Plexus issue? Among others, we have both the Surefire Plugin and the JAR Plugin requiring Maven 2.0.6 so I wonder why this plugin couldn't be bumped, too.

> its not possible to pass MAVEN_OPTS to the forked release build
> ---------------------------------------------------------------
>
>                 Key: MRELEASE-206
>                 URL: http://jira.codehaus.org/browse/MRELEASE-206
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0-beta-3, 2.0-beta-4
>            Reporter: Brian Fox
>
> I need to increase my jvm size for my build. The forked release doesn't get the maven_opts. I tried the -Darguments:
> mvn release:prepare -DdryRun=true -Darguments=-Xmx1024m 
> gets me this:  
>    [INFO] Invalid task 'mx1024m': you must specify a valid lifecycle phase, or 
>  a goal in the format plugin:goal or pluginGroupId:pluginArtifactId:pluginVersion 
>  :goal 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MRELEASE-206) its not possible to pass MAVEN_OPTS to the forked release build

Posted by "Stephen Connolly (JIRA)" <ji...@codehaus.org>.
     [ https://jira.codehaus.org/browse/MRELEASE-206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stephen Connolly updated MRELEASE-206:
--------------------------------------

    Fix Version/s: Backlog
           Labels: contributers-welcome  (was: )

Before running off and writing a patch, check back with dev@m.a.o on how you would plan to write a patch for this

> its not possible to pass MAVEN_OPTS to the forked release build
> ---------------------------------------------------------------
>
>                 Key: MRELEASE-206
>                 URL: https://jira.codehaus.org/browse/MRELEASE-206
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-3, 2.0-beta-4
>            Reporter: Brian Fox
>              Labels: contributers-welcome
>             Fix For: Backlog
>
>
> I need to increase my jvm size for my build. The forked release doesn't get the maven_opts. I tried the -Darguments:
> mvn release:prepare -DdryRun=true -Darguments=-Xmx1024m 
> gets me this:  
>    [INFO] Invalid task 'mx1024m': you must specify a valid lifecycle phase, or 
>  a goal in the format plugin:goal or pluginGroupId:pluginArtifactId:pluginVersion 
>  :goal 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MRELEASE-206) its not possible to pass MAVEN_OPTS to the forked release build

Posted by "Arnaud Heritier (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRELEASE-206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Arnaud Heritier updated MRELEASE-206:
-------------------------------------

    Component/s: prepare

> its not possible to pass MAVEN_OPTS to the forked release build
> ---------------------------------------------------------------
>
>                 Key: MRELEASE-206
>                 URL: http://jira.codehaus.org/browse/MRELEASE-206
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-3, 2.0-beta-4
>            Reporter: Brian Fox
>
> I need to increase my jvm size for my build. The forked release doesn't get the maven_opts. I tried the -Darguments:
> mvn release:prepare -DdryRun=true -Darguments=-Xmx1024m 
> gets me this:  
>    [INFO] Invalid task 'mx1024m': you must specify a valid lifecycle phase, or 
>  a goal in the format plugin:goal or pluginGroupId:pluginArtifactId:pluginVersion 
>  :goal 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira