Commit Graph

55765 Commits

Author SHA1 Message Date
Adam Simpkins
6f824649ff use absolute includes to the third-party xdiff code
Summary:
Update includes to the third-party xdiff.h file to use absolute includes
from the repository root.  This allows many parts of our internal build
tooling to work better, including automatic dependency processing.

Reviewed By: xavierd

Differential Revision: D19958228

fbshipit-source-id: 341dd8c94f1138cf4a387b92e1817b2a286d6aa1
2020-02-19 13:05:06 -08:00
Adam Simpkins
5ffa268af2 use absolute includes for the native cext modules
Summary:
Update the C files under edenscm/mercurial/cext to use absolute includes from
the repository root.  Also update a few of the libraries in edenscm/mercurial
that the cext code depends on.

This makes these files easier to build with Buck in fbsource, and reduces the
number of places where we have to use deprecated Buck functionality to help
find these headers.  This also allows autodeps to work with the build targets
for these rules.

Reviewed By: xavierd

Differential Revision: D19958221

fbshipit-source-id: e6e471583a795ba5773bae5f16ed582c9c5fd57e
2020-02-19 13:05:06 -08:00
Adam Simpkins
ab8071fa35 stop including thirdparty/pyre2 in the fbcode build
Summary:
Remove `thirdparty/pyre2/__init__.py` from the `libhg` sources list.

We don't compile the `thirdparty/pyre2/_re2.cc` file in the fbcode build, so
importing the `__init__.py` module from this package just triggers an
ImportError when the code tries to use it.  The code then always falls back to
using the version of pyre2 included from the `fb-re2` wheel.

Dropping the `__init__.py` module from our library should simply trigger an
ImportError earlier when we can't even find this file, and the code will still
fall back to using `fb-re2`.

Including this `__init__.py` file just causes issues for type checking, since
it causes us to try and type check this file even though its dependencies are
not present.

Reviewed By: xavierd

Differential Revision: D19958224

fbshipit-source-id: 34ea8806b6ee9377f17a9318c64c91ec242225df
2020-02-19 13:05:06 -08:00
Adam Simpkins
d736cca388 fix type annotations in eden_dirstate_map.py
Summary:
Some of the methods in eden_dirstate_map.py had comments that were close to
type annotations that were added a couple years ago.  Update them to proper
type comments that can be recognized by Pyre and mypy.

Also remove the unused create_clone_of_internal_map() method.

Reviewed By: chadaustin, xavierd

Differential Revision: D19958225

fbshipit-source-id: b753c030acb15cf4f8d8c536614e657ee1bcba52
2020-02-19 13:05:05 -08:00
Adam Simpkins
a673c6bd4d update eden_dirstate_map to store dirstatetuple objects
Summary:
Update the `eden_dirstate_map` class to store `dirstatetuple` objects instead
of plain tuples in its `_map` member variable.  Without this the `filefoldmap`
code that is used on Windows fails, as it directly accesses `self._map` and
expects it to contain `dirstatetuple` objects.

Reviewed By: DurhamG, pkaush

Differential Revision: D19841881

fbshipit-source-id: ddb7523b598cfd8ec8719a8a74446cefcb411358
2020-02-19 13:05:05 -08:00
svcscm
7b049c89dd Updating submodules
Summary:
GitHub commits:

c5141ebf38
95c7d18c0f
1c4b4838d7
fd39695c7e
73a6de2488

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: cf39027dfaa7427de3723a0b876405ca2f9a3c98
2020-02-19 12:57:54 -08:00
Chad Austin
c82a570d32 report conflicts when tree containing modified files is removed
Summary:
Eden SCM expects that DRY_RUN reports the same conflicts as a normal
checkout, but EdenFS would skip traversing deleted trees in dry run
mode. Fix that and add a test.

Reviewed By: genevievehelsel

Differential Revision: D19782543

fbshipit-source-id: 7a269e67a41b7ad6ce6c54fde37e8f74fcc1ef51
2020-02-19 11:20:55 -08:00
Thomas Orozco
c899ed7249 test-gitimport-octopus: don't expect a specific number of commits to verify
Summary:
bonsai_verify occasionally visits the same commit twice (I found out by adding
logging and noting that it occasionally visits the same commit twice). Let's
allow this here.

Reviewed By: StanislavGlebik

Differential Revision: D19951390

fbshipit-source-id: 3e470476c6bc43ffd62cf24c3486dfcc7133de6c
2020-02-19 10:16:38 -08:00
Arun Kulshreshtha
9ec04f9639 edenapi_server: move handlers to submodule
Summary: We're about to start adding more handlers to the server. Rather than putting them all in the same file, let's create a submodule for them.

Reviewed By: krallin

Differential Revision: D19957012

fbshipit-source-id: 38192664371f0b0ef5eadb4969739f7cb6e5c54c
2020-02-19 09:59:14 -08:00
Arun Kulshreshtha
44ded80beb edenapi_server: Add request context middleware
Summary: Add a `RequestContext` type that stores per-request state, along with a `Middleware` implementation that injects a `RequestContext` into Gotham's `State`  object for each request. This is essentially a stripped-down version of the `RequestContextMiddleware` used in the LFS server. Given that the RequestContext contains application-specific functionality, this Middleware lives alongside the rest of the EdenAPI server code rather than in the `gotham_ext` crate (where all of the generic Middleware lives).

Reviewed By: krallin

Differential Revision: D19957013

fbshipit-source-id: 6fad2b92aea0b3662403a69e6a6598e4cd26f083
2020-02-19 09:59:14 -08:00
svcscm
f96e1ce99e Updating submodules
Summary:
GitHub commits:

19f6ae0d52

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: dd28f1f5d92ccfc56675552d3dc3e1a6b6a2ce40
2020-02-19 09:31:46 -08:00
Mark Thomas
a8f06f75c0 derived_data: add DeriveError for when derivation is disabled
Summary:
Currently if derivation of a particular derived data type is disabled, but a
client makes a request that requires that derived data type, we will fail with
an internal error.

This is not ideal, as internal errors should indicate something is wrong, but
in this case Mononoke is behaving correctly as configured.

Convert these errors to a new `DeriveError` type, and plumb this back up to
the SCS server.  The SCS server converts these to a new `RequestError`
variant: `NOT_AVAILABLE`.

Reviewed By: krallin

Differential Revision: D19943548

fbshipit-source-id: 964ad0aec3ab294e4bce789e6f38de224bed54fa
2020-02-19 09:28:09 -08:00
svcscm
97dca7e280 Updating submodules
Summary:
GitHub commits:

f29e87cf35

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: e06fcaf8d82ad91659ed5a58f93ae5e64d3378ee
2020-02-19 08:54:07 -08:00
Genevieve Helsel
d90506bfb5 fork in cli daemon_exec
Summary: fork exec wait in `daemon.dameon_exec` so we can get exit code of child process in order to log.

Reviewed By: simpkins

Differential Revision: D19861810

fbshipit-source-id: 85fce52b2e2d252bb4dec779f5f975e3712b6bb5
2020-02-19 08:08:08 -08:00
Johan Schuijt-Li
91ef68fa49 configs: make configerator configs easier to use in dev
Summary:
Prepare configs locally that can be passed to any Mononoke binary where things
/just work/.

Reviewed By: HarveyHunt

Differential Revision: D19952512

fbshipit-source-id: 14a3b520972b0bdf4fa7810805066ba746bbef1a
2020-02-19 08:08:08 -08:00
Lukas Piatkowski
d1f8ed1806 mononoke: make blobstore OSS-buildable
Summary: Adds the Cargo.toml files for blobstore, this is a step towards covering mononoke-types, so only the blobstore traits are covered by this diff.

Reviewed By: aslpavel

Differential Revision: D19948739

fbshipit-source-id: c945a9ca16ccceb0e50a50d941dec65ea74fe78f
2020-02-19 05:15:18 -08:00
Lukas Piatkowski
72c1a6c0d4 common/rust: remove unused asyncmemo from the codebase
Reviewed By: aslpavel

Differential Revision: D19948742

fbshipit-source-id: 43ecb4885f4385adb7598bdec875171e69bb2ffa
2020-02-19 05:15:17 -08:00
Lukas Piatkowski
c4f0887fc2 eden/scm: cover xdiff with autocargo
Summary: Generate the Cargo.toml files inside xdiff with autocargo. This will enable Mononoke to depend on this code easily without sacrificing anything on eden/scm side.

Reviewed By: aslpavel

Differential Revision: D19948741

fbshipit-source-id: 905ff3d64b90830e5f075e4c6ed2b3de959e3f00
2020-02-19 05:15:17 -08:00
svcscm
f9ed23693b Updating submodules
Summary:
GitHub commits:

