Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-4673

Launchpad Testing: Running mvn package without clean leads to errors with the animal-sniffer-plugin

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: Launchpad Testing 10
    • Fix Version/s: Launchpad Testing 10
    • Component/s: Launchpad
    • Labels:
      None

      Description

      First executing mvn clean install on launchpad.testing runs fine, but if afterwards only mvn install is executed the build fails with the following error

      [INFO] Scanning for projects...
      [INFO] 
      [INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
      [INFO]                                                                         
      [INFO] ------------------------------------------------------------------------
      [INFO] Building Apache Sling Launchpad Testing 7-SNAPSHOT
      [INFO] ------------------------------------------------------------------------
      [INFO] 
      [INFO] --- maven-enforcer-plugin:1.3.1:enforce (enforce-java) @ org.apache.sling.launchpad.testing ---
      [INFO] 
      [INFO] --- maven-antrun-plugin:1.7:run (set-bundle-required-execution-environment) @ org.apache.sling.launchpad.testing ---
      [INFO] Executing tasks
      
      main:
      [INFO] Executed tasks
      [INFO] 
      [INFO] --- maven-remote-resources-plugin:1.5:process (default) @ org.apache.sling.launchpad.testing ---
      [INFO] 
      [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ org.apache.sling.launchpad.testing ---
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] skip non existing resourceDirectory /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/src/main/resources
      [INFO] Copying 3 resources
      [INFO] 
      [INFO] --- maven-antrun-plugin:1.7:run (check-memory-task) @ org.apache.sling.launchpad.testing ---
      [INFO] Executing tasks
      
      main:
           [echo] **************** WARNING (SLING-443/SLING-1782) ******************************
           [echo] On most platforms, you'll get OutOfMemoryErrors when building unless you set
           [echo] on 32bit platforms: MAVEN_OPTS="-Xmx256M -XX:MaxPermSize=256M", see SLING-443
           [echo] on 64bit platforms: MAVEN_OPTS="-Xmx512M -XX:MaxPermSize=512M", see SLING-1782
           [echo] ******************************************************************************
      [INFO] Executed tasks
      [INFO] 
      [INFO] --- build-helper-maven-plugin:1.8:reserve-network-port (reserve-network-port) @ org.apache.sling.launchpad.testing ---
      [INFO] Reserved port 41600 for http.port
      [INFO] Reserved port 41601 for sling.control.port
      [INFO] 
      [INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ org.apache.sling.launchpad.testing ---
      [INFO] No sources to compile
      [INFO] 
      [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ org.apache.sling.launchpad.testing ---
      [INFO] Using 'UTF-8' encoding to copy filtered resources.
      [INFO] Copying 1 resource
      [INFO] Copying 3 resources
      [INFO] 
      [INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ org.apache.sling.launchpad.testing ---
      [INFO] No sources to compile
      [INFO] 
      [INFO] --- maven-surefire-plugin:2.17:test (default-test) @ org.apache.sling.launchpad.testing ---
      [INFO] 
      [INFO] --- animal-sniffer-maven-plugin:1.11:check (default) @ org.apache.sling.launchpad.testing ---
      [INFO] Checking unresolved references to org.codehaus.mojo.signature:java15:1.0
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:297: Undefined reference: java.lang.management.ThreadInfo[] java.lang.management.ThreadMXBean.dumpAllThreads(boolean, boolean)
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:303: Undefined reference: java.lang.management.LockInfo[] java.lang.management.ThreadInfo.getLockedSynchronizers()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:308: Undefined reference: String java.lang.management.LockInfo.getClassName()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:308: Undefined reference: int java.lang.management.LockInfo.getIdentityHashCode()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:324: Undefined reference: boolean java.lang.management.ThreadMXBean.isSynchronizerUsageSupported()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:325: Undefined reference: long[] java.lang.management.ThreadMXBean.findDeadlockedThreads()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:330: Undefined reference: java.lang.management.ThreadInfo[] java.lang.management.ThreadMXBean.getThreadInfo(long[], boolean, boolean)
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:358: Undefined reference: java.lang.management.LockInfo java.lang.management.ThreadInfo.getLockInfo()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:358: Undefined reference: String java.lang.management.LockInfo.getClassName()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:358: Undefined reference: java.lang.management.LockInfo java.lang.management.ThreadInfo.getLockInfo()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:358: Undefined reference: int java.lang.management.LockInfo.getIdentityHashCode()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:410: Undefined reference: java.lang.management.MonitorInfo[] java.lang.management.ThreadInfo.getLockedMonitors()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:428: Undefined reference: java.lang.management.LockInfo java.lang.management.ThreadInfo.getLockInfo()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:429: Undefined reference: java.lang.management.LockInfo java.lang.management.ThreadInfo.getLockInfo()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:429: Undefined reference: String java.lang.management.LockInfo.getClassName()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:429: Undefined reference: java.lang.management.LockInfo java.lang.management.ThreadInfo.getLockInfo()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:429: Undefined reference: int java.lang.management.LockInfo.getIdentityHashCode()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:443: Undefined reference: int java.lang.management.MonitorInfo.getLockedStackDepth()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:444: Undefined reference: String java.lang.management.MonitorInfo.getClassName()
      [ERROR] /Users/kwindszus/Workspaces/Sling/sling-builder/launchpad/testing/target/classes/org/apache/sling/launchpad/app/ControlListener.class:444: Undefined reference: int java.lang.management.MonitorInfo.getIdentityHashCode()
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 26.823 s
      [INFO] Finished at: 2015-04-28T11:08:34+01:00
      [INFO] Final Memory: 37M/241M
      [INFO] ------------------------------------------------------------------------
      [ERROR] Failed to execute goal org.codehaus.mojo:animal-sniffer-maven-plugin:1.11:check (default) on project org.apache.sling.launchpad.testing: Signature errors found. Verify them and ignore them with the proper annotation if needed. -> [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
      

      I run Maven 3.2.1 with Java 1.8.0_05 jdk. The same error happens under Maven 3.3.1 with Java 1.7.0_60.

      It seems that some code which is incompatible with Java 5 is copied over to target (from launchpad.base). Please either exclude that from being checked with the animal-sniffer-plugin in the launchpad.testing build or check it only for Java 6 compatibility.

        Attachments

          Activity

            People

            • Assignee:
              cziegeler Carsten Ziegeler
              Reporter:
              kwin Konrad Windszus
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: