Uploaded image for project: 'OpenJPA'
  1. OpenJPA
  2. OPENJPA-2773

set minIdle to > 0 in DBCPDriverDataSource

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.0
    • Fix Version/s: 3.1.0
    • Component/s: jdbc
    • Labels:
      None

      Description

      Right now our DBCPDriverDataSource by default sets the maxIdle to 1.
      This is not wrong but also not really good in terms of performance.
      It is usually much better to keep it at a much higher number. Usually somewhere around maxActive, except when maxActive is really high.

      So I'd rather keep it at 10 or even at maxActive if this param is set.
      If the connections are not used, then they will get unlocked after some time anyway.
      But keeping the number 1 for maxIdle basically disables the pool, which is not wise.

        Attachments

          Activity

            People

            • Assignee:
              struberg Mark Struberg
              Reporter:
              struberg Mark Struberg
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: