dbSetup error handling and before_request connection error handling