adding run implementation to peer class