Uploaded image for project: 'Commons Pool'
  1. Commons Pool
  2. POOL-270

timeBetweenEvictionRunsMillis from config is ignored

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.2
    • Fix Version/s: 2.3
    • Labels:
      None

      Description

      In the constructor for GenericKeyedObjectPool, the setting for timeBetweenEvictionRunsMillis is always overridden by minEvictableIdleTimeMillis.

      First setConfig() is called, which, ends up starting an evictor with a period of timeBetweenEvictionRunsMillis, as expected. but the final line of the constructor calls startEvictor() again with minEvictableIdleTimeMillis, which kills the first timer and starts a new one with the new period. This means effectively the timeBetweenEvictionRunsMillis from the config is not used for anything.

      I want testWhileIdle's verifications to run more often than I want the timeout for evicting idle objects, which does not appear to be possible given this bug.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              mberman Michael Berman
            • Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: