Summary: APFS volume names have a length limit of 128, so we need to hash mount point to make sure we do not error out. Right now what happens if we get an error, but we do still successfully mount and the volume name is just truncated. Since we errored, we don't store this information anywhere. Instead now, we will check the volume name, and if it is too long, we hash the volume name in order to mitigate the "name too long" error.
Reviewed By: wez
Differential Revision: D22327372
fbshipit-source-id: d68f90472c1d952879078d0541b341d271c17092
Summary: Makes the hostname available for dynamicconfig conditions.
Reviewed By: quark-zju
Differential Revision: D22537946
fbshipit-source-id: 630ee833bb3ec00253d718b3d03bbb8b3d49afca
Summary: Adds support for sharding based on user name.
Reviewed By: quark-zju
Differential Revision: D22537540
fbshipit-source-id: 962f9582c8947335dc9d9d29c500d8c09df69878
Summary:
Turned out we have perfpipe_hgerrors and perfpipe_hg_errors. Having both of
them is quite confusing, so I suggest to only use perfpipe_hg_errors
We don't seem to have any alarms on these tables, so renaming should be esy
Reviewed By: quark-zju
Differential Revision: D22546855
fbshipit-source-id: a450444e8c2270603c3146f4f05072029f935f4d
Summary:
D22526230 (7ab2c54f08) adds extra output.
The test seems to be skipped in buck test due to the hgsql requirement.
Reviewed By: kulshrax
Differential Revision: D22555707
fbshipit-source-id: 8659de3cda517a49296c747e65bfbd0d372c031a
Summary: `int / int` gives `float` on Python 3 and that can cause issues.
Reviewed By: singhsrb
Differential Revision: D22563891
fbshipit-source-id: 443245710a0d2de660019f03845bed0077d62889
Summary: We have several repos whose names contain various non-alphanumeric/underscore/hyphen characters, so we need to be more permissive about accepting repo names.
Reviewed By: quark-zju
Differential Revision: D22554846
fbshipit-source-id: e7bb030e0b8fb6aa275c119ba0aa540405b29186
Summary:
Previously, the EdenAPI stores would not report errors returned from the remote store. The intention behind this pattern in other stores is to prevent `KeyError`s from aborting the operation since the local store might still have the key.
However, in the case of the EdenAPI store, EdenAPI will simply omit missing keys in its response rather than returning an error. Instead, any error returned by the EdenAPI store indicates a more fundamental problem (e.g., unable to reach the server, connection reset, etc) which should cause an abort and return the error.
Reviewed By: quark-zju
Differential Revision: D22544031
fbshipit-source-id: e01e8d88b75e46dcebd2eef5203e3a0edde69fc7
Summary: When working with large CBOR responses, it is sometimes useful to limit processing to the first N entries to prevent the operation from taking a long time. This diff adds an option to the `read_res` tool to only look at the first N entries in a data or history response.
Reviewed By: quark-zju
Differential Revision: D22544451
fbshipit-source-id: 5e8e2c7212aa3b315a25bd4cf9273009a5e43f72
Summary:
The pure Python `nodesbetween` implementation relies on raw revlog details and
weirdness (ex. `index[len(repo)]` returns `nullid`). Replace them with cleaner
code paths.
Reviewed By: DurhamG
Differential Revision: D22368831
fbshipit-source-id: c7eb0c2bb2759e9fb574afc63ad2b398d7b17d38
Summary:
We got user reports about failing hg log call -
https://fb.workplace.com/groups/scm/permalink/3016242448425355/.
If we can't fetch the data from graphql then we try to e.msg, however we don't
have such a field. We have e.message instead.
This diff fixes it, and also adds new line to make formatting better.
Reviewed By: quark-zju
Differential Revision: D22548251
fbshipit-source-id: 117489d8e6a22ab5bc43be1154697398086508d0
Summary: Some repos do not have `remotefilelog.reponame` set, so this shouldn't be a required config item.
Reviewed By: fanzeyi
Differential Revision: D22553141
fbshipit-source-id: a0fe9c289a1a32650572a4c123cda60af90e79ec
Summary:
When we build boost 1.69.0 with newer version of Xcode, it will fail with:
```
clang: error: unknown argument: '-fcoalesce-templates'
```
This commit fixes this build failure by telling boost's build system that we are building with clang on macOS.
Reviewed By: chadaustin
Differential Revision: D22417488
fbshipit-source-id: 0b3d22835abbba6d06812c656acb0311a60d8c67
Summary:
Introduce new rust library, taggederror, which contains utilities for attaching metadata to errors. The library provides two main methods for attaching metadata to an error, the TaggedError wrapper type, and the AnyhowExt trait methods. Provides a struct, CommonMetadata, which contains all the metadata types introduced by taggederror (fault, transience, category, and typename), which can also be attached individually (and the same pattern can be used to attach other metadata).
Introduce a new native rust command, debugthrowrustexception, which causes the command to return an error, with some attached metadata.
Modify hg rust native command dispatch error handling to use debug formatter to print anyhow::Error errors. This will print out the source chain, contexts, and backtrace if available, which will cause the metadata we attach as a wrapper error or context to be printed.
Reviewed By: DurhamG
Differential Revision: D22420941
fbshipit-source-id: d38c5a10b686d86b69a2c0a19f5bcbf4ca24dff6
Summary:
Increase the max limits for repo_list_bookmarks and commit_list_descendant_bookmarks
from 1,000 to 10,000. The higher number is still reasonable for a single request,
and this reduces the number of round-trips when there are lots of bookmarks.
This updates the constants in the thrift definition. The server was updated to accept
higher limits in a previous diff.
Reviewed By: mitrandir77
Differential Revision: D22524891
fbshipit-source-id: bc47c1e50af35f213ebcfbca1574669e79b2fe92
Summary:
ODS counters are helpful to know if the feature is turned on or off without
requiring a traffic spike, so let's log them. Also, let's add timeouts in here,
so we know if things aren't working as expected (I did check in the Mononoke
LFS dataset — 10ms is a very conservative number, that's way beyond the p99 of
batch requests, which include potentially many counter checks).
To make this easier to iterate on, let's also add tests.
Reviewed By: StanislavGlebik
Differential Revision: D22545853
fbshipit-source-id: 02ea4484a4e4ba0dfd4a71030c129eb5c6bb1ec9
Summary:
Previously you could only canary locally on a devserver by setting an
environment variable. Let's add a --canary flag to debugdynamicconfig that
accepts a host. Hg will ssh to that host and run the configerator cli to grab
the canaried config from that host.
Reviewed By: quark-zju
Differential Revision: D22535509
fbshipit-source-id: af1c21d8402c4e729769e50388d913bf52b66b89
Summary:
Previously we had no way of specifying an optional string flag. This
adds support.
I considered making the implementation more generic, so it'd support
Option<i64> and potentially Option<bool> but it introduced some complexity and
didn't seem worth the effort for now.
Reviewed By: quark-zju
Differential Revision: D22535511
fbshipit-source-id: 04d7b5419ca7ae44a9aeff1a5cea2c3043d80042
Summary:
Previously we didn't print the error, and it made debugging harder (see for
example this case). Let's print the error.
Reviewed By: singhsrb
Differential Revision: D22526230
fbshipit-source-id: e431199d0273183324df7938df28934cd186658c
Summary:
To help investigate a Linux kernel performance dropoff where the
kernel falsely thinks the EdenFS FUSE mount can't handle dirty page
writes at a high rate, add a 4k random writes benchmark.
Reviewed By: simpkins
Differential Revision: D21328771
fbshipit-source-id: c9977bd2e291d01e92631094aba3d8d807ec62da
Summary:
The `helpers-testrepo.sh` runs something like
hg files --cwd /path/to/fbsource/fbcode/eden/scm/tests/
to check if `hg` works or not. Previously it fails fast because of the
lz4revlog requirement. The next diff will enable lz4revlog that makes
`hg files` work.
That `hg files` command (if does not fail) is quite expensive because it has no
patterns and lists every file.
It can also be undesirable if the in-repo hg does some kind of auto migration
that makes the repo unusable by the system hg. Therefore just unconditionally
use the system hg.
Reviewed By: DurhamG
Differential Revision: D22419967
fbshipit-source-id: 2d5c75696efecce1ec38a2e4fa23aff101219545