##// END OF EJS Templates
changegroup: rename mfs to manifests...
Gregory Szorc -
r39274:cc957b9d default
parent child Browse files
Show More
@@ -850,7 +850,7 b' class cgpacker(object):'
850 850 self._verbosenote(_('%8.i (changelog)\n') % size)
851 851
852 852 clrevorder = clstate['clrevorder']
853 mfs = clstate['mfs']
853 manifests = clstate['manifests']
854 854 changedfiles = clstate['changedfiles']
855 855
856 856 # We need to make sure that the linkrev in the changegroup refers to
@@ -879,7 +879,7 b' class cgpacker(object):'
879 879
880 880 size = 0
881 881 it = self.generatemanifests(
882 commonrevs, clrevorder, fastpathlinkrev, mfs, fnodes, source,
882 commonrevs, clrevorder, fastpathlinkrev, manifests, fnodes, source,
883 883 clstate['clrevtomanifestrev'])
884 884
885 885 for tree, deltas in it:
@@ -905,9 +905,9 b' class cgpacker(object):'
905 905 mfdicts = None
906 906 if self._ellipses and self._isshallow:
907 907 mfdicts = [(self._repo.manifestlog[n].read(), lr)
908 for (n, lr) in mfs.iteritems()]
908 for (n, lr) in manifests.iteritems()]
909 909
910 mfs.clear()
910 manifests.clear()
911 911 clrevs = set(cl.rev(x) for x in clnodes)
912 912
913 913 it = self.generatefiles(changedfiles, commonrevs,
@@ -944,7 +944,7 b' class cgpacker(object):'
944 944 chunk stream has been fully consumed.
945 945 """
946 946 clrevorder = {}
947 mfs = {} # needed manifests
947 manifests = {}
948 948 mfl = self._repo.manifestlog
949 949 changedfiles = set()
950 950 clrevtomanifestrev = {}
@@ -957,7 +957,7 b' class cgpacker(object):'
957 957 clrevorder[x] = len(clrevorder)
958 958
959 959 if self._ellipses:
960 # Only update mfs if x is going to be sent. Otherwise we
960 # Only update manifests if x is going to be sent. Otherwise we
961 961 # end up with bogus linkrevs specified for manifests and
962 962 # we skip some manifest nodes that we should otherwise
963 963 # have sent.
@@ -967,7 +967,7 b' class cgpacker(object):'
967 967 manifestnode = c.manifest
968 968 # Record the first changeset introducing this manifest
969 969 # version.
970 mfs.setdefault(manifestnode, x)
970 manifests.setdefault(manifestnode, x)
971 971 # Set this narrow-specific dict so we have the lowest
972 972 # manifest revnum to look up for this cl revnum. (Part of
973 973 # mapping changelog ellipsis parents to manifest ellipsis
@@ -982,7 +982,7 b' class cgpacker(object):'
982 982 changedfiles.update(c.files)
983 983 else:
984 984 # record the first changeset introducing this manifest version
985 mfs.setdefault(c.manifest, x)
985 manifests.setdefault(c.manifest, x)
986 986 # Record a complete list of potentially-changed files in
987 987 # this manifest.
988 988 changedfiles.update(c.files)
@@ -991,7 +991,7 b' class cgpacker(object):'
991 991
992 992 state = {
993 993 'clrevorder': clrevorder,
994 'mfs': mfs,
994 'manifests': manifests,
995 995 'changedfiles': changedfiles,
996 996 'clrevtomanifestrev': clrevtomanifestrev,
997 997 }
@@ -1009,8 +1009,8 b' class cgpacker(object):'
1009 1009
1010 1010 return state, gen
1011 1011
1012 def generatemanifests(self, commonrevs, clrevorder, fastpathlinkrev, mfs,
1013 fnodes, source, clrevtolocalrev):
1012 def generatemanifests(self, commonrevs, clrevorder, fastpathlinkrev,
1013 manifests, fnodes, source, clrevtolocalrev):
1014 1014 """Returns an iterator of changegroup chunks containing manifests.
1015 1015
1016 1016 `source` is unused here, but is used by extensions like remotefilelog to
@@ -1019,7 +1019,7 b' class cgpacker(object):'
1019 1019 repo = self._repo
1020 1020 mfl = repo.manifestlog
1021 1021 dirlog = mfl._revlog.dirlog
1022 tmfnodes = {'': mfs}
1022 tmfnodes = {'': manifests}
1023 1023
1024 1024 # Callback for the manifest, used to collect linkrevs for filelog
1025 1025 # revisions.
@@ -1027,7 +1027,7 b' class cgpacker(object):'
1027 1027 def makelookupmflinknode(tree, nodes):
1028 1028 if fastpathlinkrev:
1029 1029 assert not tree
1030 return mfs.__getitem__
1030 return manifests.__getitem__
1031 1031
1032 1032 def lookupmflinknode(x):
1033 1033 """Callback for looking up the linknode for manifests.
General Comments 0
You need to be logged in to leave comments. Login now