* by making a paxos commit, but not by injecting values while
* an election is ongoing.)
*/
- virtual unsigned paxos_size() const = 0;
+ virtual int paxos_size() const = 0;
/**
* Retrieve a set of ranks which are not allowed to become the leader.
* Like paxos_size(), This set can change between elections, but not
return mon->has_ever_joined;
}
-unsigned Elector::paxos_size() const
+int Elector::paxos_size() const
{
- return (unsigned)mon->monmap->size();
+ return mon->monmap->size();
}
void Elector::shutdown()
/* Retrieve the Monitor::has_ever_joined member */
bool ever_participated() const;
/* Retrieve monmap->size() */
- unsigned paxos_size() const;
+ int paxos_size() const;
/* Right now we don't disallow anybody */
std::set<int> disallowed_leaders;
const std::set<int>& get_disallowed_leaders() const { return disallowed_leaders; }
logic.start();
}
bool ever_participated() const { return ever_joined; }
- unsigned paxos_size() const { return parent->get_paxos_size(); }
+ int paxos_size() const { return parent->get_paxos_size(); }
const set<int>& get_disallowed_leaders() const {
return parent->get_disallowed_leaders();
}