Add comment/warning to node::block_confirmed_or_being_confirmed functions indicating potentially unexpected behavior with respect to MVCC database transactions. (#4540)

This commit is contained in:
clemahieu 2024-05-07 11:49:29 +01:00 committed by GitHub
commit ad4f6c923c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -119,8 +119,11 @@ public:
void add_initial_peers ();
void start_election (std::shared_ptr<nano::block> const & block);
bool block_confirmed (nano::block_hash const &);
// This function may spuriously return false after returning true until the database transaction is refreshed
bool block_confirmed_or_being_confirmed (nano::secure::transaction const &, nano::block_hash const &);
bool block_confirmed_or_being_confirmed (nano::block_hash const &);
void do_rpc_callback (boost::asio::ip::tcp::resolver::iterator i_a, std::string const &, uint16_t, std::shared_ptr<std::string> const &, std::shared_ptr<std::string> const &, std::shared_ptr<boost::asio::ip::tcp::resolver> const &);
void ongoing_online_weight_calculation ();
void ongoing_online_weight_calculation_queue ();