736a98024b
0d977a3da7
5f99a7d8b0

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 735714dad63be0fa0865979fe83563a4f8971d6e
2020-02-19 05:15:17 -08:00
svcscm
04fc6925dc Updating submodules
Summary:
GitHub commits:

7903fc3142
462eaef5fc
e2966a7507
09013ed8c4
df7e47c39b
f40e6d1dbf

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 37553007eb60438d5ddd9cb16f0edc24e4637c25
2020-02-18 23:26:33 -08:00
David Tolnay
91cb486949 rust: Begin upgrading to bytes 0.5
Summary:
This upgrade is complicated because Tokio's codecs are coupled to a specific version of bytes.

- 0.1 codecs use bytes 0.4
    - https://docs.rs/tokio-codec/0.1/tokio_codec/trait.Encoder.html
    - https://docs.rs/tokio-codec/0.1/tokio_codec/trait.Decoder.html

- 0.2 codecs use bytes 0.5
    - https://docs.rs/tokio-util/0.2/tokio_util/codec/trait.Encoder.html
    - https://docs.rs/tokio-util/0.2/tokio_util/codec/trait.Decoder.html

Since we can't possibly do a coordinated atomic upgrade of tokio, we'll be straddling bytes versions during the migration period. This relies on the adapters added in D19919402.

Reviewed By: jsgf

Differential Revision: D19919403

fbshipit-source-id: 18c5f66efa587bc53ab13c9aab95c7098bfbce4e
2020-02-18 21:20:09 -08:00
svcscm
0ab1772cb0 Updating submodules
Summary:
GitHub commits:

45fbce085a
80905eeb79
a432b68cff
7291fd5a96
bd969f94c9

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 722c96cb6920636a9e0559472e4e3b50dd50ea99
2020-02-18 19:59:14 -08:00
Jun Wu
3a5b53134e hint: update revnum deprecation message
Summary: It's 2020 now.

Reviewed By: xavierd

Differential Revision: D19958630

fbshipit-source-id: 143d57e060acb150461151b31d82bb6bfefe3c91
2020-02-18 18:06:26 -08:00
svcscm
840d55b0e3 Updating submodules
Summary:
GitHub commits:

19910c3777
5a297516e1

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 5e311564cf8ee951b299212b4311693f91b94901
2020-02-18 17:36:54 -08:00
Jun Wu
ad6eb1928b treemanifest: make prefetchdraftparents non-fatal
Summary:
Not being able to prefetch draft parent trees should not be considered as a
fatal error.

This code path is causing trouble with narrow-heads clone:

1. Streaming clone. The client gets a changelog.
2. The client runs "pull" to get new commits. The prefetchdraftparents code path runs.
3. The client has stale remote names, and public() is lagging. `prefetchdraftparents`
   will try to fetch trees at the old master, but the repo is not configured properly.

That causes a stacktrace like:

  $ /usr/bin/hg --config 'extensions.fsmonitor=!' clone --shallow -U --config 'ui.ssh=ssh -oControlMaster=no' --configfile /etc/mercurial/repo-specific/www.rc ssh://hg.fb.com/repo repo
  connected to hg.fb.com
  streaming all changes
  searching for changes
  adding commits
  adding manifests
  adding file changes
  added 1 commits with 0 changes to 0 files  # <<<< No traceback if this says "0 commit".
  Traceback (most recent call last):
    File "edenscm/hgext/remotenames.py", line 1464, in exclonecmd
      orig(ui, *args, **opts)
    File "edenscm/hgext/remotefilelog/__init__.py", line 433, in cloneshallow
      orig(ui, repo, *args, **opts)
    File "edenscm/mercurial/commands/__init__.py", line 1615, in clone
      shareopts=shareopts,
      # shareopts = {'mode': 'identity'}
    File "edenscm/mercurial/hg.py", line 741, in clone
      exchange.pull(local, srcpeer, revs, streamclonerequested=stream)
    File "edenscm/mercurial/util.py", line 621, in __exit__
      self.close()
    File "edenscm/mercurial/transaction.py", line 46, in _active
      return func(self, *args, **kwds)
    File "edenscm/mercurial/transaction.py", line 543, in close
      self._postclosecallback[cat](self)
      # cat = bin('6472616674706172656e74747265656665746368')
    File "edenscm/hgext/treemanifest/__init__.py", line 490, in _parenttreefetch
      self.prefetchtrees([c.manifestnode() for c in draftparents])
      # c = <changectx b5ad643b3009>
      # draftparents = [<changectx b5ad643b3009>]
    File "edenscm/hgext/treemanifest/__init__.py", line 522, in prefetchtrees
      self._prefetchtrees("", mfnodes, basemfnodes, [], depth)
      # basemfnodes = [bin('a25f17018d7cd07f1f6bc3076f95c5980ba087a9')]
      # mfnodes = [bin('ad717aac7700e783a1d84f3330d13a7731a4726a')]
    File "edenscm/hgext/treemanifest/__init__.py", line 529, in _prefetchtrees
      fallbackpath = getfallbackpath(self)
    File "edenscm/hgext/treemanifest/__init__.py", line 2173, in getfallbackpath
      if util.safehasattr(repo, "fallbackpath"):
    File "edenscm/mercurial/util.py", line 190, in safehasattr
      return getattr(thing, attr, _notset) is not _notset
      # attr = 'fallbackpath'
    File "edenscm/mercurial/util.py", line 904, in __get__
      result = self.func(obj)
    File "edenscm/hgext/remotefilelog/shallowrepo.py", line 42, in fallbackpath
      "no remotefilelog server " "configured - is your .hg/hgrc trusted?"
  Abort: no remotefilelog server configured - is your .hg/hgrc trusted?
  abort: no remotefilelog server configured - is your .hg/hgrc trusted?

