[EJB 3.0] - Injecting EJB2 entity homes into EJB3 beans
by gcoleman
Should I be able to inject EJB2 homes into EJB3 beans?. This used to work on 5.0.0.Beta4 but doesn't with the latest 5.0.0 HEAD build - I'm trying to upgrade due to a problem with JBossWebRealm (fixed in r69776).
I've got an EJB3 SLSB declared using annotations. I'm injecting an EJB2 entity home into it using ejb-jar.xml:
| @Stateless(name = "TaskManager")
| @Local(TaskManager.class)
| @TransactionAttribute(REQUIRED)
| public class TaskManagerBean implements TaskManager
| {
| protected ScheduledTaskHome scheduledTaskHome;
| ...
| }
|
| <session>
| <ejb-name>TaskManager</ejb-name>
| <ejb-local-ref>
| <ejb-ref-name>ejb/ScheduledTaskHome</ejb-ref-name>
| <ejb-ref-type>Entity</ejb-ref-type>
| <local-home>util.timer.ScheduledTaskHome</local-home>
| <local>util.timer.ScheduledTask</local>
| <ejb-link>ScheduledTask</ejb-link>
| <injection-target>
| <injection-target-class>util.timer.TaskManagerBean</injection-target-class>
| <injection-target-name>scheduledTaskHome</injection-target-name>
| </injection-target>
| </ejb-local-ref>
| </session>
|
The ScheduledTask entity deployed without any errors. The problem appears to be the SLSB thinks that the entity dependency is EJB3:
| 08:24:41,721 ERROR [ProfileServiceBootstrap] [main] Failed to load profile: Summary of incomplete de
| ployments (SEE PREVIOUS ERRORS FOR DETAILS):
|
| *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual State}
|
| jboss.j2ee:ear=app.ear,jar=server-utils-ejbs.jar,name=TaskManager,service=EJB3
| -> <UNKNOWN>{Described:** UNRESOLVED Demands 'jboss.ejb:service=EJBTimerService **}
| -> <UNKNOWN>{Described:** UNRESOLVED Demands 'jboss.j2ee:ear=app.ear,name=ScheduledTask,servic
| e=EJB3,* **}
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4140802#4140802
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4140802
18 years
[Tomcat, HTTPD, Servlets & JSP] - Deployment failure
by Jono99
I am doing a jsp website and upon deployment of the project it gives me the following error:
--- Incompletely deployed packages ---
org.jboss.deployment.DeploymentInfo@7bc064c4 { url=file:/D:/jboss-4.2.1.GA/server/default/deploy/Venturecap.war }
deployer: MBeanProxyExt[jboss.web:service=WebServer]
status: Deployment FAILED reason: URL file:/D:/jboss-4.2.1.GA/server/default/tmp/deploy/tmp63203Venturecap-exp.war/ deployment failed
state: FAILED
watch: file:/D:/jboss-4.2.1.GA/server/default/deploy/Venturecap.war
altDD: null
lastDeployed: 1207118532062
lastModified: 1207118532046
mbeans:
--- MBeans waiting for other MBeans ---
ObjectName: jboss.web.deployment:war=Venturecap.war,id=2076206276
State: FAILED
Reason: org.jboss.deployment.DeploymentException: URL file:/D:/jboss-4.2.1.GA/server/default/tmp/deploy/tmp63203Venturecap-exp.war/ deployment failed
--- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
ObjectName: jboss.web.deployment:war=Venturecap.war,id=2076206276
State: FAILED
Reason: org.jboss.deployment.DeploymentException: URL file:/D:/jboss-4.2.1.GA/server/default/tmp/deploy/tmp63203Venturecap-exp.war/ deployment failed
There is more error details on it but i thought to just give this so long.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4140801#4140801
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4140801
18 years