Commit Graph

67610 Commits

Author SHA1 Message Date
Arun Kulshreshtha
b9a95f33a3 http-client: implement seek() for Buffered and Streaming handlers
Summary:
Some users have reported errors of the form:
```
error.HttpError: [65] Send failed since rewinding of the data stream failed (seek callback returned error 2)
```

These are caused by the fact that we're passing the HTTP request body directly to libcurl in memory rather than via a file, but we haven't implemented the `seek()` method necessary for libcurl to retransmit the data if needed. This diff implements the method.

Reviewed By: DurhamG

Differential Revision: D30654625

fbshipit-source-id: f21a067ad02ee540b86cf2e6eff2c6f08f45a3e4
2021-09-02 08:26:02 -07:00
svcscm svcscm
a6d2529c33 Updating submodules
Summary:
GitHub commits:

80e6cadae5

Reviewed By: yns88

fbshipit-source-id: 2305112fa3eef43f14639e2ddf0ad4c29336a47c
2021-09-02 07:27:54 -07:00
Thomas Orozco
35e3466031 third-party/rust: update daemonize to 0.5
Summary:
Like it says in the title, this updates us to use Daemonize 0.5, though from
Github and not Crates.io, because it hasn't been released to the latter yet.

The main motivation here is to pull in
https://github.com/knsd/daemonize/pull/39 to avoid leaking PID files to
children of the daemon.

This required some changes in `hphp/hack/src/facebook/hh_decl`  and `xplat/rust/mobium` since the way to
run code after daemonization has changed (and became more flexible).

Reviewed By: ndmitchell

Differential Revision: D30694946

fbshipit-source-id: d99768febe449d7a079feec78ab8826d0e29f1ef
2021-09-02 06:27:03 -07:00
svcscm svcscm
02604e98b0 Updating submodules
Summary:
GitHub commits:

f6e7be6ee1

Reviewed By: yns88

fbshipit-source-id: f49f5a1e3f4d4ae2d7406902bf61cb1da7dd1536
2021-09-02 04:27:33 -07:00
Stanislau Hlebik
60d6172ea0 mononoke: make it possible to force reload segmented changelog
Summary:
At the moment when segmented changelog is updated and/or reseeded mononoke
servers can pick it up only once an hour (this is a current reload schedule)
or when mononoke server is restarted. However during production issues (see
attached task for an example) it would be great to have a way to force all
servers to reload segmented changelog.

This diff makes it possible to do so with a tunable. Once tunable changes its
value then monononoke servers almost immediately (subject to jitter) reload it.

This implementation adds a special loop that polls tunables value and reloads
if it changes. Note that in theory it could avoid polling and watch for configerator
changes instead, but it would be harder to implement and I decided that it's
not worth it.

Reviewed By: farnz

Differential Revision: D30725095

fbshipit-source-id: da90ea06715c4b763d0de61e5899dfda8ffe2067
2021-09-02 04:27:33 -07:00
Meyer Jacobs
9cdd1c0e96 scmstore: chunk prefetch calls to avoid OOM
Summary:
Previously, extremely large prefetch calls could cause an OOM if the requested files were all fetched remotely from EdenApi, in which case the memory would remain in use until the entire batch had been fetched.

With this change, at most 1000 EdenApi files will be held in memory at once (or 10GB of memory). This is a stop-gap solution, a better approach would be to avoid storing all EdenApi files in memory after a certain amount, or allow the batch fetching implementation to understand we're only prefetching, and thus avoid reading anything back from disk or storing EdenApi files in memory unnecessarily.

Reviewed By: andll

Differential Revision: D30686054

fbshipit-source-id: 022e353760c515961a8956f7958b43f429143971
2021-09-02 03:31:04 -07:00
svcscm svcscm
69a6965b50 Updating submodules
Summary:
GitHub commits:

a98ffabee7
a6750c531c
2edb670b06
8f5e191741

Reviewed By: yns88

