Summary:
Remove member variable name shadowing
Facebook: This diff adds a default executor for async requests which do not specify one. This ensures we don't run request callbacks on the event threads (which in turn ensures we don't make blocking tcc calls from the event threads)
Test Plan: fbconfig tao/client; fbmake runtests
Reviewed By: hannesr@fb.com
Subscribers: hannesr, fugalh, zhuohuang, folly-diffs@, tao-eng@
FB internal diff:
D1731078
Tasks:
5752037
Signature: t1:
1731078:
1418237801:
5b9bbe74c288292d5e7c7e6a38e67be864627d89
template <class T>
class LifoSemMPMCQueue : public BlockingQueue<T> {
public:
- explicit LifoSemMPMCQueue(size_t capacity) : queue_(capacity) {}
+ explicit LifoSemMPMCQueue(size_t max_capacity) : queue_(max_capacity) {}
void add(T item) override {
if (!queue_.write(std::move(item))) {
*inCallback_ = true;
{
- RWSpinLock::ReadHolder(observersLock_);
+ RWSpinLock::ReadHolder rh(observersLock_);
for (auto o : observers_) {
f(o);
}
(newSubscribers_ && !newSubscribers_->empty()) ||
(oldSubscribers_ && !oldSubscribers_->empty()))) {
{
- RWSpinLock::WriteHolder(observersLock_);
+ RWSpinLock::WriteHolder wh(observersLock_);
if (newObservers_) {
for (auto observer : *(newObservers_)) {
observers_.push_back(observer);