Class CloseableDatabase

All Implemented Interfaces:
DatabaseAccess, AutoCloseable

public class CloseableDatabase extends Database implements AutoCloseable
Allows closing of the underlying pool. This is useful in application life cycle management, such as shutting down a database as a web application is being destroyed.

The component that creates the database should generally be responsible for closing it. To make it evident that the rest of the application should not close the database, only the Database base type should be provided.