fbshipit-source-id: c6dfcd51714cee2b50ca2c14bddb344903e94582
2021-09-02 03:31:04 -07:00
Thomas Orozco
0d2bfbeccd Update autocargo component on FBS:master
Summary:
Manual component version update
Bump Schedule: https://www.internalfb.com/intern/msdk/bump/?schedule_fbid=342556550408072
Package: https://www.internalfb.com/intern/msdk/package/181247287328949/
Oncall Team: rust_foundation
NOTE: This build is expected to expire at 2022/09/01 09:14AM PDT
---------
New project source changes since last bump based on D30663071 (08e362a355e0a64a503f5073f57f927394696b8c at 2021/08/31 03:47AM -05):
| 2021/08/31 04:41AM -05 | generatedunixname89002005294178 | D30665384 | [MSDK] Update autocargo component on FBS:master |
| 2021/08/31 07:14PM PDT | kavoor | D30681642 | [autocargo] Make cxx-build match version of cxx |
| 2021/09/01 04:05PM BST | krallin | D30698095 | autocargo: include generated comment in OSS manifests |
---------

build-break (bot commits are not reviewed by a human)

Reviewed By: farnz

Differential Revision: D30717040

fbshipit-source-id: 2c1d09f0d51b6ff2e2636496cf22bcf781f22889
2021-09-02 02:33:56 -07:00
svcscm svcscm
5304274a7d Updating submodules
Summary:
GitHub commits:

b181059e89

Reviewed By: yns88

fbshipit-source-id: bbb509f17dd45463f292ced3e2c52528e3ac505b
2021-09-02 02:31:41 -07:00
svcscm svcscm
b9149b343a Updating submodules
Summary:
GitHub commits:

908f5ebefa
f65e4f23f8
958ed9c422
bd2b357559

Reviewed By: yns88

fbshipit-source-id: a5649a4ecf826f30884f35672d1925533c752999
2021-09-02 00:34:07 -07:00
svcscm svcscm
49ac569231 Updating submodules
Summary:
GitHub commits:

ffc35d8280
0066df00f0
ad19131831
590bd72abf
aa9878b215
174fc14d82

Reviewed By: yns88

fbshipit-source-id: a70fdbfa75a7e8ef7d95e131800b85d20a296d41
2021-09-01 23:25:40 -07:00
svcscm svcscm
bec57768a0 Updating submodules
Summary:
GitHub commits:

2514f078f4
eec533b6cc
dfcb9ea5fa
b00d5fb188
0f99cce19a

Reviewed By: yns88

fbshipit-source-id: ced6cf79d500ec2ae835c21c314718e47bf43862
2021-09-01 22:29:26 -07:00
svcscm svcscm
729d92c77e Updating submodules
Summary:
GitHub commits:

49da54db2a
096965dc3c
890ace5afd
282c8bcf19
e8a7001159
5fb8bc0f3a
b43e87a299
7e02f8f28e

Reviewed By: yns88

fbshipit-source-id: ed7ef6406e34e89e6fa07011a1b6f28fece89472
2021-09-01 21:37:59 -07:00
svcscm svcscm
54f2561c4a Updating submodules
Summary:
GitHub commits:

8ef22aa51e
c4e4d7a1e3
4f9cadf3b6
81297b86c1
2cd9851d2f
136e41a580
a1dafbedba
d0d9b48453
1915980093

Reviewed By: yns88

fbshipit-source-id: 97119a7675858f8e76cb41509bd47c469065ab3b
2021-09-01 19:26:12 -07:00
svcscm svcscm
caea670188 Updating submodules
Summary:
GitHub commits:

c2ccacb373
613d1fdd63
bf7c35030a
be2295daf2
71bbe79abd
9c5c50fcc0
7c1a746e0e
9ab75da784
da9763374f
c2febefb55
c2eb5134c2
3af86b08c7

Reviewed By: yns88

fbshipit-source-id: e13e61479c11ab3e122af0a97dd6a7c11920cee1
2021-09-01 18:28:53 -07:00
Yipu Miao
d7afd687ea Rename fbthrift_ext to fbthrift_ext-02
Summary: Keep two versions of fbthrift_ext that one with tokio-0.2 and the other with tokio-1.x. This diff is just renaming.

Reviewed By: dtolnay

Differential Revision: D30558441

fbshipit-source-id: bfe7e96b95529f2745f635190df5118a0cb44014
2021-09-01 18:28:53 -07:00
svcscm svcscm
80d4b7335e Updating submodules
Summary:
GitHub commits:

e6b8efb176
23419bd0f6
0092442bb2
4ae8b4df0f
ff34b290fa
2e03abf9df
dc7b7133e5
fa1cf04640
c07ecb1c4f
a6d068b3e3
016a51a173

Reviewed By: yns88

fbshipit-source-id: 395d00e40970daeed869831947bd28a0acdfd963
2021-09-01 17:28:01 -07:00
svcscm svcscm
edfbbfbe94 Updating submodules
Summary:
GitHub commits:

