mirror of
https://github.com/facebook/sapling.git
synced 2024-10-11 17:27:53 +03:00
df97f609bf
Summary: Previously, the logic that added data to a mutable history pack was required to add it in the correct order (all entries for a certain file at once, and in newest-first order). This required the callers to jump through weird hoops if the data came in out of order or at different times in the transaction. This patch moves the ordering logic to be inside MutableHistoryPack, so callers can add the data in any order they wish, and it will get sorted before being serialized. This does add memory pressure to things that read a lot of history, like repack. If this becomes a problem we may want to add a 'historypack.flush()' api that let's us tell the history pack it's ok to flush it's current contents to disk. Test Plan: Ran the tests Reviewers: #mercurial, quark Reviewed By: quark Subscribers: quark, mjpieters Differential Revision: https://phabricator.intern.facebook.com/D4956096 Signature: t1:4956096:1493264693:a2275a49e35565d4b11244e3e5dd82c25de7e16e |
||
---|---|---|
.. | ||
__init__.py | ||
cachemanager.py | ||
concurrency.py | ||
constants.py | ||
debug.py | ||
implementation.py | ||
metrics.py |