some refactoring and documentation for ZeroMQ transport