Uploaded image for project: 'MariaDB Connector/Python'
  1. MariaDB Connector/Python
  2. CONPY-73

Error from connection pool: No more connections from pool 'web-app' available

Details

    Description

      I've attached a simple test program that fails with an error.

      For example:

      $ python3 ./connection_pool_test2.py 
      Error: No more connections from pool 'web-app' available
      

      This is with the following environment:

      $ python3 --version
      Python 3.6.9
      $ cat /etc/os-release 
      NAME="Ubuntu"
      VERSION="18.04.4 LTS (Bionic Beaver)"
      ID=ubuntu
      ID_LIKE=debian
      PRETTY_NAME="Ubuntu 18.04.4 LTS"
      VERSION_ID="18.04"
      HOME_URL="https://www.ubuntu.com/"
      SUPPORT_URL="https://help.ubuntu.com/"
      BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
      PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
      VERSION_CODENAME=bionic
      UBUNTU_CODENAME=bionic
      

      This occurred with MariaDB Connector/Python 1.0.0, which was installed via:

      $ tar -xvzf mariadb-connector-python-1.0.0.tar.gz
      $ pip3 install mariadb-1.0.0
      

      Attachments

        Issue Links

          Activity

            georg Georg Richter added a comment -

            We don't yet add automatically connections to the pool - the current implementation is similiar to MySQL Connector/Python.
            When running the attached script with MySQL Connector/Python , the following error is returned:

            Error: Failed getting connection; pool exhausted
            

            So with current implementation you have to add connections first with pool.add_connection()

            georg Georg Richter added a comment - We don't yet add automatically connections to the pool - the current implementation is similiar to MySQL Connector/Python. When running the attached script with MySQL Connector/Python , the following error is returned: Error: Failed getting connection; pool exhausted So with current implementation you have to add connections first with pool.add_connection()

            Confirmed. This appears to be due to the pool connections being made at init time and not reset when the configuration changes, set_config only appears to store the configuration changes but not apply them.

            LinuxJedi Andrew Hutchings (Inactive) added a comment - Confirmed. This appears to be due to the pool connections being made at init time and not reset when the configuration changes, set_config only appears to store the configuration changes but not apply them.

            georg If this is the case, the Sphinx docs for the API should probably be updated to mention what you can and cannot use this call for. Maybe using a ".. note::"?

            LinuxJedi Andrew Hutchings (Inactive) added a comment - georg If this is the case, the Sphinx docs for the API should probably be updated to mention what you can and cannot use this call for. Maybe using a ".. note::"?

            People

              jacob.moorman Jacob Moorman (Inactive)
              GeoffMontee Geoff Montee (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.