1 / 10

JNDI

JNDI. Celsina Bignoli bignolic@smccd.net. Naming Services. Name : reference to an entity A naming service : Associates (binds) names with objects Provides mechanisms for finding an object based on a name Naming services are ubiquitous in computing DNS (name –IP address)

Download Presentation

JNDI

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. JNDI Celsina Bignoli bignolic@smccd.net

  2. Naming Services • Name: reference to an entity • A naming service: • Associates (binds) names with objects • Provides mechanisms for finding an object based on a name • Naming services are ubiquitous in computing • DNS (name –IP address) • File system naming service

  3. Directory Services • A directoryobject is a special object which has attributes associated with it. • A directory service is a naming service with additional functionality for manipulating attributes • A directory is a system of correlated directory objects

  4. Directory Structure Employee1 Employees Employee2 Company Printers Computer1 Hardware Computers Computer2 Fax Machines

  5. Existing Naming & Directory Services • Examples: • LDAP (Lightweight Directory Access Protocol) • NIS (Network Information System) • Novell’s NDS (Network Directory System) • Each has its own proprietary set of services • Makes it hard to switch between systems

  6. JNDI • Provides a common interface to disparate directory services • You can use behind the scene an heterogeneous set of Naming and Directory systems making it look like one, and not having to learn their specific APIs • Use JNDI for resource factories, look up beans, acquire references

  7. JNDI Architecture Client Code JNDI Client API Service Provider Interface LDAP Service Provider NIS Service Provider File System Service Provider

  8. JNDI Concepts • Atomic name: indivisible name • Ex: usr, local • Compound name:zero or more atomic names put together according to a specific syntax • Ex: /usr/local • Binding: association of a name with an object • run.exe associates to an executable file in the file system • Context:a set of 0 or more bindings, with its own distinct atomic name.

  9. JNDI Concepts (2) • Naming system: connected set of contexts that use the same name syntax • Ex: folder tree in a file system • Namespace: set of names in a name system • Composite Name: name that spans multiple naming systems

  10. Initial Context Factories • Initial Context: starting point from where to perform naming and directory operations • Initial Context Factory: used to acquire initial context. Implemented by the JNDI Driver • To acquire an Initial Context you must provide: • IP address of the J2EE server • Port number • Starting location within the JNDI tree • User name/ password combination to access J2EE server

More Related