The JNDI Architectural Framework


As illustrated in Figure 14.1, JNDI provides two interfaces between a Java application and a naming or directory service, as follows :

Figure 14.1. The JNDI architectural framework provides a common API to a variety of naming and directory services.

graphics/14fig01.gif

  • The Application Programming Interface ( API ) can be used by a developer to access a naming or directory service from within a client application.

  • The Service Provider Interface ( SPI ) provides the capability for a J2EE Server to be independent of any specific industry naming or directory service provider. The SPI is plugged into the JNDI framework and provides a mapping from the JNDI API to the naming or directory service provider. Access to the service provider from the JNDI API is provided via a naming manager, which is typically provided by the J2EE server implementing the JNDI service, as in the case of WebLogic Server.

Note

Further descriptions of the JNDI APIs and SPIs are provided in their respective sections later in this chapter.


Hence, the JNDI architecture is independent of any specific service provider and therefore supports access to a variety of existing and emerging naming and directory services.

The Java 2 SDK version 1.3 and later releases include the JNDI classes and the three Service Provider Interfaces ”LDAP, COS, and RMI ”shown in Figure 14.1. JNDI is also available as a Java Standard Extension for use with JDK 1.1 and Java 2 SDK 1.2. WebLogic Server includes these three standard SPIs, as well as the WebLogic SPI for WebLogic Server's embedded naming service.

The four Service Provider Interfaces included in WebLogic Server are:

  • LDAP SPI ” The Service Provider Interface for an LDAP server

  • COS SPI ” The Service Provider Interface for the Common Object Services used by CORBA

  • RMI SPI ” The Service Provider Interface used by RMI to contact the rmiregistry

  • WebLogic SPI ” The implemented Service Provider Interface to make its services available through JNDI

Additional Service Provider Interfaces for JNDI are also available, including Domain Name Service (DNS) and Network Information Service (NIS).

Note

A complete list of JNDI complaint service providers can be located at http://java.sun.com/products/jndi/serviceproviders.html.




BEA WebLogic Platform 7
BEA WebLogic Platform 7
ISBN: 0789727129
EAN: 2147483647
Year: 2003
Pages: 360

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net