
C 6H A P T E R 6
JNDI Resources
The Java Naming and Directory Interface (JNDI) is an application programming interface (API) for accessing different kinds of naming and directory services. Java EE components locate objects by invoking the JNDI lookup method.
JNDI is the acronym for the Java Naming and Directory Interface API. By making calls to this API, applications locate resources and other program objects. A resource is a program object that provides connections to systems, such as database servers and messaging systems. (A JDBC resource is sometimes referred to as a data source.) Each resource object is identified by a unique,
This section covers the following topics:
■“Java EE Naming Services” on page 77
■“Naming References and Binding Information” on page 78
■“Using Custom Resources” on page 79
■“Using External JNDI Repositories and Resources” on page 79
Java EE Naming Services
A JNDI name is a
Java EE application clients, enterprise beans, and web components are required to have access to a JNDI naming environment.
The application component's naming environment is a mechanism that allows customization of the application component's business logic during deployment or assembly. Use of the
77