changed connection factory for heroku