When your application uses IMS Connector for Java™, also known as the IMS TM resource adapter, it interacts with IMS through IMS Connect using connections between the IMS TM resource adapter and IMS Connect which are created by an IMS connection factory. These connections can be managed or non-managed. Managed connections refer to connections which are managed by a Connection Manager in a J2EE application server such as WebSphere® Application Server. In a managed environment, applications do not need to create EIS connections themselves. Rather, they request connections from the J2EE Connection Manager. Non-managed connections on the other hand, are obtained directly by applications from the IMS TM resource adapter and are typically used in two-tiered applications.
When your application uses managed connections, all connections between the IMS TM resource adapter and IMS Connect are persistent. In other words, a connection is not "opened" and "closed" for each interaction. Instead, it can remain open and can be serially re-used by multiple interactions, providing better utilization of CPU and memory resources. A non-managed connection must be opened and closed by the application which uses it. With managed connections, your J2EE application server administrator configures the connection factory at deployment time, while with non-managed connections, your application must create and configure whatever connection factories it needs at runtime. The use of managed connections and JNDI lookup to get a reference to the appropriate connection factory is recommended.