All Downloads are FREE. Search and download functionalities are using the official Maven repository.

sqlg3.runtime.ConnectionManager Maven / Gradle / Ivy

Go to download

SQLG is a preprocessor and a library that uses code generation to simplify writing JDBC code

There is a newer version: 3.1
Show newest version
package sqlg3.runtime;

import java.sql.Connection;
import java.sql.SQLException;

/**
 * Connection pool interface. Pool is created once for each connected user.
 */
public interface ConnectionManager {

    /**
     * Connection allocation.
     */
    Connection allocConnection() throws SQLException;

    /**
     * Connection release.
     */
    void releaseConnection(Connection conn) throws SQLException;

    /**
     * Commits transaction on business method finish (for simple transactions)/on commit for full transactions.
     */
    void commit(Connection conn) throws SQLException;

    /**
     * Rolls back transaction on business method fail (for simple transactions)/on rollback for full transactions.
     */
    void rollback(Connection conn) throws SQLException;

    /**
     * Closing all connections and releasing all resources.
     */
    void close() throws SQLException;
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy