Zebra/zebrad/src
teor be5cfad07f
change(state): Prepare for in-place database format upgrades, but don't make any format changes yet (#7031)
* Move format upgrades to their own module and enum

* Launch a format change thread if needed, and shut it down during shutdown

* Add some TODOs and remove a redundant timer

* Regularly check for panics in the state upgrade task

* Only run example upgrade once, change version field names

* Increment database format to 25.0.2: add format change task

* Log the running and initial disk database format versions on startup

* Add initial disk and running state versions to cached state images in CI

* Fix missing imports

* Fix typo in logs workflow command

* Add a force_save_to_disk argument to the CI workflow

* Move use_internet_connection into zebrad_config()

* fastmod can_spawn_zebrad_for_rpc can_spawn_zebrad_for_test_type zebra*

* Add a spawn_zebrad_without_rpc() function

* Remove unused copy_state() test code

* Assert that upgrades and downgrades happen with the correct versions

* Add a kill_and_return_output() method for tests

* Add a test for new_state_format() versions (no upgrades or downgrades)

* Add use_internet_connection to can_spawn_zebrad_for_test_type()

* Fix workflow parameter passing

* Check that reopening a new database doesn't upgrade (or downgrade) the format

* Allow ephemeral to be set to false even if we don't have a cached state

* Add a test type that will accept any kind of state

* When re-using a directory, configure the state test config with that path

* Actually mark newly created databases with their format versions

* Wait for the state to be opened before testing the format

* Run state format tests on mainnet and testnet configs (no network access)

* run multiple reopens in tests

* Test upgrades run correctly

* Test that version downgrades work as expected (best effort)

* Add a TODO for testing partial updates

* Fix missing test arguments

* clippy if chain

* Fix typo

* another typo

* Pass a database instance to the format upgrade task

* Fix a timing issue in the tests

* Fix version matching in CI

* Use correct env var reference

* Use correct github env file

* Wait for the database to be written before killing Zebra

* Use correct workflow syntax

* Version changes aren't always upgrades

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2023-07-13 21:36:15 +00:00
..
bin/zebrad fix(zebrad): accept default subcommand arguments and print consistent usage information for top-level 'help' subcommand (#6801) 2023-06-07 06:03:42 +00:00
commands fix(commands): Require an argument name before the list of tracing filters when used without a subcommand (#7056) 2023-07-05 09:28:05 +00:00
components fix(network): Avoid initiating outbound handshakes with IPs for which Zebra already has an active peer. (#7029) 2023-07-06 05:54:10 +00:00
application.rs change(state): Prepare for in-place database format upgrades, but don't make any format changes yet (#7031) 2023-07-13 21:36:15 +00:00
commands.rs fix(log): Only show the Zebra logo & intro for the `start` command (#7075) 2023-06-27 17:38:57 +00:00
components.rs Re-order Zebra startup, so slow services are launched last (#3091) 2021-11-23 17:42:44 +00:00
config.rs rpc(config): Add a `mining` section with miner address to config (#5491) 2022-11-01 00:43:45 +00:00
lib.rs feat(ui): Add a terminal-based progress bar to Zebra (#6235) 2023-04-13 08:42:17 +00:00
prelude.rs fix(zebrad): accept default subcommand arguments and print consistent usage information for top-level 'help' subcommand (#6801) 2023-06-07 06:03:42 +00:00
sentry.rs Standardise clippy lints and require docs (#2238) 2021-06-04 08:48:40 +10:00