CodeIgniter
CodeIgniter copied to clipboard
Don't close db connection if using pconnect
CI always closes the database connection, even if a permanent connection was (deliberately) established.
At CodeIgniter.php end, should check if $CI->db is set and if $database['pconnect'](from config/databse.php) is FALSE
If $database['pconnect'] is TRUE, there should be a way for the db object to be serialized, instead, and unserialized in the next request. Or, at least, keep the connection resource on session, and use it when reloading the DB class.