Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-1950

Docker build broken with log4j-api-java9

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.9.0
    • Component/s: None
    • Labels:
      None
    • Environment:

      Docker

    • Flags:
      Patch

      Description

      Since introduction of jdk9 requirement in the build, docker image cannot be built.

      It fails with:

      [INFO] --- maven-toolchains-plugin:1.1:toolchain (default) @ log4j-api-java9 ---
      [INFO] Required toolchain: jdk [ version='9' ]
      [ERROR] No toolchain found for type jdk
      [ERROR] Cannot find matching toolchain definitions for the following toolchain types:
      jdk [ version='9' ]
      [INFO] ------------------------------------------------------------------------
      [INFO] Reactor Summary:
      [INFO]
      [INFO] Apache Log4j 2 ..................................... SUCCESS [05:27 min]
      [INFO] Apache Log4j API Java 9 support .................... FAILURE [ 25.103 s]
      [INFO] Apache Log4j API ................................... SKIPPED
      [INFO] Apache Log4j Core .................................. SKIPPED
      [INFO] Apache Log4j Core Integration Tests ................ SKIPPED
      [INFO] Apache Log4j 1.x Compatibility API ................. SKIPPED
      [INFO] Apache Log4j SLF4J Binding ......................... SKIPPED
      [INFO] Apache Log4j to SLF4J Adapter ...................... SKIPPED
      [INFO] Apache Log4j Commons Logging Bridge ................ SKIPPED
      [INFO] Apache Log4j Flume Bridge .......................... SKIPPED
      [INFO] Apache Log4j Web ................................... SKIPPED
      [INFO] Apache Log4j Tag Library ........................... SKIPPED
      [INFO] Apache Log4j JMX GUI ............................... SKIPPED
      [INFO] Apache Log4j Samples ............................... SKIPPED
      [INFO] Apache Log4j Samples: Flume - Common ............... SKIPPED
      [INFO] Apache Log4j Samples: Flume - Remote ............... SKIPPED
      [INFO] Apache Log4j Samples: Flume - Embedded ............. SKIPPED
      [INFO] Apache Log4j Samples: Configuration ................ SKIPPED
      [INFO] Apache Log4j Samples: LoggerProperties ............. SKIPPED
      [INFO] Apache Log4j Scala 2.11 wrapper for Log4j API ...... SKIPPED
      [INFO] Apache Log4j Samples: Scala API .................... SKIPPED
      [INFO] Apache Log4j OSGi .................................. SKIPPED
      [INFO] Apache Log4j BOM ................................... SKIPPED
      [INFO] Apache Log4j NoSQL ................................. SKIPPED
      [INFO] Apache Log4J Performance Tests ..................... SKIPPED
      [INFO] Apache Log4j Streaming Interface ................... SKIPPED
      [INFO] Apache Log4j JUL Adapter ........................... SKIPPED
      [INFO] Apache Log4j Liquibase Binding ..................... SKIPPED
      [INFO] Apache Log4j Scala 2.10 wrapper for Log4j API ...... SKIPPED
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 08:47 min
      [INFO] Finished at: 2017-06-22T15:27:35+00:00
      [INFO] Final Memory: 33M/81M
      [INFO] ------------------------------------------------------------------------
      [ERROR] Failed to execute goal org.apache.maven.plugins:maven-toolchains-plugin:1.1:toolchain (default) on project log4j-api-java9: Cannot find matching toolchain definitions for the following toolchain types:
      [ERROR] jdk [ version='9' ]
      [ERROR] Please make sure you define the required toolchains in your ~/.m2/toolchains.xml file.
      [ERROR] -> [Help 1]
      [ERROR]
      [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
      [ERROR] Re-run Maven using the -X switch to enable full debug logging.
      [ERROR]
      [ERROR] For more information about the errors and possible solutions, please read the following articles:
      [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
      [ERROR]
      [ERROR] After correcting the problems, you can resume the build with the command
      [ERROR]   mvn <goals> -rf :log4j-api-java9
      The command '/bin/sh -c set -ex     && cd /src     && /opt/apache-maven-3.3.9/bin/mvn verify' returned a non-zero code: 1
      
      

      I have tried to make it working back, but alpine doesnt support openjdk9 till now, so I suggest to revert to the debian image (FROM openjdk:7-jdk).
      First run is slow, as usual with packages, but then it works smoothly.

      Please check and confirm.
      Have fun with docker

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user phymbert opened a pull request:

          https://github.com/apache/logging-log4j2/pull/84

          LOG4J2-1950 Fix docker build with jdk9 requirements

          Revert docker image base from openjdk:7-alpine to openjdk:7-jdk (debian) since yet alpine does not include jdk9.
          Install jdk9 and specify toolchains file in the mvn build

          Signed-off-by: phymbert <pierrick.hymbert@gmail.com>

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/phymbert/logging-log4j2 LOG4J2-1950

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/logging-log4j2/pull/84.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #84


          commit 516e2ab45ec01021098bfef8f55d7748f16c018b
          Author: phymbert <pierrick.hymbert@gmail.com>
          Date: 2017-06-22T15:33:32Z

          LOG4J2-1950 Fix docker build with jdk9 requirements

          Signed-off-by: phymbert <pierrick.hymbert@gmail.com>


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user phymbert opened a pull request: https://github.com/apache/logging-log4j2/pull/84 LOG4J2-1950 Fix docker build with jdk9 requirements Revert docker image base from openjdk:7-alpine to openjdk:7-jdk (debian) since yet alpine does not include jdk9. Install jdk9 and specify toolchains file in the mvn build Signed-off-by: phymbert <pierrick.hymbert@gmail.com> You can merge this pull request into a Git repository by running: $ git pull https://github.com/phymbert/logging-log4j2 LOG4J2-1950 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/logging-log4j2/pull/84.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #84 commit 516e2ab45ec01021098bfef8f55d7748f16c018b Author: phymbert <pierrick.hymbert@gmail.com> Date: 2017-06-22T15:33:32Z LOG4J2-1950 Fix docker build with jdk9 requirements Signed-off-by: phymbert <pierrick.hymbert@gmail.com>
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user garydgregory commented on the issue:

          https://github.com/apache/logging-log4j2/pull/84

          Curious, why not Maven 3.5.0?

          Show
          githubbot ASF GitHub Bot added a comment - Github user garydgregory commented on the issue: https://github.com/apache/logging-log4j2/pull/84 Curious, why not Maven 3.5.0?
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user jvz commented on the issue:

          https://github.com/apache/logging-log4j2/pull/84

          Can certainly be updated for that since it's not installed via apt-get.

          Show
          githubbot ASF GitHub Bot added a comment - Github user jvz commented on the issue: https://github.com/apache/logging-log4j2/pull/84 Can certainly be updated for that since it's not installed via apt-get.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user phymbert commented on the issue:

          https://github.com/apache/logging-log4j2/pull/84

          I tried to minimise changes, I would prefer to install mvn as a package rather to freeze the version. I may do it tom if you are fine with it.

          Show
          githubbot ASF GitHub Bot added a comment - Github user phymbert commented on the issue: https://github.com/apache/logging-log4j2/pull/84 I tried to minimise changes, I would prefer to install mvn as a package rather to freeze the version. I may do it tom if you are fine with it.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user phymbert commented on the issue:

          https://github.com/apache/logging-log4j2/pull/84

          Updated to 3.5.0, please check

          Show
          githubbot ASF GitHub Bot added a comment - Github user phymbert commented on the issue: https://github.com/apache/logging-log4j2/pull/84 Updated to 3.5.0, please check
          Hide
          jira-bot ASF subversion and git services added a comment -

          Commit 3f45368597b8d47c4997963a4ecc5ae66f486a95 in logging-log4j2's branch refs/heads/master from Pierrick HYMBERT
          [ https://git-wip-us.apache.org/repos/asf?p=logging-log4j2.git;h=3f45368 ]

          LOG4J2-1950 Fix docker build with jdk9 requirements. Closes #84.

          Show
          jira-bot ASF subversion and git services added a comment - Commit 3f45368597b8d47c4997963a4ecc5ae66f486a95 in logging-log4j2's branch refs/heads/master from Pierrick HYMBERT [ https://git-wip-us.apache.org/repos/asf?p=logging-log4j2.git;h=3f45368 ] LOG4J2-1950 Fix docker build with jdk9 requirements. Closes #84.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user asfgit closed the pull request at:

          https://github.com/apache/logging-log4j2/pull/84

          Show
          githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/logging-log4j2/pull/84
          Hide
          garydgregory Gary Gregory added a comment -

          In git master. Please verify and close.

          Show
          garydgregory Gary Gregory added a comment - In git master. Please verify and close.
          Hide
          phymbert Pierrick HYMBERT added a comment -

          OK, building. Thanks

          Show
          phymbert Pierrick HYMBERT added a comment - OK, building. Thanks
          Hide
          phymbert Pierrick HYMBERT added a comment -

          BTW, Log4j 1.x Compatibility API failed in docker env

          [INFO] --- maven-surefire-plugin:2.20:test (default-test) @ log4j-1.2-api ---
          [INFO]
          [INFO] -------------------------------------------------------
          [INFO]  T E S T S
          [INFO] -------------------------------------------------------
          [INFO] Running org.apache.log4j.PriorityTest
          [INFO] Running org.apache.log4j.LoggingTest
          [INFO] Tests run: 21, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.209 s - in org.apache.log4j.PriorityTest
          [INFO] Running org.apache.log4j.config.Log4j1ConfigurationConverterSparkTest
          [INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.642 s - in org.apache.log4j.config.Log4j1ConfigurationConverterSparkTest
          [INFO] Running org.apache.log4j.config.Log4j1ConfigurationConverterHadoopTest
          Missing rootCategory or rootLogger in InputStreamWrapper [description=/src/log4j-1.2-api/src/test/resources/config-1.2/hadoop/hadoop-common-project/hadoop-auth-examples/src/main/resources/lo
          Missing rootCategory or rootLogger in InputStreamWrapper [description=/src/log4j-1.2-api/src/test/resources/config-1.2/hadoop/hadoop-tools/hadoop-sls/src/main/sample-conf/log4j.properties, i
          [INFO] Tests run: 30, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.305 s - in org.apache.log4j.config.Log4j1ConfigurationConverterHadoopTest
          [INFO] Running org.apache.log4j.config.Log4j1ConfigurationFactoryTest
          [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.675 s - in org.apache.log4j.LoggingTest
          [INFO] Running org.apache.log4j.LevelTest
          [INFO] Tests run: 23, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.106 s - in org.apache.log4j.LevelTest
          [INFO] Running org.apache.log4j.LogWithMDCTest
          [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.091 s - in org.apache.log4j.LogWithMDCTest
          [INFO] Running org.apache.log4j.MDCTestCase
          [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 s - in org.apache.log4j.MDCTestCase
          [INFO] Running org.apache.log4j.CategoryTest
          [INFO] Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.087 s - in org.apache.log4j.CategoryTest
          [INFO] Running org.apache.log4j.LogWithRouteTest
          <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
          <html>
          <head>
          <meta charset="UTF-8"/>
          <title>Headline</title>
          <style type="text/css">
          <!--
          body, table {font-family:arial,sans-serif; font-size: medium
          ;}th {background: #336699; color: #FFFFFF; text-align: left;}
          -->
          </style>
          </head>
          <body bgcolor="#FFFFFF" topmargin="6" leftmargin="6">
          <hr size="1" noshade="noshade">
          Log session start time Mon Jun 26 18:00:22 UTC 2017<br>
          <br>
          <table cellspacing="0" cellpadding="4" border="1" bordercolor="#224466" width="100%">
          <tr>
          <th>Time</th>
          <th>Thread</th>
          <th>Level</th>
          <th>Logger</th>
          <th>File:Line</th>
          <th>Message</th>
          </tr>
          </table>
          <br>
          </body></html>
          [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.093 s - in org.apache.log4j.LogWithRouteTest
          [INFO] Running org.apache.log4j.pattern.Log4j1NdcPatternConverterTest
          [INFO] Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.023 s - in org.apache.log4j.pattern.Log4j1NdcPatternConverterTest
          expected: /tmp/hadoop.log Actual: /tmp/hadoop.log
          [INFO] Running org.apache.log4j.pattern.Log4j1MdcPatternConverterTest
          [INFO] Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 s - in org.apache.log4j.pattern.Log4j1MdcPatternConverterTest
          [INFO] Running org.apache.log4j.VelocityTest
          ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'org.apache.logging.log4j.simplelog.StatusLogger.l
          [INFO] Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.078 s - in org.apache.log4j.config.Log4j1ConfigurationFactoryTest
          [INFO] Running org.apache.log4j.LoggerTest
          [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.229 s - in org.apache.log4j.VelocityTest
          [INFO] Running org.apache.log4j.CallerInformationTest
          [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.06 s - in org.apache.log4j.CallerInformationTest
          [INFO] Running org.apache.log4j.NDCTest
          [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 s - in org.apache.log4j.NDCTest
          [INFO] Running org.apache.log4j.layout.Log4j1XmlLayoutTest
          [ERROR] at org.apache.log4j.layout.Log4j1XmlLayoutTest.testWithoutThrown(Log4j1XmlLayoutTest.java:49).apache.log4j.layout.Log4j1XmlLayoutTest
          [ERROR] testWithoutThrown(org.apache.log4j.layout.Log4j1XmlLayoutTest)  Time elapsed: 0.005 s  <<< FAILURE!
          [INFO] Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.33 s - in org.apache.log4j.LoggerTest
          [INFO] d:<...></log4j:message>
          [INFO] Results:>
          [INFO]
          [ERROR] Failures: og4j:message>
          [ERROR]   Log4j1XmlLayoutTest.testWithoutThrown:49 expected:<...></log4j:message>
          <[]/log4j:event>="Name" value="John Smith"/>
          <log4j:data name="Type" value="Service"/>
          > but was:<...></log4j:message>
          <[log4j:properties>
          <log4j:data name="Name" value="John Smith"/>
          <log4j:data name="Type" value="Service"/>
          </log4j:properties>
          <]/log4j:event>
          
          >
          [INFO]
          [ERROR] Tests run: 145, Failures: 1, Errors: 0, Skipped: 0
          [INFO]
          [INFO] ------------------------------------------------------------------------
          [INFO] Reactor Summary:
          [INFO]
          [INFO] Apache Log4j 2 ..................................... SUCCESS [05:10 min]
          [INFO] Apache Log4j API Java 9 support .................... SUCCESS [01:35 min]
          [INFO] Apache Log4j API ................................... SUCCESS [01:59 min]
          [INFO] Apache Log4j Core .................................. SUCCESS [13:23 min]
          [INFO] Apache Log4j Core Integration Tests ................ SUCCESS [01:22 min]
          [INFO] Apache Log4j 1.x Compatibility API ................. FAILURE [  9.119 s]
          [INFO] Apache Log4j SLF4J Binding ......................... SKIPPED
          [INFO] Apache Log4j to SLF4J Adapter ...................... SKIPPED
          [INFO] Apache Log4j Commons Logging Bridge ................ SKIPPED
          [INFO] Apache Log4j Flume Bridge .......................... SKIPPED
          [INFO] Apache Log4j Web ................................... SKIPPED
          [INFO] Apache Log4j Tag Library ........................... SKIPPED
          [INFO] Apache Log4j JMX GUI ............................... SKIPPED
          [INFO] Apache Log4j Samples ............................... SKIPPED
          [INFO] Apache Log4j Samples: Flume - Common ............... SKIPPED
          [INFO] Apache Log4j Samples: Flume - Remote ............... SKIPPED
          [INFO] Apache Log4j Samples: Flume - Embedded ............. SKIPPED
          [INFO] Apache Log4j Samples: Configuration ................ SKIPPED
          [INFO] Apache Log4j Samples: LoggerProperties ............. SKIPPED
          [INFO] Apache Log4j Scala 2.11 wrapper for Log4j API ...... SKIPPED
          [INFO] Apache Log4j Samples: Scala API .................... SKIPPED
          [INFO] Apache Log4j OSGi .................................. SKIPPED
          [INFO] Apache Log4j BOM ................................... SKIPPED
          [INFO] Apache Log4j NoSQL ................................. SKIPPED
          [INFO] Apache Log4J Performance Tests ..................... SKIPPED
          [INFO] Apache Log4j Streaming Interface ................... SKIPPED
          [INFO] Apache Log4j JUL Adapter ........................... SKIPPED
          [INFO] Apache Log4j Liquibase Binding ..................... SKIPPED
          [INFO] Apache Log4j Scala 2.10 wrapper for Log4j API ...... SKIPPED
          [INFO] ------------------------------------------------------------------------
          [INFO] BUILD FAILURE
          [INFO] ------------------------------------------------------------------------
          [INFO] Total time: 26:20 min
          [INFO] Finished at: 2017-06-26T18:00:22Z
          [INFO] Final Memory: 42M/213M
          [INFO] ------------------------------------------------------------------------
          
          Show
          phymbert Pierrick HYMBERT added a comment - BTW, Log4j 1.x Compatibility API failed in docker env [INFO] --- maven-surefire-plugin:2.20:test ( default -test) @ log4j-1.2-api --- [INFO] [INFO] ------------------------------------------------------- [INFO] T E S T S [INFO] ------------------------------------------------------- [INFO] Running org.apache.log4j.PriorityTest [INFO] Running org.apache.log4j.LoggingTest [INFO] Tests run: 21, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.209 s - in org.apache.log4j.PriorityTest [INFO] Running org.apache.log4j.config.Log4j1ConfigurationConverterSparkTest [INFO] Tests run: 20, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.642 s - in org.apache.log4j.config.Log4j1ConfigurationConverterSparkTest [INFO] Running org.apache.log4j.config.Log4j1ConfigurationConverterHadoopTest Missing rootCategory or rootLogger in InputStreamWrapper [description=/src/log4j-1.2-api/src/test/resources/config-1.2/hadoop/hadoop-common-project/hadoop-auth-examples/src/main/resources/lo Missing rootCategory or rootLogger in InputStreamWrapper [description=/src/log4j-1.2-api/src/test/resources/config-1.2/hadoop/hadoop-tools/hadoop-sls/src/main/sample-conf/log4j.properties, i [INFO] Tests run: 30, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.305 s - in org.apache.log4j.config.Log4j1ConfigurationConverterHadoopTest [INFO] Running org.apache.log4j.config.Log4j1ConfigurationFactoryTest [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.675 s - in org.apache.log4j.LoggingTest [INFO] Running org.apache.log4j.LevelTest [INFO] Tests run: 23, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.106 s - in org.apache.log4j.LevelTest [INFO] Running org.apache.log4j.LogWithMDCTest [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.091 s - in org.apache.log4j.LogWithMDCTest [INFO] Running org.apache.log4j.MDCTestCase [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 s - in org.apache.log4j.MDCTestCase [INFO] Running org.apache.log4j.CategoryTest [INFO] Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.087 s - in org.apache.log4j.CategoryTest [INFO] Running org.apache.log4j.LogWithRouteTest <!DOCTYPE HTML PUBLIC "- //W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd" > <html> <head> <meta charset= "UTF-8" /> <title>Headline</title> <style type= "text/css" > <!-- body, table {font-family:arial,sans-serif; font-size: medium ;}th {background: #336699; color: #FFFFFF; text-align: left;} --> </style> </head> <body bgcolor= "#FFFFFF" topmargin= "6" leftmargin= "6" > <hr size= "1" noshade= "noshade" > Log session start time Mon Jun 26 18:00:22 UTC 2017<br> <br> <table cellspacing= "0" cellpadding= "4" border= "1" bordercolor= "#224466" width= "100%" > <tr> <th>Time</th> <th> Thread </th> <th>Level</th> <th>Logger</th> <th>File:Line</th> <th>Message</th> </tr> </table> <br> </body></html> [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.093 s - in org.apache.log4j.LogWithRouteTest [INFO] Running org.apache.log4j.pattern.Log4j1NdcPatternConverterTest [INFO] Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.023 s - in org.apache.log4j.pattern.Log4j1NdcPatternConverterTest expected: /tmp/hadoop.log Actual: /tmp/hadoop.log [INFO] Running org.apache.log4j.pattern.Log4j1MdcPatternConverterTest [INFO] Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 s - in org.apache.log4j.pattern.Log4j1MdcPatternConverterTest [INFO] Running org.apache.log4j.VelocityTest ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'org.apache.logging.log4j.simplelog.StatusLogger.l [INFO] Tests run: 13, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.078 s - in org.apache.log4j.config.Log4j1ConfigurationFactoryTest [INFO] Running org.apache.log4j.LoggerTest [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.229 s - in org.apache.log4j.VelocityTest [INFO] Running org.apache.log4j.CallerInformationTest [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.06 s - in org.apache.log4j.CallerInformationTest [INFO] Running org.apache.log4j.NDCTest [INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 s - in org.apache.log4j.NDCTest [INFO] Running org.apache.log4j.layout.Log4j1XmlLayoutTest [ERROR] at org.apache.log4j.layout.Log4j1XmlLayoutTest.testWithoutThrown(Log4j1XmlLayoutTest.java:49).apache.log4j.layout.Log4j1XmlLayoutTest [ERROR] testWithoutThrown(org.apache.log4j.layout.Log4j1XmlLayoutTest) Time elapsed: 0.005 s <<< FAILURE! [INFO] Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.33 s - in org.apache.log4j.LoggerTest [INFO] d:<...></log4j:message> [INFO] Results:> [INFO] [ERROR] Failures: og4j:message> [ERROR] Log4j1XmlLayoutTest.testWithoutThrown:49 expected:<...></log4j:message> <[]/log4j:event>= "Name" value= "John Smith" /> <log4j:data name= "Type" value= "Service" /> > but was:<...></log4j:message> <[log4j:properties> <log4j:data name= "Name" value= "John Smith" /> <log4j:data name= "Type" value= "Service" /> </log4j:properties> <]/log4j:event> > [INFO] [ERROR] Tests run: 145, Failures: 1, Errors: 0, Skipped: 0 [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Apache Log4j 2 ..................................... SUCCESS [05:10 min] [INFO] Apache Log4j API Java 9 support .................... SUCCESS [01:35 min] [INFO] Apache Log4j API ................................... SUCCESS [01:59 min] [INFO] Apache Log4j Core .................................. SUCCESS [13:23 min] [INFO] Apache Log4j Core Integration Tests ................ SUCCESS [01:22 min] [INFO] Apache Log4j 1.x Compatibility API ................. FAILURE [ 9.119 s] [INFO] Apache Log4j SLF4J Binding ......................... SKIPPED [INFO] Apache Log4j to SLF4J Adapter ...................... SKIPPED [INFO] Apache Log4j Commons Logging Bridge ................ SKIPPED [INFO] Apache Log4j Flume Bridge .......................... SKIPPED [INFO] Apache Log4j Web ................................... SKIPPED [INFO] Apache Log4j Tag Library ........................... SKIPPED [INFO] Apache Log4j JMX GUI ............................... SKIPPED [INFO] Apache Log4j Samples ............................... SKIPPED [INFO] Apache Log4j Samples: Flume - Common ............... SKIPPED [INFO] Apache Log4j Samples: Flume - Remote ............... SKIPPED [INFO] Apache Log4j Samples: Flume - Embedded ............. SKIPPED [INFO] Apache Log4j Samples: Configuration ................ SKIPPED [INFO] Apache Log4j Samples: LoggerProperties ............. SKIPPED [INFO] Apache Log4j Scala 2.11 wrapper for Log4j API ...... SKIPPED [INFO] Apache Log4j Samples: Scala API .................... SKIPPED [INFO] Apache Log4j OSGi .................................. SKIPPED [INFO] Apache Log4j BOM ................................... SKIPPED [INFO] Apache Log4j NoSQL ................................. SKIPPED [INFO] Apache Log4J Performance Tests ..................... SKIPPED [INFO] Apache Log4j Streaming Interface ................... SKIPPED [INFO] Apache Log4j JUL Adapter ........................... SKIPPED [INFO] Apache Log4j Liquibase Binding ..................... SKIPPED [INFO] Apache Log4j Scala 2.10 wrapper for Log4j API ...... SKIPPED [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 26:20 min [INFO] Finished at: 2017-06-26T18:00:22Z [INFO] Final Memory: 42M/213M [INFO] ------------------------------------------------------------------------
          Hide
          garydgregory Gary Gregory added a comment -

          Can I run this on the Windows 10 command line assuming I have Docker installed? (How?) Or, is our "Dockerfile" specific to Jenkins or Travis-CI?

          Show
          garydgregory Gary Gregory added a comment - Can I run this on the Windows 10 command line assuming I have Docker installed? (How?) Or, is our "Dockerfile" specific to Jenkins or Travis-CI?
          Hide
          phymbert Pierrick HYMBERT added a comment -

          Yes Windows docker machine just works fine me.

          Show
          phymbert Pierrick HYMBERT added a comment - Yes Windows docker machine just works fine me.
          Hide
          garydgregory Gary Gregory added a comment -

          What is the command you use?

          Show
          garydgregory Gary Gregory added a comment - What is the command you use?
          Hide
          phymbert Pierrick HYMBERT added a comment -

          Just build from default windows docker machine :

          docker-machine start default
          docker-machine env default
          docker build .
          
          Show
          phymbert Pierrick HYMBERT added a comment - Just build from default windows docker machine : docker-machine start default docker-machine env default docker build .
          Hide
          garydgregory Gary Gregory added a comment -

          I get failures but later:

          [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.186 s - in org.apache.logging.log4j.core.PropertiesFileConfigTest
          [INFO]
          [INFO] Results:
          [INFO]
          [ERROR] Failures:
          [ERROR]   AsyncAppenderTest.rewriteTest:92 Expected org.apache.logging.log4j.core.appender.AsyncAppenderTest rewriteTest This is a test, Actual org.apache.logging.log4j.core.appender.AsyncAppenderTest rewriteTest Hello world!
          [ERROR]   SecureSocketAppenderSocketOptionsTest.testSocketTrafficClass:127 expected:<2> but was:<0>
          [ERROR]   SocketAppenderSocketOptionsTest.testSocketTrafficClass:107 expected:<2> but was:<0>
          [INFO]
          [ERROR] Tests run: 1884, Failures: 3, Errors: 0, Skipped: 18
          [INFO]
          
          Show
          garydgregory Gary Gregory added a comment - I get failures but later: [INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.186 s - in org.apache.logging.log4j.core.PropertiesFileConfigTest [INFO] [INFO] Results: [INFO] [ERROR] Failures: [ERROR] AsyncAppenderTest.rewriteTest:92 Expected org.apache.logging.log4j.core.appender.AsyncAppenderTest rewriteTest This is a test, Actual org.apache.logging.log4j.core.appender.AsyncAppenderTest rewriteTest Hello world! [ERROR] SecureSocketAppenderSocketOptionsTest.testSocketTrafficClass:127 expected:<2> but was:<0> [ERROR] SocketAppenderSocketOptionsTest.testSocketTrafficClass:107 expected:<2> but was:<0> [INFO] [ERROR] Tests run: 1884, Failures: 3, Errors: 0, Skipped: 18 [INFO]
          Hide
          phymbert Pierrick HYMBERT added a comment -

          About Socket errors, looks like you docker VM has issue to access network, maybe check windows firewall and/or restart the docker machine.

          Show
          phymbert Pierrick HYMBERT added a comment - About Socket errors, looks like you docker VM has issue to access network, maybe check windows firewall and/or restart the docker machine.
          Hide
          mikaelstaldal Mikael Ståldal added a comment -

          SecureSocketAppenderSocketOptionsTest.testSocketTrafficClass:127 expected:<2> but was:<0>
          SocketAppenderSocketOptionsTest.testSocketTrafficClass:107 expected:<2> but was:<0>

          Those are the tests that only works on Java 7 (not on Java 8 or 9).

          Show
          mikaelstaldal Mikael Ståldal added a comment - SecureSocketAppenderSocketOptionsTest.testSocketTrafficClass:127 expected:<2> but was:<0> SocketAppenderSocketOptionsTest.testSocketTrafficClass:107 expected:<2> but was:<0> Those are the tests that only works on Java 7 (not on Java 8 or 9).
          Hide
          phymbert Pierrick HYMBERT added a comment -

          The docker VM is configured FROM openjdk:7-jdk, only log4j-api-java9 module use the toolchain jdk9.

          Confirmed with the following run just after the build:

          RUN java -version && /opt/apache-maven-3.5.0/bin/mvn -version
          

          That output:

          Step 5/6 : RUN java -version && /opt/apache-maven-3.5.0/bin/mvn -version
           ---> Running in ec253c24e421
          java version "1.7.0_131"
          OpenJDK Runtime Environment (IcedTea 2.6.9) (7u131-2.6.9-2~deb8u1)
          OpenJDK 64-Bit Server VM (build 24.131-b00, mixed mode)
          Apache Maven 3.5.0 (ff8f5e7444045639af65f6095c62210b5713f426; 2017-04-03T19:39:06Z)
          Maven home: /opt/apache-maven-3.5.0
          Java version: 1.7.0_131, vendor: Oracle Corporation
          Java home: /usr/lib/jvm/java-7-openjdk-amd64/jre
          Default locale: en, platform encoding: UTF-8
          OS name: "linux", version: "4.4.52-boot2docker", arch: "amd64", family: "unix"
           ---> 14c3a4c8a028
          
          Show
          phymbert Pierrick HYMBERT added a comment - The docker VM is configured FROM openjdk:7-jdk , only log4j-api-java9 module use the toolchain jdk9. Confirmed with the following run just after the build: RUN java -version && /opt/apache-maven-3.5.0/bin/mvn -version That output: Step 5/6 : RUN java -version && /opt/apache-maven-3.5.0/bin/mvn -version ---> Running in ec253c24e421 java version "1.7.0_131" OpenJDK Runtime Environment (IcedTea 2.6.9) (7u131-2.6.9-2~deb8u1) OpenJDK 64-Bit Server VM (build 24.131-b00, mixed mode) Apache Maven 3.5.0 (ff8f5e7444045639af65f6095c62210b5713f426; 2017-04-03T19:39:06Z) Maven home: /opt/apache-maven-3.5.0 Java version: 1.7.0_131, vendor: Oracle Corporation Java home: /usr/lib/jvm/java-7-openjdk-amd64/jre Default locale: en, platform encoding: UTF-8 OS name: "linux" , version: "4.4.52-boot2docker" , arch: "amd64" , family: "unix" ---> 14c3a4c8a028
          Hide
          mikaelstaldal Mikael Ståldal added a comment -

          Then something else might be wrong. Those Socket option traffic class tests have failed for various reasons before. I think Gary Gregory once added them, so maybe he can investigate them in deep?

          Show
          mikaelstaldal Mikael Ståldal added a comment - Then something else might be wrong. Those Socket option traffic class tests have failed for various reasons before. I think Gary Gregory once added them, so maybe he can investigate them in deep?
          Hide
          garydgregory Gary Gregory added a comment -

          The test has JUnit Assume's to only run on Java 7 and not on Travis. I can't dig in today unfortunately.

          Show
          garydgregory Gary Gregory added a comment - The test has JUnit Assume's to only run on Java 7 and not on Travis. I can't dig in today unfortunately.

            People

            • Assignee:
              Unassigned
              Reporter:
              phymbert Pierrick HYMBERT
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development