wrapping request in db transaction