##// END OF EJS Templates
peer: introduce a limitedarguments attributes...
marmoute -
r42334:69921d02 default
parent child Browse files
Show More
@@ -382,6 +382,7 class httppeer(wireprotov1peer.wirepeer)
382 self._path = path
382 self._path = path
383 self._url = url
383 self._url = url
384 self._caps = caps
384 self._caps = caps
385 self.limitedarguments = caps is not None and 'httppostargs' not in caps
385 self._urlopener = opener
386 self._urlopener = opener
386 self._requestbuilder = requestbuilder
387 self._requestbuilder = requestbuilder
387
388
@@ -750,6 +751,9 class httpv2executor(object):
750
751
751 @interfaceutil.implementer(repository.ipeerv2)
752 @interfaceutil.implementer(repository.ipeerv2)
752 class httpv2peer(object):
753 class httpv2peer(object):
754
755 limitedarguments = False
756
753 def __init__(self, ui, repourl, apipath, opener, requestbuilder,
757 def __init__(self, ui, repourl, apipath, opener, requestbuilder,
754 apidescriptor):
758 apidescriptor):
755 self.ui = ui
759 self.ui = ui
@@ -291,6 +291,10 class ipeercommandexecutor(interfaceutil
291 class ipeerrequests(interfaceutil.Interface):
291 class ipeerrequests(interfaceutil.Interface):
292 """Interface for executing commands on a peer."""
292 """Interface for executing commands on a peer."""
293
293
294 limitedarguments = interfaceutil.Attribute(
295 """True if the peer cannot receive large argument value for commands."""
296 )
297
294 def commandexecutor():
298 def commandexecutor():
295 """A context manager that resolves to an ipeercommandexecutor.
299 """A context manager that resolves to an ipeercommandexecutor.
296
300
@@ -329,6 +333,8 class ipeerv2(ipeerconnection, ipeercapa
329 class peer(object):
333 class peer(object):
330 """Base class for peer repositories."""
334 """Base class for peer repositories."""
331
335
336 limitedarguments = False
337
332 def capable(self, name):
338 def capable(self, name):
333 caps = self.capabilities()
339 caps = self.capabilities()
334 if name in caps:
340 if name in caps:
General Comments 0
You need to be logged in to leave comments. Login now