Interface PruneStrategy

All Superinterfaces:
Function<PooledConnectionProxy,Boolean>
All Known Implementing Classes:
IdlePruneStrategy

public interface PruneStrategy extends Function<PooledConnectionProxy,Boolean>
Provides an interface for pruning connections from the pool.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the interval at which the prune task will be executed.
    int
    Returns the number of statistics to store for this prune strategy.

    Methods inherited from interface java.util.function.Function

    andThen, apply, compose
  • Method Details

    • getStatisticsSize

      int getStatisticsSize()
      Returns the number of statistics to store for this prune strategy. See PooledConnectionStatistics.
      Returns:
      number of statistics to store
    • getPrunePeriod

      Duration getPrunePeriod()
      Returns the interval at which the prune task will be executed.
      Returns:
      prune period