This topic discusses how applications can use a JNDI namespace to connect to different JMS-provider environments to access the resources hosted by those environments.
The Java™ Naming and Directory Interface (JNDI) API enables JMS clients to look up configured JMS objects. By delegating all the provider-specific work to administration tasks for creating and configuring these objects, the clients can be completely portable between environments. In addition, the applications are easier to administer because they have no need for embedded administrative values in their code.
The messaging environment to which the application connects will depend upon the implementation type of the ConnectionFactory object that is obtained from JNDI. For example, if it's a WebSphere® Application Server 6.0 default messaging ConnectionFactory, then a connection will be made to the same service integration bus.