[JBoss JIRA] Created: (CDITCK-153) TCK Test FAilure: IllegalStateException: Unable to convert ejbRef
by Roger Kitain (JIRA)
TCK Test FAilure: IllegalStateException: Unable to convert ejbRef
-----------------------------------------------------------------
Key: CDITCK-153
URL: https://jira.jboss.org/jira/browse/CDITCK-153
Project: CDI TCK
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Tests
Affects Versions: 1.0.1.Final
Environment: GlassFish v3.0.1
Reporter: Roger Kitain
TEST NAME: org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.testNonStaticProducerMethodInheritedBySpecializingSubclass
TEST LOG:
[testng] -deploy:
[testng] [gf.echo] Deploying: /var/folders/8T/8TkU3CL-FMec7iJWxn8tg++++TI/-Tmp-/org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.ear
[testng] [gf.echo] 0 archive(s) to undeploy
[testng] [gf.echo] 1 archive(s) to deploy
[testng] [copy] Copying 1 file to /Users/rogerk/weld/tck/glassfishv3/glassfish/domains/domain1/autodeploy
[testng] [gf.echo] Deploying archive: /var/folders/8T/8TkU3CL-FMec7iJWxn8tg++++TI/-Tmp-/org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.ear
[testng] [gf.echo] Deployment Succeeded: org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.ear
[testng] java.lang.IllegalStateException: Unable to convert ejbRef for ejb AndalusianChicken to a business object of type interface org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.ChickenLocal
[testng] at com.sun.ejb.containers.EjbContainerServicesImpl.getBusinessObject(EjbContainerServicesImpl.java:104)
[testng] at org.glassfish.weld.ejb.SessionObjectReferenceImpl.getBusinessObject(SessionObjectReferenceImpl.java:60)
[testng] at org.jboss.weld.bean.proxy.EnterpriseBeanProxyMethodHandler.invoke(EnterpriseBeanProxyMethodHandler.java:123)
[testng] at org.jboss.weld.util.CleanableMethodHandler.invoke(CleanableMethodHandler.java:43)
[testng] at org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.AndalusianChickenLocal_$$_javassist_401.produceEgg(AndalusianChickenLocal_$$_javassist_401.java)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[testng] at java.lang.reflect.Method.invoke(Method.java:597)
[testng] at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:304)
[testng] at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
[testng] at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
[testng] at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:298)
[testng] at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:200)
[testng] at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstance(MethodInjectionPoint.java:164)
[testng] at org.jboss.weld.bean.ProducerMethod$1.produce(ProducerMethod.java:143)
[testng] at org.jboss.weld.bean.AbstractProducerBean.create(AbstractProducerBean.java:360)
[testng] at org.jboss.weld.context.DependentContext.get(DependentContext.java:62)
[testng] at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:709)
[testng] at org.jboss.weld.manager.BeanManagerImpl.getReference(BeanManagerImpl.java:735)
[testng] at org.jboss.jsr299.tck.impl.OldSPIBridge.getInstanceByType(OldSPIBridge.java:42)
[testng] at org.jboss.jsr299.tck.AbstractJSR299Test.getInstanceByType(AbstractJSR299Test.java:160)
[testng] at org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.testNonStaticProducerMethodInheritedBySpecializingSubclass(EnterpriseProducerMethodDefinitionTest.java:46)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[testng] at java.lang.reflect.Method.invoke(Method.java:597)
[testng] at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:609)
[testng] at org.testng.internal.MethodHelper$1.runTestMethod(MethodHelper.java:727)
[testng] at org.jboss.testharness.AbstractTest.run(AbstractTest.java:244)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[testng] at java.lang.reflect.Method.invoke(Method.java:597)
[testng] at org.testng.internal.MethodHelper.invokeHookable(MethodHelper.java:735)
[testng] at org.testng.internal.Invoker.invokeMethod(Invoker.java:525)
[testng] at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:686)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1018)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:128)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:112)
[testng] at org.testng.TestRunner.runWorkers(TestRunner.java:759)
[testng] at org.testng.TestRunner.privateRun(TestRunner.java:592)
[testng] at org.testng.TestRunner.run(TestRunner.java:486)
[testng] at org.testng.SuiteRunner.runTest(SuiteRunner.java:332)
[testng] at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:327)
[testng] at org.testng.SuiteRunner.privateRun(SuiteRunner.java:299)
[testng] at org.testng.SuiteRunner.run(SuiteRunner.java:204)
[testng] at org.testng.TestNG.createAndRunSuiteRunners(TestNG.java:912)
[testng] at org.testng.TestNG.runSuitesLocally(TestNG.java:876)
[testng] at org.testng.TestNG.run(TestNG.java:784)
[testng] at org.jboss.testharness.impl.runner.TestRunner.run(TestRunner.java:61)
[testng] at org.jboss.testharness.impl.runner.servlet.ServletTestRunner.doGet(ServletTestRunner.java:120)
[testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:734)
[testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
[testng] at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1523)
[testng] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:279)
[testng] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:188)
[testng] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:641)
[testng] at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:97)
[testng] at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:85)
[testng] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:185)
[testng] at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:332)
[testng] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:233)
[testng] at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:165)
[testng] at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791)
[testng] at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693)
[testng] at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954)
[testng] at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170)
[testng] at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135)
[testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102)
[testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88)
[testng] at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76)
[testng] at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53)
[testng] at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57)
[testng] at com.sun.grizzly.ContextTask.run(ContextTask.java:69)
[testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330)
[testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309)
[testng] at java.lang.Thread.run(Thread.java:637)
[testng] ********************************************************************
[testng] FINISHED TEST: FAILED........org.jboss.jsr299.tck.tests.implementation.producer.method.definition.enterprise.EnterpriseProducerMethodDefinitionTest.testNonStaticProducerMethodInheritedBySpecializingSubclass
[testng] ********************************************************************
Comment History For This Issue:
Daniel Joyce - 04/May/10 12:37 PM
So I guess the fix for WELD-381 in 1.0.1 didn't fix this. I realized this when I downloaded Glassfish 3.0.1 which uses the latest weld, and this error still occurs.
I still get java.lang.IllegalStateException: Unable to convert ejbRef for ejb. Apparently weld can't handle generic super classes when resolving references.
Pete Muir - 05/May/10 07:13 AM
This is a different issue to WELD-381.
Pete Muir - 05/May/10 07:17 AM
Roger, exactly what issue are you reporting here?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 7 months
[JBoss JIRA] Created: (CDITCK-150) TCK Test Failure: IllegalArg Exceptions - Invalid Ejb Jar
by Roger Kitain (JIRA)
TCK Test Failure: IllegalArg Exceptions - Invalid Ejb Jar
----------------------------------------------------------
Key: CDITCK-150
URL: https://jira.jboss.org/jira/browse/CDITCK-150
Project: CDI TCK
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Tests
Affects Versions: 1.0.1.Final
Environment: GlassFish v3.0.1
Reporter: Roger Kitain
Tck test failure:
TEST NAME: org.jboss.jsr299.tck.tests.deployment.packaging.bundledLibrary.LibraryInEarTest.test
SERVER LOG:
[#|2010-04-30T13:01:54.654-0400|SEVERE|glassfish3.0|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=24;_ThreadName=AutoDeployer;|Exception while deploying the app
java.lang.IllegalArgumentException: Invalid ejb jar [org.jboss.jsr299.tck.tests.deployment.packaging.bundledLibrary.LibraryInEarTest.jar]: it contains zero ejb.
Note:
1. A valid ejb jar requires at least one session, entity (1.x/2.x style), or message-driven bean.
2. EJB3+ entity beans (@Entity) are POJOs and please package them as library jar.
3. If the jar file contains valid EJBs which are annotated with EJB component level annotations (@Stateless, @Stateful, @MessageDriven, @Singleton), please check server.log to see whether the annotations were processed properly.
at com.sun.enterprise.deployment.util.EjbBundleValidator.accept(EjbBundleValidator.java:72)
at com.sun.enterprise.deployment.util.ApplicationValidator.accept(ApplicationValidator.java:124)
at com.sun.enterprise.deployment.EjbBundleDescriptor.visit(EjbBundleDescriptor.java:722)
at com.sun.enterprise.deployment.Application.visit(Application.java:1744)
at com.sun.enterprise.deployment.archivist.ApplicationArchivist.validate(ApplicationArchivist.java:774)
at com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:253)
at com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:222)
at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:152)
at org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:79)
at com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:612)
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:554)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:262)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:183)
at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:272)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:310)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:320)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1176)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$900(CommandRunnerImpl.java:83)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
at org.glassfish.deployment.autodeploy.AutoOperation.run(AutoOperation.java:141)
at org.glassfish.deployment.autodeploy.AutoDeployer.deploy(AutoDeployer.java:573)
at org.glassfish.deployment.autodeploy.AutoDeployer.deployAll(AutoDeployer.java:459)
at org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:391)
at org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:376)
at org.glassfish.deployment.autodeploy.AutoDeployService$1.run(AutoDeployService.java:195)
at java.util.TimerThread.mainLoop(Timer.java:512)
at java.util.TimerThread.run(Timer.java:462)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 7 months
[JBoss JIRA] Created: (CDITCK-119) Documentation issues
by Jozef Hartinger (JIRA)
Documentation issues
--------------------
Key: CDITCK-119
URL: https://jira.jboss.org/jira/browse/CDITCK-119
Project: CDI TCK
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Documentation
Affects Versions: 1.0.1.GA
Reporter: Jozef Hartinger
Despite the fact that CDITCK-54 has been closed, some of issues reported there are still present in the CDI-TCK 1.0.1 documentation
- JBoss Test Harness version 1.0.0 - should be 1.1.0-CR5
- TestNG 5.9 - it is actually 5.10
- Part III - a reference to JBoss Test Harness documentation is missing - there is a "TODO" placeholder
- in-container-execution.png is not displayed in the section 10.1. Negotiating the execution of an in-container test
- Table "12.1. Weld JBoss TCK Runner Dependencies" is outdated and should perhaps be removed
- statement "You can find all of these artifacts in the JBoss Maven repository." is not true since they are published to sonatype
- section 2.4 references legacy https://jira.jboss.org/jira/browse/WBTCK instead of https://jira.jboss.org/jira/browse/CDITCK
- update JBoss AS version globally (JBoss AS 5.2 is mentioned somewhere while JBoss AS 6.0.0.M1 somewhere else)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 7 months
[JBoss JIRA] Created: (CDITCK-161) Test Fails With IllegalAccessError:org.jboss.jsr299.tck.tests.implementation.enterprise.definition.EnterpriseBeanDefinitionTest.testConstructorAnnotatedInjectCalled
by Roger Kitain (JIRA)
Test Fails With IllegalAccessError:org.jboss.jsr299.tck.tests.implementation.enterprise.definition.EnterpriseBeanDefinitionTest.testConstructorAnnotatedInjectCalled
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
Key: CDITCK-161
URL: https://jira.jboss.org/browse/CDITCK-161
Project: CDI TCK
Issue Type: Bug
Security Level: Public (Everyone can see)
Environment: GlassFish v3.0.1
Reporter: Roger Kitain
org.jboss.jsr299.tck.tests.implementation.enterprise.definition.EnterpriseBeanDefinitionTest.testConstructorAnnotatedInjectCalled fails with:
[testng] java.lang.IllegalAccessError: tried to access class org.jboss.jsr299.tck.tests.implementation.enterprise.definition.SimpleBean from class $Proxy150
>>> [testng] at $Proxy150.getInjectedSimpleBean(Unknown Source)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>> [testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>> [testng] at java.lang.reflect.Method.invoke(Method.java:597)
>>> [testng] at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:304)
>>> [testng] at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
>>> [testng] at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
>>> [testng] at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:298)
>>> [testng] at org.jboss.weld.bean.proxy.EnterpriseBeanProxyMethodHandler.invoke(EnterpriseBeanProxyMethodHandler.java:127)
>>> [testng] at org.jboss.weld.util.CleanableMethodHandler.invoke(CleanableMethodHandler.java:43)
>>> [testng] at org.jboss.jsr299.tck.tests.implementation.enterprise.definition.ExplicitConstructor_$$_javassist_13.getInjectedSimpleBean(ExplicitConstructor_$$_javassist_13.java)
>>> [testng] at org.jboss.jsr299.tck.tests.implementation.enterprise.definition.EnterpriseBeanDefinitionTest.testConstructorAnnotatedInjectCalled(EnterpriseBeanDefinitionTest.java:63)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>> [testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>> [testng] at java.lang.reflect.Method.invoke(Method.java:597)
>>> [testng] at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:609)
>>> [testng] at org.testng.internal.MethodHelper$1.runTestMethod(MethodHelper.java:727)
>>> [testng] at org.jboss.testharness.AbstractTest.run(AbstractTest.java:244)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> [testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>> [testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>> [testng] at java.lang.reflect.Method.invoke(Method.java:597)
>>> [testng] at org.testng.internal.MethodHelper.invokeHookable(MethodHelper.java:735)
>>> [testng] at org.testng.internal.Invoker.invokeMethod(Invoker.java:525)
>>> [testng] at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:686)
>>> [testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1018)
>>> [testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:128)
>>> [testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:112)
>>> [testng] at org.testng.TestRunner.runWorkers(TestRunner.java:759)
>>> [testng] at org.testng.TestRunner.privateRun(TestRunner.java:592)
>>> [testng] at org.testng.TestRunner.run(TestRunner.java:486)
>>> [testng] at org.testng.SuiteRunner.runTest(SuiteRunner.java:332)
>>> [testng] at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:327)
>>> [testng] at org.testng.SuiteRunner.privateRun(SuiteRunner.java:299)
>>> [testng] at org.testng.SuiteRunner.run(SuiteRunner.java:204)
>>> [testng] at org.testng.TestNG.createAndRunSuiteRunners(TestNG.java:912)
>>> [testng] at org.testng.TestNG.runSuitesLocally(TestNG.java:876)
>>> [testng] at org.testng.TestNG.run(TestNG.java:784)
>>> [testng] at org.jboss.testharness.impl.runner.TestRunner.run(TestRunner.java:61)
>>> [testng] at org.jboss.testharness.impl.runner.servlet.ServletTestRunner.doGet(ServletTestRunner.java:120)
>>> [testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:734)
>>> [testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
>>> [testng] at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1523)
>>> [testng] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:279)
>>> [testng] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:188)
>>> [testng] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:641)
>>> [testng] at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:97)
>>> [testng] at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:85)
>>> [testng] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:185)
>>> [testng] at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:332)
>>> [testng] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:233)
>>> [testng] at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:165)
>>> [testng] at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791)
>>> [testng] at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693)
>>> [testng] at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954)
>>> [testng] at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170)
>>> [testng] at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135)
>>> [testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102)
>>> [testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88)
>>> [testng] at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76)
>>> [testng] at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53)
>>> [testng] at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57)
>>> [testng] at com.sun.grizzly.ContextTask.run(ContextTask.java:69)
>>> [testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330)
>>> [testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309)
>>> [testng] at java.lang.Thread.run(Thread.java:637)
===========================
> Am Dienstag, den 18.05.2010, 14:07 +0100 schrieb Pete Muir:
>> >> Upon some quick investigation, the problem is that:
>> >>
>> >> * SimpleBean is package protected
>> >> * SimpleBean, the Test and the ExplicitConstructor & it's bean are in the same package
>> >> * the proxy isn't, thus trying to access SimpleBean via it causes this error (I think, not 100% on this)
> >
> > Yes, this appears to be an EJB proxy in GF?
Yes, it's a Java dynamic proxy used by the container to implement an EJB reference for the Local business view of the bean. I found the JDK issue filed for this as of JDK 1.5 , still not addressed : http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6256803. The root cause is that the java.lang.reflect.Proxy javadoc says the package of a dynamic proxy for a public interface is undefined. In SUN's JDK the actual package assigned to the package at runtime is 'null', so the proxy gets an IllegalAccessError when attempting to access SimpleBean, which is package private.
The first thing to note is this has nothing to do with the fix to support constructor injection on EJB bean classes. It's pretty easy to reproduce the IllegalAccessError on an unrelated app. Unfortunately the constructor injection fix revealed issues in the only two WELD TCK tests that exercise EJB constructor injection, this being one of them. There's obviously no requirement that the EJB container use JDK dynamic proxies to implement EJB reference objects but it's unrealistic for that strategy to change at this stage and for this issue. The JDK bug evaluator's note makes the point that it's generally bad practice for a public interface to depend on non-public types.
Seems like the best two options are to either modify the test to make SimpleBean a public class or exclude the test. Thoughts?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 7 months
[JBoss JIRA] Created: (CDITCK-160) NewEnterpriseBeanICTest.testNewBeanHasSameConstructor() assumes new instance creation
by Ken Saks (JIRA)
NewEnterpriseBeanICTest.testNewBeanHasSameConstructor() assumes new instance creation
-------------------------------------------------------------------------------------
Key: CDITCK-160
URL: https://jira.jboss.org/browse/CDITCK-160
Project: CDI TCK
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Tests
Affects Versions: 1.0.1.Final
Environment: run against GlassFish v3.0.1 intermediate build
Reporter: Ken Saks
I'm working on supporting EJB constructor injection for GlassFish v3.0.1(https://glassfish.dev.java.net/issues/show_bug.cgi?id=11180) but I'm seeing a failure in NewEnterpriseBeanICTest.testNewBeanHasSameConstructor(NewEnterpriseBeanICTest, line 49. I can confirm that the Stateless Session bean class one-arg constructor is being invoked as a result of the InjectionTarget.produce() operation, but I don't understand the assumption the test client is making.
The test client accesses the bean through a reference, then calls a bean method that resets a static field counting the number of constructor calls for that bean class. It then calls getInstanceByType() and assumes that the constructor count has been incremented as a result of a new bean instance creation. The pooling strategy of the container might mean an existing bean instance is reused. In that case, the constructor will not be called a second time and the test assertion will fail.
34 @Artifact
35 @Packaging(PackagingType.EAR)
36 @IntegrationTest
37 @SpecVersion(spec="cdi", version="20091101")
38 public class NewEnterpriseBeanICTest extends AbstractJSR299Test
39 {
40
41 @Test(groups = { "new" })
42 @SpecAssertion(section = "3.12", id = "l")
43 public void testNewBeanHasSameConstructor()
44 {
45 ExplicitConstructor bean = getInstanceByType(ExplicitConstructor.class);
46 bean.setConstructorCalls(0);
47 ExplicitConstructor newBean = getInstanceByType(ExplicitConstructor.class, ExplicitConstructorSessionBean.NEW);
48 assert bean != newBean;
49 assert bean.getConstructorCalls() == 1;
50 assert bean.getInjectedSimpleBean() != null;
51 }
[testng] java.lang.AssertionError
[testng] at org.jboss.jsr299.tck.tests.implementation.enterprise.newBean.NewEnterpriseBeanICTest.testNewBeanHasSameConstructor(NewEnterpriseBeanICTest.java:49)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[testng] at java.lang.reflect.Method.invoke(Method.java:597)
[testng] at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:609)
[testng] at org.testng.internal.MethodHelper$1.runTestMethod(MethodHelper.java:727)
[testng] at org.jboss.testharness.AbstractTest.run(AbstractTest.java:244)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[testng] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[testng] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[testng] at java.lang.reflect.Method.invoke(Method.java:597)
[testng] at org.testng.internal.MethodHelper.invokeHookable(MethodHelper.java:735)
[testng] at org.testng.internal.Invoker.invokeMethod(Invoker.java:525)
[testng] at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:686)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1018)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:128)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:112)
[testng] at org.testng.TestRunner.runWorkers(TestRunner.java:759)
[testng] at org.testng.TestRunner.privateRun(TestRunner.java:592)
[testng] at org.testng.TestRunner.run(TestRunner.java:486)
[testng] at org.testng.SuiteRunner.runTest(SuiteRunner.java:332)
[testng] at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:327)
[testng] at org.testng.SuiteRunner.privateRun(SuiteRunner.java:299)
[testng] at org.testng.SuiteRunner.run(SuiteRunner.java:204)
[testng] at org.testng.TestNG.createAndRunSuiteRunners(TestNG.java:912)
[testng] at org.testng.TestNG.runSuitesLocally(TestNG.java:876)
[testng] at org.testng.TestNG.run(TestNG.java:784)
[testng] at org.jboss.testharness.impl.runner.TestRunner.run(TestRunner.java:61)
[testng] at org.jboss.testharness.impl.runner.servlet.ServletTestRunner.doGet(ServletTestRunner.java:120)
[testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:734)
[testng] at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
[testng] at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1523)
[testng] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:279)
[testng] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:188)
[testng] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:641)
[testng] at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:97)
[testng] at com.sun.enterprise.web.PESessionLockingStandardPipeline.invoke(PESessionLockingStandardPipeline.java:85)
[testng] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:185)
[testng] at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:332)
[testng] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:233)
[testng] at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:165)
[testng] at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:791)
[testng] at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:693)
[testng] at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:954)
[testng] at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:170)
[testng] at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:135)
[testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:102)
[testng] at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:88)
[testng] at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:76)
[testng] at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:53)
[testng] at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:57)
[testng] at com.sun.grizzly.ContextTask.run(ContextTask.java:69)
[testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:330)
[testng] at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:309)
[testng] at java.lang.Thread.run(Thread.java:637)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 7 months