J2EE or J2SE? JNDI works with both
JNDI, the Java Naming and Directory Interface, allows applications to access various naming and directory services via a common
interface. The figure below shows the JNDI architecture. Like JDBC (Java Database Connectivity), JNDI is not a service, but
a set of interfaces; it allows applications to access many different directory service providers using a standardized API.
Just as with JDBC, the JDK contains the JNDI interfaces but does not include a JNDI service provider -- although Sun Microsystems
provides adapters for connecting to existing directory service providers, such as LDAP (lightweight directory access protocol),
DNS (domain name service), and CORBA. However, you can use one of several free or open source JNDI providers in your J2SE
(Java 2 Platform, Standard Edition) applications.
Brian Goetz,
April 2002
Integrate EJBs with CORBA
Interoperability between EJBs (Enterprise JavaBeans) and CORBA is
important for integrating Java- and non-Java-based applications.
This article shows how to achieve integration between an EJB and a
CORBA C++ application. It points to several important integration
areas, particularly those in which EJBs use methods with Java
built-in or user-defined objects as their parameters and return
values.
Matjaz B. Juric,
March 2002
Java Tip 118: Utilize the EjbProxy
This tip introduces you to the EjbProxy utility class.
It instantiates and invokes a remote EJB without coupling your code
directly to a specific implementation of that particular EJB.
Gorsen Huang,
October 2001
The art of EJB deployment
It's no wonder the EJB specification calls for the role of an EJB
deployer. Deploying EJBs can be a time-consuming task, and
designing blueprints for universally deployable EJBs can be an even
greater challenge. Application servers differ in how they prepare
and deploy EJBs. This article tackles the issues you might
encounter when deploying the same EJB code on different application
servers -- namely BEA's WebLogic, IBM's WebSphere, and the open
source community's JBoss. In addition, it highlights some
preparation techniques for your EJB deployment.
James Caple and <a Href="javascript:openbrwindow()">mike Haim Altarace</a>,
August 2001
The magic of Merlin
This technical overview will give you insight into the various new
features and APIs of the upcoming JDK 1.4 -- code-named
Merlin. The beta version is expected to be released this
month. (3,000 words)
Vinay Aggarwal,
March 2001
J2EE clustering, Part 1
If you plan to build a scalable and highly available Website, you
need to understand clustering. In this article, Abraham Kang
introduces J2EE clustering, shows how to implement clusters, and
examines how Bluestone Total-e-server, Sybase Enterprise
Application Server, SilverStream Application Server, and WebLogic
Application Server differ in their approaches. With this knowledge
you will be able to design and implement effective and efficient
J2EE applications. (5,900 words)
Abraham Kang,
February 2001
Get disconnected with CachedRowSet
The new CachedRowSet, still in early access release,
provides benefits that developers can begin to take advantage of
right away. Taylor Cowan demonstrates how you can use a
CachedRowSet as the data model for a JavaServer Pages
(JSP) entry/edit form. Assuming that you have some experience with
JSP development, he describes step by step how to implement
navigation, updates, inserts, and deletes using a
CachedRowSet JavaBean. In addition, he shows how the
CachedRowSet helps to reduce database-update SQL
statements and the use of valuable database connection resources.
(2,100 words)
Taylor G. Cowan,
February 2001
Dive into connection pooling with J2EE
Connection pooling is a technique used for sharing server resources
among requesting clients. This article focuses on support for
connection pooling of both database resources and
nondatabase resources in a J2EE environment. Siva examines
the JDBC 2.0, JMS 1.02, JNDI 1.2 Standard Extension APIs with
regard to connection pooling and looks at some existing vendor
implementations of those APIs. He then looks at the upcoming J2EE
Connector Architecture 1.0 that would support a
vendor-independent/pluggable approach to managing resource
connections. (2,000 words)
Siva Visveswaran,
October 2000
Frameworks save the day
Every Enterprise Java project has the same basic plumbing. By
embracing this premise, you can cut project costs and improve
software quality in one swoop. Even the lightweight framework
outlined in this article can add significant value to your project
-- with immediate gains. And it's designed to be extensible and
vendor-neutral, which makes it all the more valuable. We'll look at
some basic components to demonstrate how you can add new services
easily while maintaining a consistent API to developers using the
framework, thus ensuring future extensibility. We'll also look at
the issues pertaining to cross-application server portability.
(3,200 words)
Humphrey Sheil,
September 2000
Oracle8i's ORB does the trick
This article provides an in-depth overview of developing scalable
and secure server-side Java CORBA applications using Oracle8i JVM
and ORB. Also, session-based IIOP is introduced. Extensive security
mechanisms make it easy to develop highly secure and flexible
applications. A simple and easy-to-use JNDI interface is also
provided to the name service. Since the Oracle8i ORB runs in the
database, the desired load balancing and high scalability can be
taken for granted. We'll also briefly touch on the general Oracle8i
server framework, with which developers can write their own
client/server protocols or component models using the scalability
and performance of Oracle8i. Future releases of the ORB will
include more sophisticated features like POA, objects by value, and
bi-directional GIOP. (3,300 words)
Sastry K. Malladi,
July 2000
JNDI overview, Part 3: Advanced JNDI
A JNDI service can be much more than a computerized card catalog.
JNDI's object-storage capabilities allow it to play the role of
resource administrator in your distributed applications and to
provide simple, manageable object persistence. In recognition of
its potential, the architects of key Java technologies such as JDBC
and EJB built JNDI into their specifications. This month Todd
Sundsted shows you how to store objects in a JNDI service.
(1,900 words)
Todd Sundsted,
March 2000
JNDI overview, Part 2: An introduction to directory services
As applications become more distributed, the efficient management
and distribution of the information upon which they depend becomes
more and more of a problem. Directory services such as LDAP (the
Lightweight Directory Access Protocol) address this problem. For
Java applications, the Java Naming and Directory Interface (JNDI)
provides a generic interface to LDAP and other directory services.
This month, Todd Sundsted introduces you to JNDI directory
services. (1,300 words)
Todd Sundsted,
February 2000
Use JNDI to share objects between different virtual machines
Imagine the following: Process A on machine B puts an object into a
Hashtable. Now, a separate process C on a different
machine D can access that object from its own local copy of the
Hashtable -- even after process A terminates and the
virtual machine unloads! Now imagine all this is achieved without
the use of RMI, and without involving an ORB, CORBA, EJB, or a
database. What's the secret? The Java Naming and Directory
Interface (JNDI). This month's tool is the
JNDIHashtable -- which, as its name reveals, uses JNDI
to do its thing. (2,600 words)
Thomas E. Davis,
July 1999
The state of Java middleware, Part 2: Enterprise JavaBeans
By the time Sun released version 1.0 of the Enterprise JavaBeans
(EJB) specifications in March of 1998, several vendors not only had
endorsed this new server-side component architecture, but also had
begun developing products based on the evolving specifications.
Today there are several products that fully implement the required
features of EJB 1.0, and some that also support optional EJB
features. This article provides an overview of EJB and looks at how
some of these products support EJB. If you have wondered what EJB
is or have bits and pieces of information about it but are missing
the big picture, you need to read this article.
Bonus: Includes a Middleware and EJB Glossary.
(9,000 words)
Anil Hemrajani,
April 1999