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

It is safer to make org.apache.commons.pool2.impl.GenericObjectPool.evictor volatile

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • Nightly Builds
    • 2.0
    • Platform: All

    Description

      A field of org.apache.commons.pool2.impl.GenericObjectPool<T> might need to be synchronized. Field org.apache.commons.pool2.impl.GenericObjectPool.evictor is read and written in method org.apache.commons.pool2.impl.GenericObjectPool.startEvictor(long), which might be called by multiple threads concurrently. Is there a possibility that org.apache.commons.pool2.impl.GenericObjectPool.startEvictor(long) gets invoked concurrently? Would it be safer to make org.apache.commons.pool2.impl.GenericObjectPool.evictor volatile?

      Attachments

        Activity

          People

            Unassigned Unassigned
            samira-t Samira Tasharofi
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: