Fixed up some issues discovered with projects that use this base, specifically to handle mysql connection timeouts.