You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Milos Kleint (JIRA)" <de...@myfaces.apache.org> on 2007/01/25 14:30:49 UTC

[jira] Created: (TOBAGO-256) the apt plugin fails to execute in embedded environment

the apt plugin fails to execute in embedded environment
-------------------------------------------------------

                 Key: TOBAGO-256
                 URL: https://issues.apache.org/jira/browse/TOBAGO-256
             Project: MyFaces Tobago
          Issue Type: Bug
          Components: Maven Apt Plugin
         Environment: maven 2.1-snapshot + mevenide 2.3 + netbeans 5.5
            Reporter: Milos Kleint
            Priority: Blocker


the apt plugin seems to fail in embedded environment, like in the netbeans IDE integration.

when not forked, it cannot find the apt's main class for some reason. This one could be either a problem in the plugin or somewhere in the classloading of maven when embedding (or somewhere else)

when forked, it fails to execute on windows platform where there is space in the path to jdk. that one seems to be hardly a problem of embedding, but strangely enough it seems to work on command line just fine.

for details, see http://jira.codehaus.org/browse/MEVENIDE-482

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TOBAGO-256) the apt plugin fails to execute in embedded environment

Posted by "Benjamin Bentmann (JIRA)" <de...@myfaces.apache.org>.
    [ https://issues.apache.org/jira/browse/TOBAGO-256?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12778841#action_12778841 ] 

Benjamin Bentmann commented on TOBAGO-256:
------------------------------------------

>From the plugin's source code:
{code:java}
// we need to have tools.jar in lasspath
// due to bug in Apt compiler, system classpath must be modified but in future:
// TODO try separate ClassLoader (see Plexus compiler api)
if ( !isClasspathModified )
{
    URL toolsJar = new File( System.getProperty( "java.home" ),
        "../lib/tools.jar" ).toURL();
    Method m = URLClassLoader.class.getDeclaredMethod( "addURL",
          new Class[] { URL.class } );
    m.setAccessible( true );
    m.invoke( this.getClass().getClassLoader()
        .getSystemClassLoader(), new Object[] { toolsJar } );
    isClasspathModified = true;
}
{code}
hacking the system class loader is a no-no. They should create their own class loader.

> the apt plugin fails to execute in embedded environment
> -------------------------------------------------------
>
>                 Key: TOBAGO-256
>                 URL: https://issues.apache.org/jira/browse/TOBAGO-256
>             Project: MyFaces Tobago
>          Issue Type: Bug
>          Components: Maven Apt Plugin
>         Environment: maven 2.1-snapshot + mevenide 2.3 + netbeans 5.5
>            Reporter: Milos Kleint
>
> the apt plugin seems to fail in embedded environment, like in the netbeans IDE integration.
> when not forked, it cannot find the apt's main class for some reason. This one could be either a problem in the plugin or somewhere in the classloading of maven when embedding (or somewhere else)
> when forked, it fails to execute on windows platform where there is space in the path to jdk. that one seems to be hardly a problem of embedding, but strangely enough it seems to work on command line just fine.
> for details, see http://jira.codehaus.org/browse/MEVENIDE-482

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TOBAGO-256) the apt plugin fails to execute in embedded environment

Posted by "Benjamin Bentmann (JIRA)" <de...@myfaces.apache.org>.
    [ https://issues.apache.org/jira/browse/TOBAGO-256?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12782825#action_12782825 ] 

Benjamin Bentmann commented on TOBAGO-256:
------------------------------------------

Users suffering from this issue are advised to migrate their builds to use the [apt-maven-plugin:1.0-alpha-3|http://mojo.codehaus.org/apt-maven-plugin/] from the Mojo project which includes a fix for the issue (MOJO-1458).

> the apt plugin fails to execute in embedded environment
> -------------------------------------------------------
>
>                 Key: TOBAGO-256
>                 URL: https://issues.apache.org/jira/browse/TOBAGO-256
>             Project: MyFaces Tobago
>          Issue Type: Bug
>          Components: Maven Apt Plugin
>         Environment: maven 2.1-snapshot + mevenide 2.3 + netbeans 5.5
>            Reporter: Milos Kleint
>
> the apt plugin seems to fail in embedded environment, like in the netbeans IDE integration.
> when not forked, it cannot find the apt's main class for some reason. This one could be either a problem in the plugin or somewhere in the classloading of maven when embedding (or somewhere else)
> when forked, it fails to execute on windows platform where there is space in the path to jdk. that one seems to be hardly a problem of embedding, but strangely enough it seems to work on command line just fine.
> for details, see http://jira.codehaus.org/browse/MEVENIDE-482

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.