#include "cls/rbd/cls_rbd_client.h"
#include "include/stringify.h"
#include "librbd/Utils.h"
+#include "librbd/asio/ContextWQ.h"
#include "librbd/watcher/Types.h"
#include "Threads.h"
io_ctx.get_pool_name())),
m_notifier_id(librados::Rados(io_ctx).get_instance_id()),
m_instance_id(stringify(m_notifier_id)),
- m_leader_lock(new LeaderLock(m_ioctx, m_work_queue, m_oid, this, true,
- m_cct->_conf.get_val<uint64_t>(
- "rbd_blacklist_expire_seconds"))) {
+ m_leader_lock(new LeaderLock(m_ioctx, *m_threads->asio_engine, m_oid, this,
+ true, m_cct->_conf.get_val<uint64_t>(
+ "rbd_blocklist_expire_seconds"))) {
}
template <typename I>
}
template <typename I>
-bool LeaderWatcher<I>::is_blacklisted() const {
+bool LeaderWatcher<I>::is_blocklisted() const {
std::lock_guard locker{m_lock};
- return m_blacklisted;
+ return m_blocklisted;
}
template <typename I>
void LeaderWatcher<I>::handle_rewatch_complete(int r) {
dout(5) << "r=" << r << dendl;
- if (r == -EBLACKLISTED) {
- dout(1) << "blacklisted detected" << dendl;
- m_blacklisted = true;
+ if (r == -EBLOCKLISTED) {
+ dout(1) << "blocklisted detected" << dendl;
+ m_blocklisted = true;
return;
}