Fix it by making prefetchdraftparents non-fatal. This would hopefully unblock
narrow-heads rollout.

Reviewed By: xavierd

Differential Revision: D19957251

fbshipit-source-id: e65bbe6bf422776effe49055f7332ec538177a41
2020-02-18 17:36:54 -08:00
Puneet Kaushik
b6af823950 Fixing Windows build by removing shutdown event logging
Reviewed By: genevievehelsel

Differential Revision: D19863374

fbshipit-source-id: cf74e323d2e49c8bf9459d585343ba65112dbf55
2020-02-18 16:48:29 -08:00
Puneet Kaushik
69435b554a Moving Notifications out of Windows build
Summary: Notifications is using folly Subprocess which doesn't work on Windows.

Reviewed By: genevievehelsel

Differential Revision: D19863375

fbshipit-source-id: 63b047253c0f8a48b1b0ccc767f5820e77a28d80
2020-02-18 16:48:28 -08:00
svcscm
5126050bb0 Updating submodules
Summary:
GitHub commits:

996a6f2c29

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 672b5bb57cc33def28c64599488b9dc3a4b75112
2020-02-18 16:48:28 -08:00
svcscm
b9aaf33364 Updating submodules
Summary:
GitHub commits:

def8c9a5ef
c6abe30ee3

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 6b57a0a88458d3260e07571419d8d6439b961d0a
2020-02-18 14:35:35 -08:00
Liubov Dmitrieva
3163d20016 commitcloud: log errors to scuba
Summary:
This will allow us to improve our dashboards filtering out errors we are
responsible for, like missing certs on the machines.

Reviewed By: mitrandir77

Differential Revision: D19950614

fbshipit-source-id: 73503e984dfe8513a700fdcb2fc36b1618c20a4f
2020-02-18 14:28:33 -08:00
Puneet Kaushik
2c67abae24 Adding null ObjectFetchContext to Fixing Windows build
Reviewed By: simpkins

Differential Revision: D19776610

fbshipit-source-id: 89c7aa1b22b9ed6862ad3e1208695ad0e7cf3d46
2020-02-18 13:30:42 -08:00
Mark Thomas
0387f1c67e localrepo: add configurable limits for description and extras
Summary:
Commit messages and extras can be unbounded in size.  This can cause problems if users create commits with exceptionally large messages or extras.  Mercurial will commit these to the changelog, increasing its size.  On Mononoke, large commit messages may go over the cacheing threshold, resulting in poor performance for requests involving these commits as Mononoke will need to reload on every access.

Commit messages should not usually be that large.  Mostly likely it will happen by accident, e.g. through use of `hg commit -l some-large-file`. Prevent this from happening by accident by adding configuration for soft limits when creating commits.

If a user really does need to create a commit with a very large message or extras, they can override using the config option.

Reviewed By: xavierd

Differential Revision: D19942522

fbshipit-source-id: 09b9fe1f470467237acc1b20286d2b1d2ab25613
2020-02-18 13:12:58 -08:00
svcscm
fc1323019f Updating submodules
Summary:
GitHub commits:

