25.02.2013 Views

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

TCP/IP Tutorial and Technical Overview - IBM Redbooks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

HTTP-Based<br />

Client<br />

Java<br />

Application<br />

HTTP<br />

Figure 16-5 The Enterprise JavaBeans environment<br />

Remote Method Invocation (RMI)<br />

RMI is a st<strong>and</strong>ard protocol for communication between Java objects residing on<br />

different computers. RMI provides a way for client <strong>and</strong> server applications to<br />

invoke methods across a distributed network of clients <strong>and</strong> servers running the<br />

JVM. You can invoke methods on the remote RMI object as you do on a local<br />

Java object. RMI is cross-platform, but not cross-language (Java only).<br />

Sun Microsystems, with <strong>IBM</strong> <strong>and</strong> others, developed a more portable version of<br />

RMI, which uses the Object Management Group’s (OMG) Internet Inter-ORB<br />

Protocol. IIOP is necessary for Java 2 Platform, Enterprise Edition (J2EE)<br />

deployments to be interoperable with CORBA systems.<br />

Types of EJBs<br />

There are two types of Enterprise JavaBeans (EJB):<br />

► Entity EJBs<br />

They encapsulate permanent data, which is stored in a data source such as a<br />

database or a file system, <strong>and</strong> associated methods to manipulate that data. In<br />

most cases, an entity bean must be accessed in some transactional manner.<br />

Instances of an entity bean are unique <strong>and</strong> they can be accessed by multiple<br />

users. For example, information about a bank account can be encapsulated<br />

in an entity bean. An account entity bean might contain an account ID, an<br />

account type (checking or savings), a balance variable, <strong>and</strong> methods to<br />

manipulate these variables.<br />

620 <strong>TCP</strong>/<strong>IP</strong> <strong>Tutorial</strong> <strong>and</strong> <strong>Technical</strong> <strong>Overview</strong><br />

Web<br />

Server<br />

EJB Server<br />

Servlet or JSP<br />

RMI/IIOP<br />

Data Source

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!