You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Bryan Campbell (JIRA)" <ji...@codehaus.org> on 2010/11/11 18:33:03 UTC

[jira] Created: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Classpath cleared after maven-javadoc-plugin:javadoc
----------------------------------------------------

                 Key: MJAVADOC-302
                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
             Project: Maven 2.x Javadoc Plugin
          Issue Type: Bug
    Affects Versions: 2.7, 2.6.1, 2.6, 2.5
         Environment: mac OSX 10.6.4
            Reporter: Bryan Campbell
            Priority: Blocker


Repro Case:
  - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
  - > mvn jetty:run

Result:
  - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.

When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 

My javadoc configuration is as follows:

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-javadoc-plugin</artifactId>
  <executions>
    <execution>
      <goals>
        <goal>javadoc</goal>
      </goals>
      <phase>generate-resources</phase>
    </execution>
  </executions>
</plugin>

-- 
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: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=265309#action_265309 ] 

Herve Boutemy commented on MJAVADOC-302:
----------------------------------------

could you be hit by MJAVADOC-279?
ie do you have dependencies with classifiers?

> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Priority: Blocker
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> {code:xml}<plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>{code}

-- 
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: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=265312#action_265312 ] 

Herve Boutemy commented on MJAVADOC-302:
----------------------------------------

after searching more deeply, one way to confirm the issue is to check MPIR-223
please try to use 2.1.1 or 2.2 of maven-project-info-report-plugin: they should not cause the problem
but 2.1, 2.3 or 2.3.1 cause the problem
one workaround is to change the plugin version
another is to avoid dependencies report

> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Priority: Blocker
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> {code:xml}<plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>{code}

-- 
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] Closed: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Herve Boutemy closed MJAVADOC-302.
----------------------------------

       Resolution: Duplicate
    Fix Version/s: 2.8
         Assignee: Herve Boutemy

as far as I can tell, this is a consequence of MPIR-223, then a duplicate of MJAVADOC-279

if you're still having an issue when removing MPIR dependencies report, please open another Jira issue with a test project to reproduce the problem

> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Assignee: Herve Boutemy
>            Priority: Blocker
>             Fix For: 2.8
>
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> {code:xml}<plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>{code}

-- 
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: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Bryon Jacob (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253164#action_253164 ] 

Bryon Jacob commented on MJAVADOC-302:
--------------------------------------

a workaround, which might help indicate the source of the problem, is to use the "aggregate" goal instead of the "javadoc" goal.

it appears that the two goals do essentially the same thing, except that the aggregate goal is run as an aggregator plugin:
 http://maven.apache.org/plugins/maven-javadoc-plugin/javadoc-mojo.html
 http://maven.apache.org/plugins/maven-javadoc-plugin/aggregate-mojo.html
 http://docs.codehaus.org/display/MAVEN/Aggregator+Plugins

which has the benefit that the execution is always forked, so the classpath munging doesn't affect the rest of your lifecycle.  Looking at the source, you can see that the "aggregate" goal simply extends the "javadoc" goal and turns on the "aggregator" bit:
 http://maven.apache.org/plugins/maven-javadoc-plugin/xref/org/apache/maven/plugin/javadoc/AggregatorJavadocReport.html

Looking at the wiki on Aggregator Plugins, I don't see any reason why it should be dangerous to use that on a non-aggregate project, and empirically, this seems to work around the issues Bryan mentions above.


> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Priority: Blocker
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> <plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>

-- 
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: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=264599#action_264599 ] 

Herve Boutemy commented on MJAVADOC-302:
----------------------------------------

can you provide a sample project with instructions to reproduce the problem?

> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Priority: Blocker
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> {code:xml}<plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>{code}

-- 
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: (MJAVADOC-302) Classpath cleared after maven-javadoc-plugin:javadoc

Posted by "Herve Boutemy (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MJAVADOC-302?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Herve Boutemy updated MJAVADOC-302:
-----------------------------------

    Description: 
Repro Case:
  - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
  - > mvn jetty:run

Result:
  - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.

When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 

My javadoc configuration is as follows:

{code:xml}<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-javadoc-plugin</artifactId>
  <executions>
    <execution>
      <goals>
        <goal>javadoc</goal>
      </goals>
      <phase>generate-resources</phase>
    </execution>
  </executions>
</plugin>{code}

  was:
Repro Case:
  - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
  - > mvn jetty:run

Result:
  - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.

When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 

My javadoc configuration is as follows:

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-javadoc-plugin</artifactId>
  <executions>
    <execution>
      <goals>
        <goal>javadoc</goal>
      </goals>
      <phase>generate-resources</phase>
    </execution>
  </executions>
</plugin>


> Classpath cleared after maven-javadoc-plugin:javadoc
> ----------------------------------------------------
>
>                 Key: MJAVADOC-302
>                 URL: http://jira.codehaus.org/browse/MJAVADOC-302
>             Project: Maven 2.x Javadoc Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 2.6, 2.6.1, 2.7
>         Environment: mac OSX 10.6.4
>            Reporter: Bryan Campbell
>            Priority: Blocker
>
> Repro Case:
>   - I have a war based maven configuration with the maven-javadoc-plugin as copied below.
>   - > mvn jetty:run
> Result:
>   - When jetty loads, every servlet fails to load, the first is always java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener followed by null pointers and CNFE's on every servlet.
> When i take out the execution of the maven-javadoc-plugin everything works?!  My only guess is that when the javadoc plugin runs, it does something with the classpath such that when jetty runs it doesn't have what it needs to find all the classes correctly. 
> My javadoc configuration is as follows:
> {code:xml}<plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <executions>
>     <execution>
>       <goals>
>         <goal>javadoc</goal>
>       </goals>
>       <phase>generate-resources</phase>
>     </execution>
>   </executions>
> </plugin>{code}

-- 
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