08d358626f

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: 36b4c630bb3c2ea572cefa5fd2592c2a566f1448
2020-02-18 12:47:03 -08:00
Adam Simpkins
1a263466c6 remove the unused sparsematchfn dirstate parameter
Summary:
This parameter was originally removed in D12811551, but re-added in D12855935
due to the fact that at the time the `eden_dirstate.py` and `dirstate.py`
files were deployed in separate RPMs and could not be updated together
atomically.  We now deploy these files together, so we can drop this extra
unnecessary argument.

Reviewed By: chadaustin

Differential Revision: D19913057

fbshipit-source-id: 0f0b4fde4b3124a8fc5bb568551b4e67de14d410
2020-02-18 11:39:22 -08:00
Jerry Liang
8c34859329 Push compat down one level in fbcode/eden/mononoke/benchmark/benchmark.rs
Summary:
- Pushing .compat down from main into run function and switch to 0.3 timed function

Note: Possible next level of pushing down: pushing .compact into derive_fn and get rid of BoxFuture run's signature.

Reviewed By: ikostia

Differential Revision: D19943392

fbshipit-source-id: 65bd84492855d3e2e560299a586af6dd4fe9c3ea
2020-02-18 11:01:12 -08:00
svcscm
82834552f1 Updating submodules
Summary:
GitHub commits:

75bb459654
fc1945c2e0
332a31a145
2b6eef4dc9

Reviewed By: 2d2d2d2d2d

fbshipit-source-id: d105b9aa5001c53f884f007406684b73809a7680
2020-02-18 10:20:45 -08:00
Jun Wu
795b679d60 doctor: support efficient treestate (dirstate) repair
Summary:
Sometimes the treestate points to an unknown commit (ex. aborted transaction
might strip commits). While `debugrebuilddirstate -r HASH --hidden` is able to
fix it, it is too slow.

This diff adds treestate repair logic to the `doctor` command. It scans through
the treestate files, find a most recent `Root` entry with `p1` pointing to a
known commit.

This can be much faster than `debugrebuilddirstate` in some cases, because the
watchman clock might still be valid, and the NEED_CHECK file list might still
be small. In that case, `status` can still be fast.

Since treestate atomically updates all information needed for `status`
calculation (parents, need-check-files (or, "non-normal files"), watchman-clock
(only with fsmonitor), and stat for clean files). Reverting to a previous state
is still atomic. Correctness-wise, this is equivalent to aborting a "large"
transaction, and restoring treestate data to the state before the transaction.
It should be consistent, and the next `status` call won't mis-report files like
the dangerous `debugsetparents` command.

Reviewed By: DurhamG

Differential Revision: D19864422

fbshipit-source-id: d5d2f8b43a0c15ea2ac0e3c164edec7deeb8451f
2020-02-18 09:41:32 -08:00
Jun Wu
bc7c3c1e24 doctor: remove invalid commits in visibleheads
Summary:
See the test change. Without this change repairing the changelog won't give the
user back a working repo.

Reviewed By: markbt

Differential Revision: D19864421

fbshipit-source-id: b84582c5302469828c8cfcb3db362ea82f2eea63
2020-02-18 09:41:31 -08:00
Jun Wu
febe96048e doctor: integrate fixcorrupt logic to repair changelog
Summary:
Reuse utilities in the fixcorrupt extension to repair changelog.

This is better than fixcorrupt because `hg doctor` does not require a repo
object. Some messages are updated so they become more consistent with the
rest of `hg doctor`.

The main motivation is to get changelog fixed early, so other repair logic can
check if a commit hash is known by changelog or not.

Reviewed By: markbt

Differential Revision: D19864418

fbshipit-source-id: 6f95c6c6191d7db2a474a07a5278a857cf41d8e2
2020-02-18 09:41:31 -08:00
Jun Wu
6f2b529e94 doctor: run 'edenfsctl doctor' on edenfs repos
Summary:
Run 'edenfsctl doctor' on an edenfs repo. If there is no current repo, it might
be caused by edenfs daemon stopped running. So let's also run edenfsctl doctor
in that case.

Reviewed By: markbt

Differential Revision: D19864419

fbshipit-source-id: d2a49a126a040845b88b4883d214162326d08d8d
2020-02-18 09:41:30 -08:00
Durham Goode
99a829340b py3: move sampling to use mercurial.json
Summary:
We're seeing a user have issues because their username contains unicode
characters and sampling's use of json doesn't handle it well. I've not been able
to repro it unfortunately, but let's go ahead and switch sampling to use
mercurial.json.

