##// END OF EJS Templates
revbranchcache: add the necessary bit to send 'rbc' data over bundle2...
Boris Feld -
r36984:c0e90df1 default
parent child Browse files
Show More
@@ -1939,6 +1939,28 b' def _getbundletagsfnodes(bundler, repo, '
1939 outgoing = _computeoutgoing(repo, heads, common)
1939 outgoing = _computeoutgoing(repo, heads, common)
1940 bundle2.addparttagsfnodescache(repo, bundler, outgoing)
1940 bundle2.addparttagsfnodescache(repo, bundler, outgoing)
1941
1941
1942 @getbundle2partsgenerator('cache:rev-branch-cache')
1943 def _getbundlerevbranchcache(bundler, repo, source, bundlecaps=None,
1944 b2caps=None, heads=None, common=None,
1945 **kwargs):
1946 """Transfer the rev-branch-cache mapping
1947
1948 The payload is a series of data related to each branch
1949
1950 1) branch name length
1951 2) number of open heads
1952 3) number of closed heads
1953 4) open heads nodes
1954 5) closed heads nodes
1955 """
1956 # Don't send unless:
1957 # - changeset are being exchanged,
1958 # - the client supports it.
1959 if not (kwargs.get(r'cg', True)) or 'rev-branch-cache' not in b2caps:
1960 return
1961 outgoing = _computeoutgoing(repo, heads, common)
1962 bundle2.addpartrevbranchcache(repo, bundler, outgoing)
1963
1942 def check_heads(repo, their_heads, context):
1964 def check_heads(repo, their_heads, context):
1943 """check if the heads of a repo have been modified
1965 """check if the heads of a repo have been modified
1944
1966
General Comments 0
You need to be logged in to leave comments. Login now