Bug 269887 - SessionBean testing deploy failed on JBoss-5.0.0.GA
Summary: SessionBean testing deploy failed on JBoss-5.0.0.GA
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Nobody - feel free to take it CLA
QA Contact:
URL:
Whiteboard:
Keywords: test
Depends on:
Blocks:
 
Reported: 2009-03-24 16:05 EDT by Kevin Yuan CLA
Modified: 2022-06-09 10:25 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Yuan CLA 2009-03-24 16:05:40 EDT
The sessionbean test suite for JPA testing deploy failed on JBoss-5.0.0.GA with the following exception (the same testing worked fine on JBoss-4.2.x):
2009-03-24 15:26:01,531 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (HDScanner) Error installing to Real: name=vfszip:/C:/EclipseLink/jboss-5.0.0.GA/server/default/deploy/eclipselink-sessionbean-model.ear state=PreReal mode=Manual requiredState=Real
org.jboss.deployers.spi.DeploymentException: Error deploying eclipselink-sessionbean-model_ejb.jar: <injection-target> could not be found: org.eclipse.persistence.testing.models.jpa.sessionbean.EmployeeServiceBean.fieldaccess
	at org.jboss.ejb3.deployers.Ejb3Deployer.deploy(Ejb3Deployer.java:203)
	at org.jboss.ejb3.deployers.Ejb3Deployer.deploy(Ejb3Deployer.java:104)
	at org.jboss.deployers.vfs.spi.deployer.AbstractVFSRealDeployer.internalDeploy(AbstractVFSRealDeployer.java:45)
	at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
	at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1210)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)
	at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
	at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1598)
	at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
	at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
	at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)
	at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:545)
	at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:290)
	at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:221)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: <injection-target> could not be found: org.eclipse.persistence.testing.models.jpa.sessionbean.EmployeeServiceBean.fieldaccess
	at org.jboss.injection.InjectionUtil.findInjectionTarget(InjectionUtil.java:223)
	at org.jboss.injection.InjectionUtil.injectionTarget(InjectionUtil.java:299)
	at org.jboss.injection.PersistenceContextHandler.loadXml(PersistenceContextHandler.java:64)
	at org.jboss.ejb3.EJBContainer.processMetadata(EJBContainer.java:584)
	at org.jboss.ejb3.Ejb3Deployment.processEJBContainerMetadata(Ejb3Deployment.java:415)
	at org.jboss.ejb3.Ejb3Deployment.start(Ejb3Deployment.java:523)
	at org.jboss.ejb3.deployers.Ejb3Deployer.deploy(Ejb3Deployer.java:196)
	... 28 more

Except this test suite, all other JPA test suites worked fine on JBoss-5.0.0.GA, got same test results as JBoss-4.2.x.
Comment 1 Kevin Yuan CLA 2009-08-26 11:03:46 EDT
There is some info: http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4162427#4162427
Comment 2 Kevin Yuan CLA 2009-08-27 15:05:55 EDT
Based on the document for @PersistenceContext reference here http://www.oracle.com/technology/products/ias/toplink/jpa/resources/toplink-jpa-annotations.html#PersistenceContext .

Should be using unitName attribute and not the name attribute in org.eclipse.persistence.testing.models.jpa.sessionbean.EmployeeServiceBean.java, in this case. So the bean should be changed to: 
    @PersistenceContext(unitName="sessionbean")

By the way, the PU name should be sessionbean, not fieldaccess.

Code reviewed by Yiping Zhao.
Checked in EclipseLink 2.0   (revision: 4994)
                       1.2   (revision: 4996)
                       1.1.3 (revision: 4995)

Comment 3 Eclipse Webmaster CLA 2022-06-09 10:25:48 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink