Groovy
  1. Groovy
  2. GROOVY-4673

java.lang.ClassFormatError: Illegal class name "groovy/jmx/builder/package-info" in class file groovy/jmx/builder/package-info

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.7.7
    • Fix Version/s: 1.8.1, 1.7.11
    • Component/s: groovy-jdk
    • Labels:
      None
    • Environment:
      JBoss AS 6.0.0 / Tomcat 7.0.0
      Windows 7

      Description

      The groovy-all-1.7.7.jar file in the embeddable directory of the binary ZIP file contains an invalid package-info file groovy.jmx.builder.package-info.class. I believe this is due to the src/main/groovy/jmx/builder/package-info.groovy file being incorrectly compiled. In Tomcat 7.0.0 and JBoss AS 6.0.0, this results in an exception like the one below and a deployment failure for any applications that bundle this JAR file.

      Tomcat has since released a patch that issues this is a warning and allows the deployment to continue, but JBoss AS has not. Since the problem is ultimately that a legitimately invalid package-info class exists in the library, it seems most logical that the problem be resolved with Groovy and not JBoss.

      I was able to resolve my issue for now by manually editing the distributable JAR file and removing the package-info.class file from it, but this is not a good permanent solution.

      Here is the exception:

      Exception
      18:02:52,225 WARN  [org.jboss.detailed.classloader.ClassLoaderManager] Unexpected error during load of:groovy.jmx.builder.package-info: java.lang.ClassFormatError: Illegal class name "groovy/jmx/builder/package-info" in class file groovy/jmx/builder/package-info
      	at java.lang.ClassLoader.defineClass1(Native Method) [:1.6.0_23]
      	at java.lang.ClassLoader.defineClassCond(Unknown Source) [:1.6.0_23]
      	at java.lang.ClassLoader.defineClass(Unknown Source) [:1.6.0_23]
      	at org.jboss.classloader.spi.base.BaseClassLoader.access$200(BaseClassLoader.java:52) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader$2.run(BaseClassLoader.java:650) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader$2.run(BaseClassLoader.java:609) [jboss-classloader.jar:2.2.0.GA]
      	at java.security.AccessController.doPrivileged(Native Method) [:1.6.0_23]
      	at org.jboss.classloader.spi.base.BaseClassLoader.loadClassLocally(BaseClassLoader.java:608) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader.loadClassLocally(BaseClassLoader.java:585) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseDelegateLoader.loadClass(BaseDelegateLoader.java:156) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.filter.FilteredDelegateLoader.doLoadClass(FilteredDelegateLoader.java:141) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.filter.FilteredDelegateLoader.loadClass(FilteredDelegateLoader.java:132) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.ClassLoadingTask$ThreadTask.run(ClassLoadingTask.java:461) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.ClassLoaderManager.nextTask(ClassLoaderManager.java:262) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.ClassLoaderManager.process(ClassLoaderManager.java:161) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoaderDomain.loadClass(BaseClassLoaderDomain.java:260) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoaderDomain.loadClass(BaseClassLoaderDomain.java:1152) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader.loadClassFromDomain(BaseClassLoader.java:886) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader.doLoadClass(BaseClassLoader.java:505) [jboss-classloader.jar:2.2.0.GA]
      	at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:450) [jboss-classloader.jar:2.2.0.GA]
      	at java.lang.ClassLoader.loadClass(Unknown Source) [:1.6.0_23]
      	at java.lang.Class.forName0(Native Method) [:1.6.0_23]
      	at java.lang.Class.forName(Unknown Source) [:1.6.0_23]
      	at org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactoryImpl.resolveComplexTypeInfo(IntrospectionTypeInfoFactoryImpl.java:458) [jboss-reflect.jar:2.2.0.GA]
      	at org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactoryImpl.getTypeInfo(IntrospectionTypeInfoFactoryImpl.java:414) [jboss-reflect.jar:2.2.0.GA]
      	at org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory.getTypeInfo(IntrospectionTypeInfoFactory.java:54) [jboss-reflect.jar:2.2.0.GA]
      	at org.jboss.config.plugins.AbstractConfiguration.getTypeInfo(AbstractConfiguration.java:121) [jboss-reflect.jar:2.2.0.GA]
      	at org.jboss.kernel.plugins.config.AbstractKernelConfig.getTypeInfo(AbstractKernelConfig.java:95) [jboss-kernel.jar:2.2.0.GA]
      	at org.jboss.kernel.plugins.config.AbstractKernelConfigurator.getTypeInfo(AbstractKernelConfigurator.java:102) [jboss-kernel.jar:2.2.0.GA]
      	at org.jboss.scanning.plugins.visitor.ConfiguratorReflectProvider.getTypeInfo(ConfiguratorReflectProvider.java:47) [:1.0.0.GA]
      	at org.jboss.scanning.plugins.visitor.CachingReflectProvider.getTypeInfo(CachingReflectProvider.java:52) [:1.0.0.GA]
      	at org.jboss.scanning.plugins.visitor.ReflectResourceVisitor.getTypeInfo(ReflectResourceVisitor.java:60) [:1.0.0.GA]
      	at org.jboss.scanning.plugins.visitor.ReflectResourceVisitor.getClassInfo(ReflectResourceVisitor.java:72) [:1.0.0.GA]
      	at org.jboss.scanning.plugins.visitor.ReflectResourceVisitor.doVisit(ReflectResourceVisitor.java:107) [:1.0.0.GA]
      	at org.jboss.scanning.plugins.visitor.ReflectResourceVisitor.visit(ReflectResourceVisitor.java:86) [:1.0.0.GA]
      	at org.jboss.scanning.hierarchy.plugins.HierarchyIndexScanningPlugin.visit(HierarchyIndexScanningPlugin.java:91) [:1.0.0.GA]
      	at org.jboss.scanning.spi.helpers.ScanningPluginWrapper.visit(ScanningPluginWrapper.java:112) [:1.0.0.GA]
      	at org.jboss.classloading.plugins.visitor.FederatedResourceVisitor.visit(FederatedResourceVisitor.java:101) [jboss-classloading.jar:2.2.0.GA]
      	at org.jboss.classloading.plugins.vfs.VFSResourceVisitor.visit(VFSResourceVisitor.java:264) [jboss-classloading-vfs.jar:2.2.0.GA]
      	at org.jboss.vfs.VirtualFile.visit(VirtualFile.java:408) [jboss-vfs.jar:3.0.0.GA]
      	at org.jboss.vfs.VirtualFile.visit(VirtualFile.java:410) [jboss-vfs.jar:3.0.0.GA]
      	at org.jboss.vfs.VirtualFile.visit(VirtualFile.java:410) [jboss-vfs.jar:3.0.0.GA]
      	at org.jboss.vfs.VirtualFile.visit(VirtualFile.java:410) [jboss-vfs.jar:3.0.0.GA]
      	at org.jboss.vfs.VirtualFile.visit(VirtualFile.java:396) [jboss-vfs.jar:3.0.0.GA]
      	at org.jboss.classloading.plugins.vfs.VFSResourceVisitor.visit(VFSResourceVisitor.java:102) [jboss-classloading-vfs.jar:2.2.0.GA]
      	at org.jboss.deployers.vfs.plugins.classloader.VFSDeploymentClassLoaderPolicyModule.visit(VFSDeploymentClassLoaderPolicyModule.java:181) [:2.2.0.GA]
      	at org.jboss.scanning.plugins.DeploymentUnitScanner.scan(DeploymentUnitScanner.java:111) [:1.0.0.GA]
      	at org.jboss.scanning.spi.helpers.UrlScanner.scan(UrlScanner.java:96) [:1.0.0.GA]
      	at org.jboss.scanning.deployers.ScanningDeployer.deploy(ScanningDeployer.java:95) [:1.0.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179) [:2.2.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1832) [:2.2.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1550) [:2.2.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1491) [:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:379) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2044) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1083) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1322) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1246) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1139) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:939) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:654) [jboss-dependency.jar:2.2.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployersImpl.change(DeployersImpl.java:1983) [:2.2.0.GA]
      	at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:1076) [:2.2.0.GA]
      	at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:679) [:2.2.0.GA]
      	at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:380) [:6.0.0.Final]
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_23]
      	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [:1.6.0_23]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [:1.6.0_23]
      	at java.lang.reflect.Method.invoke(Unknown Source) [:1.6.0_23]
      	at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157) [:6.0.0.GA]
      	at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96) [:6.0.0.GA]
      	at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) [:6.0.0.GA]
      	at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271) [:6.0.0.GA]
      	at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670) [:6.0.0.GA]
      	at org.jboss.system.server.jmx.MBeanServerWrapper.invoke(MBeanServerWrapper.java:138) [:6.0.0.Final (Build SVNTag:JBoss_6.0.0.Final date: 20101228)]
      	at javax.management.remote.rmi.RMIConnectionImpl.doOperation(Unknown Source) [:1.6.0_23]
      	at javax.management.remote.rmi.RMIConnectionImpl.access$200(Unknown Source) [:1.6.0_23]
      	at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(Unknown Source) [:1.6.0_23]
      	at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(Unknown Source) [:1.6.0_23]
      	at javax.management.remote.rmi.RMIConnectionImpl.invoke(Unknown Source) [:1.6.0_23]
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_23]
      	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [:1.6.0_23]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [:1.6.0_23]
      	at java.lang.reflect.Method.invoke(Unknown Source) [:1.6.0_23]
      	at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source) [:1.6.0_23]
      	at sun.rmi.transport.Transport$1.run(Unknown Source) [:1.6.0_23]
      	at java.security.AccessController.doPrivileged(Native Method) [:1.6.0_23]
      	at sun.rmi.transport.Transport.serviceCall(Unknown Source) [:1.6.0_23]
      	at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source) [:1.6.0_23]
      	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source) [:1.6.0_23]
      	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source) [:1.6.0_23]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) [:1.6.0_23]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [:1.6.0_23]
      	at java.lang.Thread.run(Unknown Source) [:1.6.0_23]
      1. MyAnnotation.java
        0.4 kB
        Cédric Champeau
      2. package-info.class
        0.2 kB
        Cédric Champeau
      3. package-info.java
        0.1 kB
        Cédric Champeau

        Activity

        Nick Williams created issue -
        Guillaume Delcroix made changes -
        Field Original Value New Value
        Assignee Guillaume Laforge [ guillaume ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.7.8 [ 17134 ]
        Resolution Fixed [ 1 ]
        Fix Version/s 1.9-beta-1 [ 17153 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 1.8-rc-1 [ 17132 ]
        Paul King made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Cédric Champeau made changes -
        Attachment MyAnnotation.java [ 53712 ]
        Attachment package-info.class [ 53711 ]
        Attachment package-info.java [ 53710 ]
        Jochen Theodorou made changes -
        Fix Version/s 1.9-beta-1 [ 17153 ]
        Jochen Theodorou made changes -
        Fix Version/s 1.7.8 [ 17134 ]
        Fix Version/s 1.7.9 [ 17164 ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.8-rc-1 [ 17132 ]
        Fix Version/s 1.8-rc-2 [ 17176 ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.8-rc-3 [ 17228 ]
        Fix Version/s 1.8-rc-2 [ 17176 ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.7.9 [ 17164 ]
        Fix Version/s 1.7.10 [ 17229 ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.7.10 [ 17229 ]
        Fix Version/s 1.7.11 [ 17244 ]
        Guillaume Delcroix made changes -
        Fix Version/s 1.8-rc-3 [ 17228 ]
        Fix Version/s 1.8-rc-4 [ 17245 ]
        Jochen Theodorou made changes -
        Fix Version/s 1.8-rc-4 [ 17245 ]
        Fix Version/s 1.8.1 [ 17223 ]
        Graeme Rocher made changes -
        Priority Major [ 3 ] Blocker [ 1 ]
        Paul King made changes -
        Priority Blocker [ 1 ] Major [ 3 ]
        Paul King made changes -
        Resolution Fixed [ 1 ]
        Assignee Guillaume Laforge [ guillaume ] Paul King [ paulk ]
        Status Reopened [ 4 ] Resolved [ 5 ]
        Paul King made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 13:32:57 UTC 2015 [ 1428240777691 ]
        Mark Thomas made changes -
        Workflow jira [ 12733604 ] Default workflow, editable Closed status [ 12745370 ]
        Mark Thomas made changes -
        Project Import Mon Apr 06 02:11:23 UTC 2015 [ 1428286283443 ]
        Mark Thomas made changes -
        Workflow jira [ 12971104 ] Default workflow, editable Closed status [ 12978873 ]

          People

          • Assignee:
            Paul King
            Reporter:
            Nick Williams
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 24h
              24h
              Remaining:
              Remaining Estimate - 24h
              24h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development