Hi Peter,
File a bug in packaging (the base class of FileDirContext class did
change a non-static variable to a static (see
http://stackoverflow.com/questions/1980452/what-causes-java-lang-incompatibleclasschangeerror
for IncompatibleClassChangeError explanation), but somebody needs to
look at why the subclass wasn't recompiled when building the -all.jar.
thanks,
-marina
Major Péter wrote:
> Hi Marina,
>
> My classpath looks like this:
> /home/aldaris/NetBeansProjects/korok/sch-pek-ejb-impl/target/test-classes:/home/aldaris/NetBeansProjects/korok/sch-pek-ejb-impl/target/classes:/home/aldaris/NetBeansProjects/korok/sch-pek-domain/target/classes:/home/aldaris/NetBeansProjects/korok/sch-pek-ejb-services/target/classes:/home/aldaris/NetBeansProjects/korok/sch-pek-test/target/classes:/home/aldaris/.m2/repository/log4j/log4j/1.2.14/log4j-1.2.14.jar:/home/aldaris/.m2/repository/javax/mail/mail/1.4.3/mail-1.4.3.jar:/home/aldaris/.m2/repository/javax/activation/activation/1.1/activation-1.1.jar:/home/aldaris/.m2/repository/org/springframework/ldap/spring-ldap-core/1.3.0.RELEASE/spring-ldap-core-1.3.0.RELEASE.jar:/home/aldaris/.m2/repository/commons-logging/commons-logging/1.0.4/commons-logging-1.0.4.jar:/home/aldaris/.m2/repository/commons-lang/commons-lang/2.1/commons-lang-2.1.jar:/home/aldaris/.m2/repository/org/springframework/spring-core/2.5.6/spring-core-2.5.6.jar:/home/aldaris/.m2/repository/org/springframework/
> spring-beans/2.5.6/spring-beans-2.5.6.jar:/home/aldaris/.m2/repository/org/springframework/spring-tx/2.5.6/spring-tx-2.5.6.jar:/home/aldaris/.m2/repository/org/springframework/spring-context/2.5.6/spring-context-2.5.6.jar:/home/aldaris/.m2/repository/aopalliance/aopalliance/1.0/aopalliance-1.0.jar:/home/aldaris/.m2/repository/junit/junit/4.7/junit-4.7.jar:/home/aldaris/.m2/repository/org/glassfish/extras/glassfish-embedded-all/3.1-SNAPSHOT/glassfish-embedded-all-3.1-SNAPSHOT.jar:/home/aldaris/.m2/repository/org/hibernate/hibernate-core/3.5.0-Final/hibernate-core-3.5.0-Final.jar:/home/aldaris/.m2/repository/antlr/antlr/2.7.6/antlr-2.7.6.jar:/home/aldaris/.m2/repository/commons-collections/commons-collections/3.1/commons-collections-3.1.jar:/home/aldaris/.m2/repository/dom4j/dom4j/1.6.1/dom4j-1.6.1.jar:/home/aldaris/.m2/repository/xml-apis/xml-apis/1.0.b2/xml-apis-1.0.b2.jar:/home/aldaris/.m2/repository/javax/transaction/jta/1.1/jta-1.1.jar:/home/aldaris/.m2/repository/org/slf4
> j/slf4j-api/1.5.8/slf4j-api-1.5.8.jar:/home/aldaris/.m2/repository/javax/javaee-api/6.0/javaee-api-6.0.jar:/home/aldaris/.m2/repository/org/hibernate/hibernate-entitymanager/3.5.0-Final/hibernate-entitymanager-3.5.0-Final.jar:/home/aldaris/.m2/repository/org/hibernate/hibernate-annotations/3.5.0-Final/hibernate-annotations-3.5.0-Final.jar:/home/aldaris/.m2/repository/org/hibernate/hibernate-commons-annotations/3.2.0.Final/hibernate-commons-annotations-3.2.0.Final.jar:/home/aldaris/.m2/repository/org/hibernate/javax/persistence/hibernate-jpa-2.0-api/1.0.0.Final/hibernate-jpa-2.0-api-1.0.0.Final.jar:/home/aldaris/.m2/repository/cglib/cglib/2.2/cglib-2.2.jar:/home/aldaris/.m2/repository/asm/asm/3.1/asm-3.1.jar:/home/aldaris/.m2/repository/javassist/javassist/3.9.0.GA/javassist-3.9.0.GA.jar:
>
> So there is no webapplication involved at all (at least not mine, that's
> for sure).
> Also I'm using this:
> properties.put(EJBContainer.MODULES, new
> File("../sch-pek-ejb-impl/target/classes"));
>
> so the damn thing SHOULD have find my EJB's.
> Currently I stepped few svnrev's back in GF repo and made an own jar,
> and I'm using that (almost) without problem.
>
> Regards,
> Peter
>
> 2010-08-11 05:04 keltezéssel, Marina Vatkina írta:
>
>> Hi Peter,
>>
>> What does your classpath contain? The exception comes from the
>> web-naming package that should not be used by EJBs...
>>
>> thanks,
>> -marina
>>
>> Major Péter wrote:
>>
>>> Hi Marina,
>>>
>>> I've turned up the logging level to FINER, and I got the same exception
>>> as on the other machine:
>>> .EjbDeployer load method
>>> java.lang.RuntimeException: EJB Container initialization error
>>> at
>>> org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:232)
>>>
>>> at
>>> org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:245)
>>> at
>>> org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:92)
>>> at
>>> org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:172)
>>> at
>>> org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:234)
>>>
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:363)
>>>
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:204)
>>>
>>> at
>>> org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:189)
>>>
>>> at
>>> org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:138)
>>>
>>> at
>>> org.glassfish.ejb.embedded.EJBContainerImpl.deploy(EJBContainerImpl.java:133)
>>>
>>> at
>>> org.glassfish.ejb.embedded.EJBContainerProviderImpl.createEJBContainer(EJBContainerProviderImpl.java:124)
>>>
>>> at
>>> javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:116)
>>>
>>> at
>>> hu.sch.test.base.ContainerHolder.fireUpEJBContainer(ContainerHolder.java:56)
>>>
>>> at
>>> hu.sch.test.base.ContainerAwareAbstractTest.setup(ContainerAwareAbstractTest.java:46)
>>>
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:597)
>>> at
>>> org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
>>>
>>> at
>>> org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
>>>
>>> at
>>> org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
>>>
>>> at
>>> org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
>>>
>>> at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
>>> at
>>> org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
>>>
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140)
>>>
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127)
>>>
>>> at org.apache.maven.surefire.Surefire.run(Surefire.java:177)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>
>>> at java.lang.reflect.Method.invoke(Method.java:597)
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345)
>>>
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009)
>>>
>>> Caused by: java.lang.IncompatibleClassChangeError: Expected non-static
>>> field org.apache.naming.resources.FileDirContext.sm
>>> at
>>> org.apache.naming.resources.FileDirContext.file(FileDirContext.java:955)
>>> at
>>> org.apache.naming.resources.FileDirContext.file(FileDirContext.java:870)
>>> at
>>> org.apache.naming.resources.FileDirContext.lookup(FileDirContext.java:280)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.findResourceInternalFromRepositories(WebappClassLoader.java:2109)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.findResourceInternal(WebappClassLoader.java:2064)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1956)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.findClass(WebappClassLoader.java:895)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1465)
>>>
>>> at
>>> org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1348)
>>>
>>> at java.lang.Class.forName0(Native Method)
>>> at java.lang.Class.forName(Class.java:247)
>>> at java.lang.Package.getPackageInfo(Package.java:352)
>>> at java.lang.Package.getAnnotations(Package.java:383)
>>> at
>>> org.glassfish.apf.impl.AnnotationProcessorImpl.processAnnotations(AnnotationProcessorImpl.java:281)
>>>
>>> at
>>> org.glassfish.apf.impl.AnnotationProcessorImpl.processAnnotations(AnnotationProcessorImpl.java:267)
>>>
>>> at
>>> org.glassfish.apf.impl.AnnotationProcessorImpl.process(AnnotationProcessorImpl.java:167)
>>>
>>> at
>>> org.glassfish.apf.impl.AnnotationProcessorImpl.process(AnnotationProcessorImpl.java:130)
>>>
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.processAnnotations(Archivist.java:607)
>>>
>>> at
>>> org.glassfish.web.embed.impl.EmbeddedWebArchivist.processAnnotations(EmbeddedWebArchivist.java:123)
>>>
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readAnnotations(Archivist.java:456)
>>>
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readAnnotations(Archivist.java:443)
>>>
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readRestDeploymentDescriptors(Archivist.java:419)
>>>
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readDeploymentDescriptors(Archivist.java:394)
>>>
>>>
>>> probably just the two server had two different logging configuration.
>>>
>>> Any hint on this?
>>>
>>> Thanks,
>>> Peter
>>>
>>> 2010-08-11 00:47 keltezéssel, Marina Vatkina írta:
>>>
>>>
>>>> Hi Peter,
>>>>
>>>> The second error means that something went wrong during
>>>> createEJBContainer() call. Look in the output log for more details.
>>>>
>>>> -marina
>>>>
>>>> Major Péter wrote:
>>>>
>>>>
>>>>> Hi,
>>>>>
>>>>> I've just tried to run some tests with glassfish-embedded-all
>>>>> 3.1-SNAPSHOT, but it's failing on one machine with this message:
>>>>> Skipping
>>>>> reparsing...file:/path/to/workspace/sch-pek-ejb-impl/../sch-pek-ejb-impl/target/classes/
>>>>>
>>>>>
>>>>> [#|2010-08-07T22:59:54.213+0200|WARNING|glassfish3.1|javax.enterprise.system.core.org.glassfish.kernel.event|_ThreadID=1;_ThreadName=main;|Exception
>>>>>
>>>>>
>>>>> while dispatching an event
>>>>> java.lang.IncompatibleClassChangeError: Expected non-static field
>>>>> org.apache.naming.resources.FileDirContext.sm
>>>>> at
>>>>> org.apache.naming.resources.FileDirContext.file(FileDirContext.java:955)
>>>>>
>>>>>
>>>>>
>>>>> and on another with this:
>>>>> javax.ejb.EJBException: No EJBContainer provider available
>>>>> The following providers:
>>>>> org.glassfish.ejb.embedded.EJBContainerProviderImpl
>>>>> Returned null from createEJBContainer call.
>>>>> at
>>>>> javax.ejb.embeddable.EJBContainer.reportError(EJBContainer.java:200)
>>>>> at
>>>>> javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:135)
>>>>>
>>>>>
>>>>>
>>>>> Are these known issues? Don't you want to create separate (stable)
>>>>> builds instead of this nightly ones? It's really hard to test (timers
>>>>> for example), when there is no fallback if the nightly is buggy...
>>>>>
>>>>> Thanks,
>>>>> Peter
>>>>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>