Commit Graph

10 Commits

Author SHA1 Message Date
Jun Wu
5bb0e8fcf1 tests: remove require-ext.sh
Summary:
The script was used to check dependency on extenral extension. It's no longer
necessary since those "external" extensions are in repo now.

Reviewed By: DurhamG

Differential Revision: D13440398

fbshipit-source-id: 2f228ddee621b84a23f44748d843f29e1f05530e
2018-12-12 18:54:22 -08:00
Jun Wu
4ddedaf7d2 tests: remove most rocksdb test cases
Summary:
RocksDB and InnoDB are highly compatibile. There is no need to test RocksDB
engine for every hgsql related tests. Only use rocksdb for 2 of the tests.

Reviewed By: phillco

Differential Revision: D10055068

fbshipit-source-id: f9b7ef546fe7d457b0390e49014ebbe56d3c12c1
2018-09-26 14:20:15 -07:00
Durham Goode
eabf7f1b4d treemanifest: add root-only sqltreestrip option
Summary:
In the new corruption fix strategy, we're only going to strip the
entries from the root treemanifest revlog. This will leave all the
still-referenced sub-trees available for fetching if clients still have old
references to them, while preventing new references from being taken from the
root nodes.

Reviewed By: phillco

Differential Revision: D8284287

fbshipit-source-id: 4cc20bfdbf7ae5d32074dae22da4d37717ee5728
2018-06-07 11:06:01 -07:00
Durham Goode
ab72f94206 hgsql: add a sqlrefill command
Summary:
This adds a command that can be used to fill a database with data from
existing revlogs. This will be useful in the future for uploading new
repositories as well as fixing any database corruption.

In particular, this is important as a precaution to fixing the treemanifest
corruption.

Reviewed By: farnz

Differential Revision: D8108361

fbshipit-source-id: 20717c2057f2bed82c98323c4a3e9d0c6dbd7df5
2018-06-01 16:33:41 -07:00
Durham Goode
1ce89cff9a hgsql: add sqltreestrip
Summary:
Adds a command for deleting trees from history, both in mysql and
locally. This will be useful for recovering from treemanifest corruption.

Reviewed By: singhsrb

Differential Revision: D8066231

fbshipit-source-id: 34a57572c526d99c62d7d4a9e48d60d668065547
2018-05-21 11:38:52 -07:00
Durham Goode
0ae182a740 hg: default to using bundle2 for pushrebase parts
Summary:
Pushrebase previously defaulted to bundlev1. Now that the server can
support v2, let's default to v2.

Reviewed By: quark-zju

Differential Revision: D7591174

fbshipit-source-id: bc5448490ff319543baedf3f5a1aab160a73ed27
2018-04-13 21:51:53 -07:00
Durham Goode
24653e5e32 hg: add develwarn for bundle1 format
Summary:
We want to deprecate the bundlev1 format, so let's start by adding a
develwarn. Later diffs will update the tests to not use v1, then remove v1 as a
supported outgoing bundle entirely.

Reviewed By: quark-zju

Differential Revision: D7591166

fbshipit-source-id: 143ad029bfe4d141f91d6d5077342dfa44ad2944
2018-04-13 21:51:52 -07:00
Thomas Jacob
0e6b93a0e0 Add support for RocksDB
Summary:
- Add support for RocksDB engine (developed as a drop in replacement for innodb) to hgsql to allow new xdb.hgsql.1-10 shards to host hg repos
- Prefer MySQL test DBs in same region
- Run all hgsql unit tests also for RocksDB engine
- Allow for nested ifs to make that possible (downside if you switch off rockdb tests, innodb tests are run twice)

Reviewed By: quark-zju

Differential Revision: D7014064

fbshipit-source-id: 073c36176aa7eaf74252ef33c3f47da594920b28
2018-04-13 21:51:13 -07:00
Durham Goode
88ec218bd4 hg: fix hgsql treemanifest test
Summary:
The import was using the old format here. Let's use the requireext
check instead to be more robust.

Reviewed By: quark-zju

Differential Revision: D6803848

fbshipit-source-id: cb8474245414c946a1ab6cc6c3cec18cd831de0d
2018-04-13 21:50:57 -07:00
Mark Thomas
742cd624f7 hgsql: integrate with hg-crew
Summary:
Move hgsql into the hgext directory, and the tests to tests/test-hgsql-*.

Update the tests to refer to the new places for things.

Test Plan: Run the hgsql tests and make sure they pass.

Reviewers: #sourcecontrol

Differential Revision: https://phabricator.intern.facebook.com/D6660499

Tasks: T24908724
2018-01-04 07:22:19 -08:00