Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2010

    Unanswered: MySQL Persistant Connection

    Starting researching this and found most results indicate that it's more trouble than it's worth. Guess I am looking for a bottom line answer to use
    or not to use. As I am a new MySQL user, have years of experience with
    other databases, would like to get the experts opinions.

    Jim Douglas

  2. #2
    Join Date
    Sep 2009
    San Sebastian, Spain
    Hi Jim,

    the idea of persistent connections, where a link is reused does on the surface suggest improved performance i.e. without needing to allocate memory structures etc.

    The downside of persistent connections is the possibility of creating locks on tables which could in turn block any database connections, use up all the web browsers connections and ultimately stops the website from running.

    Ultimately persistent connection hinge on the performance improvements gained from using them. I have found an interesting website which analyzed the performance gains of using persistent versus non-persistent connections Benchmarking of MySQL Persistent Connections vs Non-Persistent Connections | Randomness from RES and the conclusion is that the performance gain is negligible. If I have time I will try and reexecute the same sets of tests on my own server with the latest versions of both PHP and MySQL to see if these deliver any improved performance and let you know.
    Ronan Cashell
    Certified Oracle DBA/Certified MySQL Expert (DBA & Cluster DBA)
    Follow me on Twitter

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts