com.github.chengyuxing.sql.support.QueryTimeoutHandler Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of rabbit-sql Show documentation
Show all versions of rabbit-sql Show documentation
Light wrapper of JDBC, support ddl, dml, query, plsql/procedure/function, transaction and manage sql
file.
package com.github.chengyuxing.sql.support;
import java.sql.Statement;
import java.util.Map;
/**
* Jdbc execute sql timeout({@link Statement#setQueryTimeout(int)}) handler.
*/
@FunctionalInterface
public interface QueryTimeoutHandler {
/**
* Do handle sql execute timeout.
*
* @param sql sql
* @param args args
* @return timeout (seconds)
*/
int handle(String sql, Map args);
}