Support external listeners. Closes #1672