beforeStart callback