refactor gracefulReload (bis)