Skip to content

Commit

Permalink
Merge pull request #4777 from pwojcikdev/remove-legacy-bootstrap-2
Browse files Browse the repository at this point in the history
Remove legacy bootstrap
  • Loading branch information
pwojcikdev authored Oct 31, 2024
2 parents e72a999 + 93385bb commit c612519
Show file tree
Hide file tree
Showing 68 changed files with 1,141 additions and 8,187 deletions.
2 changes: 1 addition & 1 deletion nano/core_test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ add_executable(
block_store.cpp
blockprocessor.cpp
bootstrap.cpp
bootstrap_ascending.cpp
bootstrap_server.cpp
cli.cpp
confirmation_solicitor.cpp
Expand Down Expand Up @@ -41,6 +40,7 @@ add_executable(
optimistic_scheduler.cpp
processing_queue.cpp
processor_service.cpp
random.cpp
random_pool.cpp
rep_crawler.cpp
receivable.cpp
Expand Down
14 changes: 8 additions & 6 deletions nano/core_test/active_elections.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,9 @@ TEST (active_elections, confirm_frontier)
nano::node_flags node_flags;
node_flags.disable_request_loop = true;
node_flags.disable_ongoing_bootstrap = true;
node_flags.disable_ascending_bootstrap = true;
auto & node1 = *system.add_node (node_flags);
nano::node_config node_config;
node_config.bootstrap.enable = false;
auto & node1 = *system.add_node (node_config, node_flags);
system.wallet (0)->insert_adhoc (nano::dev::genesis_key.prv);

// we cannot use the same block instance on 2 different nodes, so make a copy
Expand All @@ -136,10 +137,11 @@ TEST (active_elections, confirm_frontier)
// The rep crawler would otherwise request confirmations in order to find representatives
nano::node_flags node_flags2;
node_flags2.disable_ongoing_bootstrap = true;
node_flags2.disable_ascending_bootstrap = true;
node_flags2.disable_rep_crawler = true;
nano::node_config node_config2;
node_config2.bootstrap.enable = false;
// start node2 later so that we do not get the gossip traffic
auto & node2 = *system.add_node (node_flags2);
auto & node2 = *system.add_node (node_config2, node_flags2);

// Add representative to disabled rep crawler
auto peers (node2.network.random_set (1));
Expand Down Expand Up @@ -1444,10 +1446,10 @@ TEST (active_elections, broadcast_block_on_activation)
nano::node_config config1 = system.default_config ();
// Deactivates elections on both nodes.
config1.active_elections.size = 0;
config1.bootstrap_ascending.enable = false;
config1.bootstrap.enable = false;
nano::node_config config2 = system.default_config ();
config2.active_elections.size = 0;
config2.bootstrap_ascending.enable = false;
config2.bootstrap.enable = false;
nano::node_flags flags;
// Disables bootstrap listener to make sure the block won't be shared by this channel.
flags.disable_bootstrap_listener = true;
Expand Down
Loading

0 comments on commit c612519

Please sign in to comment.