Interface TarantoolConnectionManager
-
- All Superinterfaces:
AutoCloseable
- All Known Implementing Classes:
AbstractTarantoolConnectionManager
,TarantoolClusterConnectionManager
public interface TarantoolConnectionManager extends AutoCloseable
Manages the Tarantool server connections lifecycle. Maintains multiple connections. Once a connection is lost, a connection procedure is performed.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CompletableFuture<TarantoolConnection>
getConnection()
Get an established connection according to the order provided by specified connection selection strategy.boolean
refresh()
Starts the process of establishing lacking connections to each host-
Methods inherited from interface java.lang.AutoCloseable
close
-
-
-
-
Method Detail
-
getConnection
CompletableFuture<TarantoolConnection> getConnection()
Get an established connection according to the order provided by specified connection selection strategy. If the connection procedure hasn't been performed yet, starts it.- Returns:
- a future with next connection in order
-
refresh
boolean refresh()
Starts the process of establishing lacking connections to each host- Returns:
- returns true if the establishing process has been started, else false
-
-