mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
We have to track the high node ID of trusted validators as a tie-breaker.
1) Change return from getCurrentValidations 2) Log tiebreaker logic to aid debugging 3) Change checkLastClosedLedger to use the new tie-breaker logic 4) Log when we refuse to switch to our own previous ledger 5) Track node ID in the serialized validation object 6) Simplify getCurrentValidations ledger suppression logic
This commit is contained in:
@@ -12,6 +12,8 @@
|
||||
|
||||
typedef boost::unordered_map<uint160, SerializedValidation::pointer> ValidationSet;
|
||||
|
||||
typedef std::pair<int, uint160> currentValidationCount; // nodes validating and highest node ID validating
|
||||
|
||||
class ValidationCollection
|
||||
{
|
||||
protected:
|
||||
@@ -38,7 +40,7 @@ public:
|
||||
int getNodesAfter(const uint256& ledger);
|
||||
int getLoadRatio(bool overLoaded);
|
||||
|
||||
boost::unordered_map<uint256, int> getCurrentValidations(uint256 currentLedger = uint256());
|
||||
boost::unordered_map<uint256, currentValidationCount> getCurrentValidations(uint256 currentLedger);
|
||||
|
||||
void flush();
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user