changed the db connection to use adapter based off of config