8e7b733de0
ed33c339ea
df8714a6d1
1424eadb83
b32dbbcea2
af292cef27
7cc809e446
6e8ec89b92
79aac633f1
e975d99768
77f487939b
22dd1197de
ac9044e401

Reviewed By: yns88

fbshipit-source-id: 49b8775d2b8eefe89aa76d924846d670e81c61d6
2021-09-01 16:30:10 -07:00
Xavier Deguillard
69159f20d5 store: split the blob/tree/prefetch queue
Summary:
Having the same queue for all three makes the dequeue code overly complicated
as it needs to keep track of the kind of request that needs to be dequeued.
Incidently, the previous code had a bug where request in "putback" would be
requeued at the end of the queue, even though there were at the beginning of it
if they all had the same priorities.

This is theory should also improve the dequeue performance when the queue has a
mix of blobs/tree requests, but I haven't measured.

Reviewed By: genevievehelsel

Differential Revision: D30560490

fbshipit-source-id: b27e5429105c07e5f9eab482c12e5699ca3413f7
2021-09-01 14:29:27 -07:00
Xavier Deguillard
54de90fa1b service: background actual prefetch of files
Summary:
Since the background condition is before the actual prefetching of files,
specifying the background option would just glob files but not prefetch them
which is equivalent to prefetching all the trees.

Reviewed By: genevievehelsel

Differential Revision: D30618753

fbshipit-source-id: 5533b1c78d614342ac3341ce033795be3850750a
2021-09-01 14:29:27 -07:00
svcscm svcscm
f87ca0258c Updating submodules
Summary:
GitHub commits:

7db90ebbd0
a1972f8679
a160fd8e85
a782676bbc
8084715adc
3ad284b879
19af4061d9
1d04c37775
bca70f0bfa
60f11748b2
0846b809ad
ffcc83a93a
4f35477729
2c83c515b8
e4a5d407e0
379e31189b
7fbf128f30

Reviewed By: yns88

fbshipit-source-id: 6d5c99c2c9bdde4a6c4e5be8678754eda9e8eaf6
2021-09-01 14:29:27 -07:00
Meyer Jacobs
edad2caf13 scmstore: fix warnings on master
Summary:
It looks like a few scmstore changes landed with warnings (probably fixed higher up in the tree unification stack).

This change fixes those warnings.

Differential Revision: D30686092

fbshipit-source-id: d80625dea64f35683f815b58c83a3e5bb7cbdfa8
2021-09-01 11:26:24 -07:00
Durham Goode
81d2d0f010 sparse: fix sparse profile refreshes during hg commit
Summary:
When we remove a file from a sparse profile and commit the profile, it
should delete the file on disk. There's a bug where it doesn't actually delete
the file. This fixes it by passing the correct commit parents to the refresh
function.

Reviewed By: andll

Differential Revision: D30683677

fbshipit-source-id: 7f012faa99975d8270209f2962e7f9236890daed
2021-09-01 10:27:30 -07:00
Jun Wu
58ab76f9f0 dag: avoid excessive remote lookup during id reassignment
Summary:
Use `populate_missing_vertexes_for_add_heads` (added by D27630093 (f138b012e9)) to avoid
excessive lookups for non-master ids that remain in non-master.  The function
was used in two other `flush` cases, but missed the id reassignment case.  It
works basically by using the "discovery" logic to quickly rule out what's
missing and what's present (ex. if a root is missing in the server graph, then
all descendants of the root is missing).

Reviewed By: andll

Differential Revision: D30700451

fbshipit-source-id: 1f1cd88399dbffd4af75083fef1f3e363a5c60fe
2021-09-01 10:27:30 -07:00
Jun Wu
5baa4c5f51 dag: add test case to demonstrate excessive remote lookup during id reassignment
Summary: During reassigning non-master ids, it might trigger too many remote lookups.

Reviewed By: StanislavGlebik

Differential Revision: D30700452

fbshipit-source-id: 2483335e466c3de8a362f7b6a15fc4ba9e2693be
2021-09-01 10:27:30 -07:00
Jun Wu
7eb11cb392 revlogindex: implement octopus merge support
Summary:
Support octopus merge defined in the following format:

- The revlog flag has `1 << 12` set.
- Extra `stepparents` is set to `hexnode1,hexnode2,...` format.

This is mainly used to support revlog from stream clone.

Reviewed By: StanislavGlebik

Differential Revision: D30686450

fbshipit-source-id: d5aa2f18a02f5f0d7aa033210fb4f79b729c0d26
2021-09-01 09:25:33 -07:00
Jun Wu
b13579fdf9 revlogindex: extend ParentRevs to support more than 2 parents
Summary:
Extend the struct so we can support more than 2 parents.

The size of the sturct is now 16 bytes, from 8 bytes. This might have some
performance overhead.

Not using `Box<[u8]>` because that will make the struct 24 bytes.

Reviewed By: StanislavGlebik

Differential Revision: D30686451

fbshipit-source-id: c0f8d0472c7e578f34d771dacecffc91585650c3
2021-09-01 09:25:33 -07:00
Jun Wu
260c97cb09 dag: avoid remote lookup in one more case
Summary:
In `vertex_id_with_max_group(name, group)`, if `group` is master and the `name`
exists in the non-master group, then there is no need to lookup remotely because
a same name (vertex) cannot be present in both master and non-master group. In
that case, just return that the `name` does not exist in the master group.

Reviewed By: StanislavGlebik

Differential Revision: D30699215

fbshipit-source-id: 5170abe719aa7cc31533912e18bc0e21f133e1f4
2021-09-01 09:25:33 -07:00
Jun Wu
c713ce098b dag: add test of suboptimal flush reassignment with lazy graph
Summary:
Added a test about excessive remote lookups when flush() reassigns vertexes
from non-master to master.

Reviewed By: StanislavGlebik

Differential Revision: D30699214

fbshipit-source-id: 0547707764855ab9a563178740612b54df4a5fc9
2021-09-01 09:25:33 -07:00
Jun Wu
77b3a82755 dag: add more tracing logs
Summary: They are used to narrow down issues related to S242328.

Reviewed By: StanislavGlebik

Differential Revision: D30699216

fbshipit-source-id: 28f4f0bfadadb2dea5510878168c2d7b47a8641c
2021-09-01 09:25:33 -07:00
Arun Kulshreshtha
550ee2eafa http-client: add RequestInfo struct
Summary: Split out the request ID, URL, and HTTP method from `RequestContext` into a new `RequestInfo` struct, which can be cheaply cloned and included in the response returned to the caller. This enables the caller to correlate requests and responses, which is useful when working with many concurrent requests.

Reviewed By: DurhamG

Differential Revision: D30650365

fbshipit-source-id: 68efedcf852c91387450443ebe46062809633f10
2021-08-31 22:29:39 -07:00
Jun Wu
095232f7a8 pydag: export CheckIntegrity methods to Python
Summary:
Make it possible to call the CheckIntegrity APIs from Python such as:

  In [1]: cl.inner.checkuniversalids()
  Out[1]: []

  In [2]: cl.inner.checksegments()
  Out[2]: []

  In [3]: cl.inner.checkisomorphicgraph(cl.inner, cl.dageval(lambda: heads(mastergroup())))
  # take a while
  Out[3]: []

Reviewed By: andll

Differential Revision: D30682536

fbshipit-source-id: 23f280bf261def3d20d5f7dc15a48c2fc2d79d77
2021-08-31 21:26:47 -07:00
Jun Wu
41ef5198f5 hgcommits: delegate CheckIntegrity to inner structs
Summary: Expose CheckIntegrity features from segmented changelog.

Reviewed By: andll

Differential Revision: D30682538

fbshipit-source-id: 382c50719f7176f299c15d16ddaae3783cbae265
2021-08-31 21:26:47 -07:00
Jun Wu
4d4afdd72a dag: add delegate support for CheckIntegrity
Summary: This makes other crates easier to implement CheckIntegrity.

Reviewed By: andll

Differential Revision: D30682540

fbshipit-source-id: 4333f37fa7bafe55a8bee9f149b2f23a463c51af
2021-08-31 21:26:46 -07:00
Jun Wu
71a676472c revlogindex: impl dummy integrity checks for revlog
Summary:
Makes the revlog index provides dummy graph integrity checks so it can
be used as a generic object in the Python bindings.

Reviewed By: andll

Differential Revision: D30682542

fbshipit-source-id: 25c6e8640de46188d7bf45a927e11e0779a8ad40
2021-08-31 21:26:46 -07:00
Jun Wu
5bcfb8cda0 dag: impl check_isomorphic_graph for NameDag
Summary: Make it possible to check a graph against a reference graph.

Reviewed By: andll

Differential Revision: D30682539

