Uploaded image for project: 'Parquet'
  1. Parquet
  2. PARQUET-1293

Build failure when using Java 8 lambda expressions

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.8.2
    • 1.11.0
    • None
    • None

    Description

      I tried to use Java 8 lambda expressions, but when I tried mvn clean install, I ran into compilation error:

      
      [ERROR] Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.1:shade (default) on project parquet-column: Error creating shaded jar: 10969 -> [Help 1]
      
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.1:shade (default) on project parquet-column: Error creating shaded jar: 10969
      
       at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
      
       at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
      
       at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
      
       at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
      
       at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
      
       at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
      
       at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
      
       at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
      
       at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
      
       at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
      
       at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
      
       at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
      
       at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
      
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      
       at java.lang.reflect.Method.invoke(Method.java:498)
      
       at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
      
       at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
      
       at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
      
       at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
      
      Caused by: org.apache.maven.plugin.MojoExecutionException: Error creating shaded jar: 10969
      
       at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:528)
      
       at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
      
       at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
      
       ... 20 more
      
      Caused by: java.lang.ArrayIndexOutOfBoundsException: 10969
      
       at org.objectweb.asm.ClassReader.<init>(Unknown Source)
      
       at org.objectweb.asm.ClassReader.<init>(Unknown Source)
      
       at org.objectweb.asm.ClassReader.<init>(Unknown Source)
      
       at org.vafer.jdependency.Clazzpath.addClazzpathUnit(Clazzpath.java:94)
      
       at org.apache.maven.plugins.shade.filter.MinijarFilter.<init>(MinijarFilter.java:77)
      
       at org.apache.maven.plugins.shade.mojo.ShadeMojo.getFilters(ShadeMojo.java:767)
      
       at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:445)
      
       ... 22 more
      
      

       

      Since Parquet is already on Java 8, one should be able to use all Java 8 features. Upgrading maven-shade-plugin version and enforcer-rule dependency of 

      maven-enforcer-plugin would solve the problem.

      Attachments

        Issue Links

          Activity

            People

              nkollar Nándor Kollár
              nkollar Nándor Kollár
              Votes:
              0 Vote for this issue
              Watchers:
              3 Stop watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Slack

                  Issue deployment