implemented reaper object to regulate shutdown