fbshipit-source-id: 57db952dcda5656ff6000e9961448c9b64afbaf0
2021-08-31 21:26:46 -07:00
Jun Wu
2cc0389e8b dag: add static lifetime bound
Summary: Required to make the upcoming changes compile.

Reviewed By: andll

Differential Revision: D30682541

fbshipit-source-id: 3ed4cf4718a906638cba2ab4efce2e3ea5f11fee
2021-08-31 21:26:46 -07:00
Jun Wu
08efd9d167 dag: impl check_segments for NameDag
Summary: Make it possible to check segment integrity.

Reviewed By: andll

Differential Revision: D30644243

fbshipit-source-id: 24bb0c8c8c9394d688e3e9320e59268bc2a4ed3f
2021-08-31 21:26:46 -07:00
Jun Wu
fe0562eaec dag: impl check_universal_ids for NameDag
Summary: Make it possible to check universal ids externally.

Reviewed By: andll

Differential Revision: D30644242

fbshipit-source-id: f312ff59dbdf68e57c5249d57c5d44da0b10e398
2021-08-31 21:26:46 -07:00
Jun Wu
28721b23e3 dag: impl blank integrity check for NameDag
Summary: Blank code for implementing integrity check for NameDag.

Reviewed By: andll

Differential Revision: D30644245

fbshipit-source-id: 22b030893dda0f0ac4c1b3707e39a520b1f6e718
2021-08-31 21:26:46 -07:00
Jun Wu
91195dcb76 dag: define graph integrity check functions
Summary: This will be used to verify graph integrity later.

Reviewed By: andll

Differential Revision: D30644244

fbshipit-source-id: 0d22b70121da37c411adf17200a6c752fefa80ad
2021-08-31 21:26:46 -07:00
Genevieve Helsel
f90a988fb2 use HiveLogger in EdenLogviewWriter
Differential Revision: D29568132

fbshipit-source-id: a1ef159bfbb5ebacb50274ab68a1585a684e53c9
2021-08-31 17:28:23 -07:00
Zeyi (Rice) Fan
949f565aab Back out "generate Cargo.toml"
Reviewed By: genevievehelsel

Differential Revision: D30679584

fbshipit-source-id: 025ea455c51b5a485cc61abf405e7c06380093fd
2021-08-31 15:25:20 -07:00
Zeyi (Rice) Fan
79517ec184 generate Cargo.toml
Differential Revision: D30670348

fbshipit-source-id: 74655c060cdc584c63e334a22e169705878329b7
2021-08-31 12:28:09 -07:00
Simon Farnsworth
4d12f542a3 All rules for a treematcher must be typed
Summary: This breaks all use of `hg sparse`, because `.hg*` cannot be matched.

Reviewed By: mitrandir77

Differential Revision: D30666349

fbshipit-source-id: c06d1b798a57490f2e5560f178a2839ae5425146
2021-08-31 09:39:31 -07:00
Zeyi (Rice) Fan
0d53c14f66 temporarily remove existing Cargo.toml
Differential Revision: D30670349

fbshipit-source-id: 872f847a01ac6e2ff5dd21c5bd7f4a7aa563a494
2021-08-31 09:34:46 -07:00
Alex Hornby
f15eff2116 mononoke: introduce ManifoldOptions struct
Summary: We've got multiple manifold parameters now, two of which are Option<i64>, so lets create a struct to name them

Reviewed By: HarveyHunt

Differential Revision: D30305462

fbshipit-source-id: 44eee00d478e4485d074a14fcccec2f0f9572ecd
2021-08-31 09:34:46 -07:00
Mateusz Kwapich
a57cfdf804 include the program name in the error message
Summary:
This allows to quickly identify the program that emitted the error.

Per user feedback: https://fb.workplace.com/groups/clifoundation/posts/433922134631466

Reviewed By: StanislavGlebik

Differential Revision: D30604611

fbshipit-source-id: 712bc9f466c5a7b5c97a1b83a10fbe277341a300
2021-08-31 02:32:46 -07:00
svcscm svcscm
3f0baf2d82 Updating submodules
Summary:
GitHub commits:

b765365df4

Reviewed By: yns88

fbshipit-source-id: f2017902fd388fb299b4449739bdba925d320168
2021-08-30 23:53:53 -07:00
Genevieve Helsel
c101e56dec add json option to version
Reviewed By: chadaustin

Differential Revision: D30555962

fbshipit-source-id: 50cf7afa0f30242a5d28b112bae04793e9b55ceb
2021-08-30 22:12:15 -07:00