• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB-CORBA integration

 
Pedro Erencia
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can an EJB component communicate with a remote corba component without using java-idl ?
 
giuseppe fanuzzi
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the only way a java client can communicates with a corba service, and viceversa, i know is IDL language.
 
Ronald Wouters
Ranch Hand
Posts: 190
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
EJBs use IIOP (well actually RMI-IIOP) for communication purposes.
The IIOP specifies a standardized interoperability protocol for the Internet, providing �out of the box� interoperation with other compatible ORBs ...

The above quote is taken directly from the
CORBA/IIOP 2.3.1 Specification, formal/99-10-07, item 12.1.4 Internet Inter-ORB Protocol (IIOP) on page 365.
I just want to make the point that EJBs are essentially also "corba components" at least when you consider their communication model. For example, when an ejb deployed on a weblogic appserver "calls" another ejb deployed on a jboss or websphere appserver which may be running on a completely different OS then the calling ejb, in essence you have two "corba components" communicating with each other.
Java IDL becomes necessary only when non-java corba components are involved.

Also, if you look in the JDK docs :
http://java.sun.com/javase/6/docs/technotes/guides/idl/corba.html
it says :
CORBA technology is an integral part of the Java 2 platform

[ June 08, 2008: Message edited by: Ronald Wouters ]
 
Pedro Erencia
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Giuseppe and Ronald. I've got it. :roll:
 
giuseppe fanuzzi
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So the only advantage using "rmi over iiop" is that you can built a java remote object (say EJB) without knowing what type of client will use it! right?!
 
Ronald Wouters
Ranch Hand
Posts: 190
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think so. Looking on the same page of the JDK docs mentioned above it also says:
RMI over IIOP was introduced as a standard extension to JDK 1.2. This enabled remote objects written in the Java programming language to be accessible from any language via IIOP.

and also
IIOP eases legacy application and platform integration by allowing application components written in C++, Smalltalk, and other CORBA supported languages to communicate with components running on the Java platform ... clients can be written in other languages using IDL derived from the remote Java technology-based interfaces

However, to get back to the original question of Pedro, which was actually the reverse question, contacting non-java (my italics) corba components from inside an EJB, you would need to generate the class code files for the stubs and skeletons that enable your applications to hook into the ORB. This is done by using the idlj compiler, so I guess in this case IDL is a must... The good part is that it is the provider of the component you want to call from your ejb probably has already created the IDL code which saves you that "trouble" at least and just leaves you with the idjl stuff to figure out, unless you are that provider yourself of course
[ June 08, 2008: Message edited by: Ronald Wouters ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic