Added an api call that will shutdown the listeners.