You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Gregor N. Purdy, Sr. (JIRA)" <ji...@codehaus.org> on 2011/12/22 22:43:02 UTC
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Gregor N. Purdy, Sr. created SUREFIRE-812:
---------------------------------------------
Summary: log4j classloader problem in 2.11 that is not there in 2.10
Key: SUREFIRE-812
URL: https://jira.codehaus.org/browse/SUREFIRE-812
Project: Maven Surefire
Issue Type: Bug
Components: Maven Surefire Plugin
Affects Versions: 2.11
Reporter: Gregor N. Purdy, Sr.
Unit test does not fail with 2.10 but does fail with 2.11
Output from failing unit test
log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
$ mvn -version
Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
Plugin config
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.11</version>
<executions>
<execution>
<id>default-test</id>
<phase>test</phase>
<goals>
<goal>test</goal>
</goals>
<configuration>
<argLine>-Xmx2048m -Xms1024m</argLine>
<failIfNoTests>true</failIfNoTests>
<useManifestOnlyJar>false</useManifestOnlyJar>
<forkMode>always</forkMode>
<forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
<redirectTestOutputToFile>true</redirectTestOutputToFile>
<systemPropertyVariables>
<java.awt.headless>true</java.awt.headless>
</systemPropertyVariables>
</configuration>
</execution>
</executions>
<configuration>
<argLine>-Xmx2048m -Xms1024m</argLine>
<failIfNoTests>true</failIfNoTests>
<useManifestOnlyJar>false</useManifestOnlyJar>
<forkMode>always</forkMode>
<forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
<redirectTestOutputToFile>true</redirectTestOutputToFile>
<systemPropertyVariables>
<java.awt.headless>true</java.awt.headless>
</systemPropertyVariables>
</configuration>
</plugin>
reporting plugin configuration
<plugin>
<artifactId>maven-surefire-report-plugin</artifactId>
<version>2.11</version>
<configuration>
<argLine>-Xmx2048m -Xms1024m</argLine>
<failIfNoTests>true</failIfNoTests>
<useManifestOnlyJar>false</useManifestOnlyJar>
<forkMode>always</forkMode>
<forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
<redirectTestOutputToFile>true</redirectTestOutputToFile>
<systemPropertyVariables>
<java.awt.headless>true</java.awt.headless>
</systemPropertyVariables>
</configuration>
</plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=286725#comment-286725 ]
Kristian Rosenvold commented on SUREFIRE-812:
---------------------------------------------
Can you also check if there's a stack trace of any value if you run with mvn -e. Additionally, I assume this "works" if you run forkMode=once ?
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kristian Rosenvold updated SUREFIRE-812:
----------------------------------------
Comment: was deleted
(was: Is there any chance you could produce a small test project that reproduces this issue ?)
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=286693#comment-286693 ]
Kristian Rosenvold commented on SUREFIRE-812:
---------------------------------------------
Is there any chance you could produce a small test project that reproduces this issue ?
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kristian Rosenvold updated SUREFIRE-812:
----------------------------------------
Comment: was deleted
(was: Can you also check if there's a stack trace of any value if you run with mvn -e. Additionally, I assume this "works" if you run forkMode=once ?)
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=286694#comment-286694 ]
Kristian Rosenvold edited comment on SUREFIRE-812 at 12/30/11 4:29 AM:
-----------------------------------------------------------------------
Could you verify that the problem is still present on 2.12-SNAPSHOT, we have fixed another issue with similar symptoms for 2.12.
If not, is there any chance you could produce a small test project that reproduces this issue ?
Can you also check if there's a stack trace of any value if you run with mvn -e. Additionally, I assume this "works" if you run forkMode=once ?
was (Author: krosenvold):
Could you also verify that the problem is still present on 2.12-SNAPSHOT?
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kristian Rosenvold closed SUREFIRE-812.
---------------------------------------
Resolution: Fixed
Fix Version/s: 2.12
Assignee: Kristian Rosenvold
Managed to reproduce, added it in r1228952. The issue has already been fixed but can consitently be proved to happen with 2.11 using the IT
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
> Assignee: Kristian Rosenvold
> Fix For: 2.12
>
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=287744#comment-287744 ]
Kristian Rosenvold commented on SUREFIRE-812:
---------------------------------------------
Can you please attach your log4j configuration ?
I have committed a test project at https://svn.apache.org/repos/asf/maven/surefire/trunk/surefire-integration-tests/src/test/resources/surefire-812-log4j-classloader that can be checked out from svn.
Unfortunately this project does not reproduce the problem (run project with "mvn -Dsurefire.version=2.11 test"). If you could try to modify this project to reproduce the problem, you could submit the diff.
If there is no further acitvity on this issue in a reasonable amount of time I will close it as cannot reproduce
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] (SUREFIRE-812) log4j classloader problem in 2.11 that is not
there in 2.10
Posted by "Kristian Rosenvold (JIRA)" <ji...@codehaus.org>.
[ https://jira.codehaus.org/browse/SUREFIRE-812?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=286694#comment-286694 ]
Kristian Rosenvold commented on SUREFIRE-812:
---------------------------------------------
Could you also verify that the problem is still present on 2.12-SNAPSHOT?
> log4j classloader problem in 2.11 that is not there in 2.10
> -----------------------------------------------------------
>
> Key: SUREFIRE-812
> URL: https://jira.codehaus.org/browse/SUREFIRE-812
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.11
> Reporter: Gregor N. Purdy, Sr.
>
> Unit test does not fail with 2.10 but does fail with 2.11
> Output from failing unit test
> log4j:ERROR A "org.apache.log4j.xml.DOMConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
> log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
> log4j:ERROR [sun.misc.Launcher$AppClassLoader@37b90b39] whereas object of type
> log4j:ERROR "org.apache.log4j.xml.DOMConfigurator" was loaded by [org.apache.maven.surefire.booter.IsolatedClassLoader@7bd63e39].
> log4j:ERROR Could not instantiate configurator [org.apache.log4j.xml.DOMConfigurator].
> $ mvn -version
> Apache Maven 3.0.3 (r1075438; 2011-02-28 09:31:09-0800)
> Plugin config
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <version>2.11</version>
> <executions>
> <execution>
> <id>default-test</id>
> <phase>test</phase>
> <goals>
> <goal>test</goal>
> </goals>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </execution>
> </executions>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
> reporting plugin configuration
> <plugin>
> <artifactId>maven-surefire-report-plugin</artifactId>
> <version>2.11</version>
> <configuration>
> <argLine>-Xmx2048m -Xms1024m</argLine>
> <failIfNoTests>true</failIfNoTests>
> <useManifestOnlyJar>false</useManifestOnlyJar>
> <forkMode>always</forkMode>
> <forkedProcessTimeoutInSeconds>600</forkedProcessTimeoutInSeconds>
> <redirectTestOutputToFile>true</redirectTestOutputToFile>
> <systemPropertyVariables>
> <java.awt.headless>true</java.awt.headless>
> </systemPropertyVariables>
> </configuration>
> </plugin>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira