Skip to content

Commit

Permalink
GH-2102 Add logging on app().quit()
Browse files Browse the repository at this point in the history
  • Loading branch information
heifner committed Apr 3, 2024
1 parent bd43d61 commit c84bab1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions plugins/net_plugin/net_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4376,6 +4376,7 @@ namespace eosio {
set_producer_accounts(producer_plug->producer_accounts());

thread_pool.start( thread_pool_size, []( const fc::exception& e ) {
elog("Exception in net thread, exiting: ${e}", ("e", e.to_detail_string()));
app().quit();
} );

Expand Down
4 changes: 4 additions & 0 deletions programs/nodeos/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ int main(int argc, char** argv)
uint32_t short_hash = 0;
fc::from_hex(eosio::version::version_hash(), (char*)&short_hash, sizeof(short_hash));

app->set_stop_executor_cb([&app]() {
ilog("appbase quit called");
app->get_io_service().stop();
});
app->set_version(htonl(short_hash));
app->set_version_string(eosio::version::version_client());
app->set_full_version_string(eosio::version::version_full());
Expand Down

0 comments on commit c84bab1

Please sign in to comment.