Firm up the event system. Make handlers only emit their own events, and then map those to Messages and IO events with a bit of glue. Only emit 'data' when streams are readable, same for 'end'.