Differential Revision: D19895419

fbshipit-source-id: a1f087d1e2c7568488c2b8d54f267bd5c8266202
2020-02-18 09:36:28 -08:00
Xavier Deguillard
d8064b5e2a types: add a Sha256 type
Summary: This will be used in the LFS store.

Reviewed By: DurhamG

Differential Revision: D19895803

fbshipit-source-id: 4cf447987c10fed0b5c98904f20c841428965d89
2020-02-18 08:32:33 -08:00
Xavier Deguillard
17cc9ab5ab revisionstore: add a wrapper around IndexedLog/RotateLog
Summary:
In some cases, higher level stores may want to store data in either a plain
IndexedLog, or in a RotateLog, for local and shared data. Due to slight
difference between the 2, they can't easily be adapted into a common trait.

Instead let's just wrap both into an enum and implement the main functions that
the higher level stores need.

The first use of this will be the LfsStore, future use will include the
IndexedLogDataStore and the IndexedLogHistoryStores.

Reviewed By: DurhamG

Differential Revision: D19859292

fbshipit-source-id: 920572e0cf5f69bda4901a727a6b0dc0f08fc8d0
2020-02-18 08:32:32 -08:00
Genevieve Helsel
9b8960eef4 add success field to daemon start logging
Summary: records if a start was successful or not

Reviewed By: simpkins

Differential Revision: D19817810

fbshipit-source-id: b67253099781bb534b7e2fb26a09ba41c1f0bd69
2020-02-18 08:05:51 -08:00
Genevieve Helsel
9c03c5a769 log when a graceful restart is requested
Summary: log when a graceful restart is requested

Reviewed By: simpkins

Differential Revision: D19826640

fbshipit-source-id: 0e2b4ccb36d695a5687386235c8d707461b6e4f3
2020-02-18 08:05:50 -08:00
Genevieve Helsel
175efb9fd1 log when CLI sends sigkill during stop
Summary: Since we cannot log this case from the daemon because we can't catch sigkill, log failed stop from CLI layer.

Reviewed By: simpkins

Differential Revision: D19826140

fbshipit-source-id: eb3aa27802db0206a13e552c4cb1384f856905d2
2020-02-18 08:05:50 -08:00
Genevieve Helsel
c304e34c2d cli scuba logging setup
Summary:
this is used up the stack. This introduces generic scuba logging for the cli layer. In case of the open source build, `log` will be a no-op as suggested in `cli/telemetry.py`.

this is used as so:
```
from .telemetry import build_base_sample, log
# for example, I am adding the field "status" to know that this is a status call.
sample = instance.build_sample("status").add_string("something", "another")
instance.log(sample)
```

Reviewed By: simpkins

Differential Revision: D19816913

fbshipit-source-id: b055d4d1e29456e3549292e6f5047b935f11e4e2
2020-02-18 08:05:49 -08:00
Doug Neal
8e684cfda7 mononoke: lfs_server: add jitter field to ratelimit struct
Summary: Add the max_jitter_ms field to the rate limiting config struct, and to the integration test.

Reviewed By: HarveyHunt

Differential Revision: D19905068

fbshipit-source-id: b44251c456a45bc494d1080e405f2d009becc0d2
2020-02-18 07:47:09 -08:00
Thomas Orozco
49808a4410 mononoke/hg_sync_job: use 0.2 runtime
Summary:
This is required for 0.2 timers or runtime reliant code to work within the sync
job. To achieve this, we need to get of Tokio 0.1 fs code, which is
incompatible with Tokio 0.2 because it uses `blocking()`.

Reviewed By: ikostia

Differential Revision: D19909434

fbshipit-source-id: 58781e858dd55a9a5fc10a004e8ebdace1a533a4
2020-02-18 07:42:41 -08:00
Thomas Orozco
b451a97878 mononoke/warm_bookmarks_cache: use the repo's configuration
Summary:
This update the warm_bookmarks_cache's constructor to use the passed in
blobrepo's derived data configuration (instead of whatever the caller is
passing in), since we now have that information.

Reviewed By: HarveyHunt

Differential Revision: D19949725

fbshipit-source-id: 575a1b9ff48f06003dbf9e0230b7cca723ad68f5
2020-02-18 07:40:25 -08:00