Package io.agroal.api.cache
Interface ConnectionCache
public interface ConnectionCache
Interface for a cache of connections. It's intended for mapping connections to executing threads.
- Author:
- Luis Barreiro
-
Method Summary
Modifier and TypeMethodDescriptionget()Get a acquirable object from cache.static ConnectionCachenone()An implementation that does not cache.voidput(Acquirable acquirable) Cache an acquirable object on this cache.voidreset()Reset the cache.
-
Method Details
-
none
An implementation that does not cache. -
get
Acquirable get()Get a acquirable object from cache.- Returns:
- a connection successfully acquired, according to
Acquirable.acquire()
-
put
Cache an acquirable object on this cache. -
reset
void reset()Reset the cache.
-