]> git.proxmox.com Git - ceph.git/blob - ceph/src/msg/Connection.cc
import 15.2.0 Octopus source
[ceph.git] / ceph / src / msg / Connection.cc
1 // -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
2 // vim: ts=8 sw=2 smarttab
3
4 #include "msg/Connection.h"
5 #include "msg/Messenger.h"
6
7
8 bool Connection::is_blackhole() const {
9 auto& conf = msgr->cct->_conf;
10 return ((conf->ms_blackhole_mon && peer_type == CEPH_ENTITY_TYPE_MON) ||
11 (conf->ms_blackhole_osd && peer_type == CEPH_ENTITY_TYPE_OSD) ||
12 (conf->ms_blackhole_mds && peer_type == CEPH_ENTITY_TYPE_MDS) ||
13 (conf->ms_blackhole_client && peer_type == CEPH_ENTITY_TYPE_CLIENT));
14 }