简体   繁体   English

如何在jboss 4.2和jboss 6.1中调用EJB3

[英]How to invoke an EJB3 in jboss as 4.2 and jboss as 6.1

we have two ejb3 applications, one in jboss 4.2, the other in jboss 6.1. 我们有两个ejb3应用程序,一个在jboss 4.2中,另一个在jboss 6.1中。

and i want to make a client in tomcat that invoke methods from that applications. 我想在tomcat中创建一个从该应用程序调用方法的客户端。

it is possible to do that? 有可能做到吗? and what jars i have to use ? 我必须使用什么罐子? those from jboss 4.2 client or jboss 6.1? 是来自jboss 4.2客户端还是jboss 6.1?

thanks 谢谢

Yes its possible to do that. 是的,这样做是可能的。 You will need the Remote EJB client jars for whatever EJB you want to call. 无论您要调用什么EJB,都将需要Remote EJB客户端jar。 You do not need any specific JBoss jars, just the client jars. 您不需要任何特定的JBoss jar,仅需要客户端jar。 You will probably need a few CORBA settings set on your InitialContext when you look up the EJB like the IIOP address and port for each EJB: 查找EJB时,可能需要在InitialContext上设置一些CORBA设置,例如每个EJB的IIOP地址和端口:

props.setProperty("org.omg.CORBA.ORBInitialHost", "JBOSS_ADDRESS"); props.setProperty(“ org.omg.CORBA.ORBInitialHost”,“ JBOSS_ADDRESS”); props.setProperty("org.omg.CORBA.ORBInitialPort", "JBOSS_PORT"); props.setProperty(“ org.omg.CORBA.ORBInitialPort”,“ JBOSS_PORT”);

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM