# HG changeset patch # User Pierre-Yves David # Date 2014-04-15 21:19:46 # Node ID 0879352d67d8322e485006456d8adbfae3654d6e # Parent 19b9f23a8c6fa34e0677d21419ffdf6d0b7b92a8 wireproto: add a _calltwowaystream method on wirepeer This method will be used by bundle2 pushes. It calls a command, feeds it with a stream and receives another stream in reply. Actual implementation for ssh and http will be done in later changesets. diff --git a/mercurial/wireproto.py b/mercurial/wireproto.py --- a/mercurial/wireproto.py +++ b/mercurial/wireproto.py @@ -415,6 +415,13 @@ class wirepeer(peer.peerrepository): """ raise NotImplementedError() + def _calltwowaystream(self, cmd, fp, **args): + """execute on server + + The command will send a stream to the server and get a stream in reply. + """ + raise NotImplementedError() + def _abort(self, exception): """clearly abort the wire protocol connection and raise the exception """