remotefilelog

Contents

remotefilelog causes Mercurial to lazilly fetch file contents (EXPERIMENTAL)

Description

This extension is HIGHLY EXPERIMENTAL. There are NO BACKWARDS COMPATIBILITY GUARANTEES. This means that repositories created with this extension may only be usable with the exact version of this extension/Mercurial that was used. The extension attempts to enforce this in order to prevent repository corruption.

remotefilelog works by fetching file contents lazily and storing them in a cache on the client rather than in revlogs. This allows enormous histories to be transferred only partially, making them easier to operate on.

Configs:

packs.maxchainlen specifies the maximum delta chain length in pack files

packs.maxpacksize specifies the maximum pack file size

packs.maxpackfilecount specifies the maximum number of packs in the
shared cache (trees only for now)

remotefilelog.backgroundprefetch runs prefetch in background when True

remotefilelog.bgprefetchrevs specifies revisions to fetch on commit and
update, and on other commands that use them. Different from pullprefetch.

remotefilelog.gcrepack does garbage collection during repack when True

remotefilelog.nodettl specifies maximum TTL of a node in seconds before
it is garbage collected

remotefilelog.repackonhggc runs repack on hg gc when True

remotefilelog.prefetchdays specifies the maximum age of a commit in
days after which it is no longer prefetched.
remotefilelog.prefetchdelay specifies delay between background
prefetches in seconds after operations that change the working copy parent
remotefilelog.data.gencountlimit constraints the minimum number of data
pack files required to be considered part of a generation. In particular, minimum number of packs files > gencountlimit.
remotefilelog.data.generations list for specifying the lower bound of
each generation of the data pack files. For example, list ['100MB','1MB'] or ['1MB', '100MB'] will lead to three generations: [0, 1MB), [ 1MB, 100MB) and [100MB, infinity).
remotefilelog.data.maxrepackpacks the maximum number of pack files to
include in an incremental data repack.
remotefilelog.data.repackmaxpacksize the maximum size of a pack file for
it to be considered for an incremental data repack.
remotefilelog.data.repacksizelimit the maximum total size of pack files
to include in an incremental data repack.
remotefilelog.history.gencountlimit constraints the minimum number of
history pack files required to be considered part of a generation. In particular, minimum number of packs files > gencountlimit.
remotefilelog.history.generations list for specifying the lower bound of
each generation of the history pack files. For example, list [ '100MB', '1MB'] or ['1MB', '100MB'] will lead to three generations: [ 0, 1MB), [1MB, 100MB) and [100MB, infinity).
remotefilelog.history.maxrepackpacks the maximum number of pack files to
include in an incremental history repack.
remotefilelog.history.repackmaxpacksize the maximum size of a pack file
for it to be considered for an incremental history repack.
remotefilelog.history.repacksizelimit the maximum total size of pack
files to include in an incremental history repack.
remotefilelog.backgroundrepack automatically consolidate packs in the
background

remotefilelog.cachepath path to cache

remotefilelog.cachegroup if set, make cache directory sgid to this
group

remotefilelog.cacheprocess binary to invoke for fetching file data

remotefilelog.debug turn on remotefilelog-specific debug output

remotefilelog.excludepattern pattern of files to exclude from pulls

remotefilelog.includepattern pattern of files to include in pulls

remotefilelog.fetchwarning: message to print when too many
single-file fetches occur

remotefilelog.getfilesstep number of files to request in a single RPC

remotefilelog.getfilestype if set to 'threaded' use threads to fetch
files, otherwise use optimistic fetching
remotefilelog.pullprefetch revset for selecting files that should be
eagerly downloaded rather than lazily
remotefilelog.reponame name of the repo. If set, used to partition
data from other repos in a shared store.

remotefilelog.server if true, enable server-side functionality

remotefilelog.servercachepath path for caching blobs on the server

remotefilelog.serverexpiration number of days to keep cached server
blobs
remotefilelog.validatecache if set, check cache entries for corruption
before returning blobs
remotefilelog.validatecachelog if set, check cache entries for
corruption before returning metadata

Commands

Repository maintenance

prefetch

prefetch file revisions from the server:

hg prefetch [OPTIONS] [FILE...]

Prefetchs file revisions for the specified revs and stores them in the local remotefilelog cache. If no rev is specified, the default rev is used which is the union of dot, draft, pullprefetch and bgprefetchrev. File names or patterns can be used to limit which files are downloaded.

Return 0 on success.

Options:

-r, --rev <REV[+]>
 prefetch the specified revisions
--repack run repack after prefetch
-b, --base <VALUE>
 rev that is assumed to already be local
-I, --include <PATTERN[+]>
 include names matching the given patterns
-X, --exclude <PATTERN[+]>
 exclude names matching the given patterns

[+] marked option can be specified multiple times

Uncategorized commands

gc

garbage collect the client and server filelog caches:

hg gc [REPO...]

garbage collect the client and server filelog caches

repack

hg repack [OPTIONS]

Options:

--background run in a background process
--incremental do an incremental repack
--packsonly only repack packs (skip loose objects)

verifyremotefilelog

hg verifyremotefilelogs <directory>

Options:

-d, --decompress
 decompress the filelogs first