concept ibati DAO framework in category iBatis

This is an excerpt from Manning's book iBatis in Action.
The role of the abstraction layer is to provide a consistent and meaningful interface to the persistence layer. It is a set of classes and methods that act as a façade to the persistence implementation details. Methods in the abstraction layer should never require any implementation-specific parameters, nor should it return any values or throw any exceptions that are exclusive to the persistence implementation. With a proper abstraction layer in place, the entire persistence approach—including both the persistence API and the storage infrastructure—should be able to change without modifications to the abstraction layer or any of the layers that depend on it. There are patterns that can help with the implementation of a proper abstraction layer, the most popular of which is the Data Access Objects (DAO) pattern. Some frameworks, including iBATIS, implement this pattern for you. We discuss the iBATIS DAO framework in chapter 11.
The dao.xml file is the only configuration file required when using the iBATIS DAO framework. It is a very simple file, and is used to provide the DAO manager with the information required to manage transactions for your DAO classes and tell it how to supply DAO implementations for your interfaces.
Table 10.1. Transaction managers available with the iBATIS DAO framework
Type alias
Transaction manager/properties
Comments
EXTERNAL ExternalDaoTransactionManager A “do-nothing” transaction that allows you to manage your own transactions outside of the iBATIS DAO framework. HIBERNATE HibernateDaoTransactionManager Delegates to the Hibernate transaction management functionality. JDBC JdbcDaoTransactionManager * DataSource * JDBC.Driver * JDBC.ConnectionURL * JDBC.Username * JDBC.Password * JDBC.DefaultAutoCommit Uses JDBC to provide connection pooling services via the DataSource API. Three DataSource implementations are supported: SIMPLE, DBCP, and JNDI. SIMPLE is an implementation of the iBATIS SimpleDataSource, which is a stand-alone implementation ideal for minimal overhead and dependencies. DBCP is an implementation that uses the Jakarta DBCP DataSource. Finally, JNDI is an implementation that retrieves a DataSource reference from a JNDI directory. This is the most common and flexible configuration, as it allows you to centrally configure your application via your application server. JTA JtaDaoTransactionManager * DBJndiContext * UserTransaction Manages transactions using the Java Transaction Architecture (JTA) API. Requires that the DataSource implementation be retrieved via JNDI and that UserTransaction instances also be accessible via JNDI. OJB OjbBrokerTransactionManager Delegates to the OJB transaction management functionality. SQLMAP SqlMapDaoTransactionManager Delegates to the SQL map transaction management functionality. TOPLINK ToplinkDaoTransactionManager Delegates to the TOPLINK transaction management functionality.