mirror of
https://github.com/ceph/ceph
synced 2024-12-18 17:37:38 +00:00
OSD: rename share_map_incoming and share_map_outgoing
share_map_incoming -> share_map share_map_outgoing -> share_map_peer Signed-off-by: Greg Farnum <greg@inktank.com>
This commit is contained in:
parent
e1277ba6b3
commit
b038f0c504
@ -3030,7 +3030,7 @@ void OSD::handle_osd_ping(MOSDPing *m)
|
||||
if (is_active()) {
|
||||
ConnectionRef con = service.get_con_osd_cluster(from, curmap->get_epoch());
|
||||
if (con) {
|
||||
service.share_map_outgoing(from, con.get());
|
||||
service.share_map_peer(from, con.get());
|
||||
}
|
||||
}
|
||||
} else if (!curmap->exists(from) ||
|
||||
@ -3077,7 +3077,7 @@ void OSD::handle_osd_ping(MOSDPing *m)
|
||||
if (is_active()) {
|
||||
ConnectionRef con = service.get_con_osd_cluster(from, curmap->get_epoch());
|
||||
if (con) {
|
||||
service.share_map_outgoing(from, con.get());
|
||||
service.share_map_peer(from, con.get());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3978,7 +3978,7 @@ void OSDService::send_message_osd_cluster(int peer, Message *m, epoch_t from_epo
|
||||
}
|
||||
const entity_inst_t& peer_inst = next_map->get_cluster_inst(peer);
|
||||
Connection *peer_con = osd->cluster_messenger->get_connection(peer_inst).get();
|
||||
share_map_outgoing(peer, peer_con, next_map);
|
||||
share_map_peer(peer, peer_con, next_map);
|
||||
osd->cluster_messenger->send_message(m, peer_inst);
|
||||
release_map(next_map);
|
||||
}
|
||||
@ -4751,14 +4751,14 @@ bool OSDService::should_share_map(entity_name_t name, Connection *con,
|
||||
return should_send;
|
||||
}
|
||||
|
||||
void OSDService::share_map_incoming(
|
||||
void OSDService::share_map(
|
||||
entity_name_t name,
|
||||
Connection *con,
|
||||
epoch_t epoch,
|
||||
OSDMapRef& osdmap,
|
||||
epoch_t *sent_epoch_p)
|
||||
{
|
||||
dout(20) << "share_map_incoming "
|
||||
dout(20) << "share_map "
|
||||
<< name << " " << con->get_peer_addr()
|
||||
<< " " << epoch << dendl;
|
||||
|
||||
@ -4788,7 +4788,7 @@ void OSDService::share_map_incoming(
|
||||
}
|
||||
|
||||
|
||||
void OSDService::share_map_outgoing(int peer, Connection *con, OSDMapRef map)
|
||||
void OSDService::share_map_peer(int peer, Connection *con, OSDMapRef map)
|
||||
{
|
||||
if (!map)
|
||||
map = get_osdmap();
|
||||
@ -4800,9 +4800,9 @@ void OSDService::share_map_outgoing(int peer, Connection *con, OSDMapRef map)
|
||||
send_incremental_map(pe, con, map);
|
||||
note_peer_epoch(peer, map->get_epoch());
|
||||
} else
|
||||
dout(20) << "_share_map_outgoing " << con << " already has epoch " << pe << dendl;
|
||||
dout(20) << "share_map_peer " << con << " already has epoch " << pe << dendl;
|
||||
} else {
|
||||
dout(20) << "_share_map_outgoing " << con << " don't know epoch, doing nothing" << dendl;
|
||||
dout(20) << "share_map_peer " << con << " don't know epoch, doing nothing" << dendl;
|
||||
// no idea about peer's epoch.
|
||||
// ??? send recent ???
|
||||
// do nothing.
|
||||
@ -6827,7 +6827,7 @@ void OSD::do_notifies(
|
||||
it->first, curmap->get_epoch());
|
||||
if (!con)
|
||||
continue;
|
||||
service.share_map_outgoing(it->first, con.get(), curmap);
|
||||
service.share_map_peer(it->first, con.get(), curmap);
|
||||
if (con->has_feature(CEPH_FEATURE_INDEP_PG_MAP)) {
|
||||
dout(7) << "do_notify osd " << it->first
|
||||
<< " on " << it->second.size() << " PGs" << dendl;
|
||||
@ -6867,7 +6867,7 @@ void OSD::do_queries(map<int, map<spg_t,pg_query_t> >& query_map,
|
||||
ConnectionRef con = service.get_con_osd_cluster(who, curmap->get_epoch());
|
||||
if (!con)
|
||||
continue;
|
||||
service.share_map_outgoing(who, con.get(), curmap);
|
||||
service.share_map_peer(who, con.get(), curmap);
|
||||
if (con->has_feature(CEPH_FEATURE_INDEP_PG_MAP)) {
|
||||
dout(7) << "do_queries querying osd." << who
|
||||
<< " on " << pit->second.size() << " PGs" << dendl;
|
||||
@ -6911,7 +6911,7 @@ void OSD::do_infos(map<int,
|
||||
p->first, curmap->get_epoch());
|
||||
if (!con)
|
||||
continue;
|
||||
service.share_map_outgoing(p->first, con.get(), curmap);
|
||||
service.share_map_peer(p->first, con.get(), curmap);
|
||||
if (con->has_feature(CEPH_FEATURE_INDEP_PG_MAP)) {
|
||||
MOSDPGInfo *m = new MOSDPGInfo(curmap->get_epoch());
|
||||
m->pg_list = p->second;
|
||||
@ -7289,7 +7289,7 @@ void OSD::handle_pg_query(OpRequestRef op)
|
||||
it->second.from, it->second.to,
|
||||
osdmap->get_epoch(), empty,
|
||||
it->second.epoch_sent);
|
||||
service.share_map_outgoing(from, con.get(), osdmap);
|
||||
service.share_map_peer(from, con.get(), osdmap);
|
||||
cluster_messenger->send_message(mlog, con.get());
|
||||
}
|
||||
} else {
|
||||
@ -7669,7 +7669,7 @@ public:
|
||||
if (session) {
|
||||
session->sent_epoch_lock.Lock();
|
||||
}
|
||||
osd->service.share_map_incoming(
|
||||
osd->service.share_map(
|
||||
m->get_source(),
|
||||
con.get(),
|
||||
map_epoch,
|
||||
@ -8017,7 +8017,7 @@ void OSD::dequeue_op(
|
||||
if (session) {
|
||||
session->sent_epoch_lock.Lock();
|
||||
}
|
||||
service.share_map_incoming(
|
||||
service.share_map(
|
||||
m->get_source(),
|
||||
m->get_connection().get(),
|
||||
op->sent_epoch,
|
||||
|
@ -434,10 +434,10 @@ public:
|
||||
OSDSuperblock& superblock);
|
||||
bool should_share_map(entity_name_t name, Connection *con, epoch_t epoch,
|
||||
OSDMapRef& osdmap, const epoch_t *sent_epoch_p);
|
||||
void share_map_incoming(entity_name_t name, Connection *con, epoch_t epoch,
|
||||
OSDMapRef& osdmap, epoch_t *sent_epoch_p);
|
||||
void share_map_outgoing(int peer, Connection *con,
|
||||
OSDMapRef map = OSDMapRef());
|
||||
void share_map(entity_name_t name, Connection *con, epoch_t epoch,
|
||||
OSDMapRef& osdmap, epoch_t *sent_epoch_p);
|
||||
void share_map_peer(int peer, Connection *con,
|
||||
OSDMapRef map = OSDMapRef());
|
||||
|
||||
ConnectionRef get_con_osd_cluster(int peer, epoch_t from_epoch);
|
||||
pair<ConnectionRef,ConnectionRef> get_con_osd_hb(int peer, epoch_t from_epoch); // (back, front)
|
||||
|
@ -4465,7 +4465,7 @@ void PG::fulfill_log(
|
||||
ConnectionRef con = osd->get_con_osd_cluster(
|
||||
from.osd, get_osdmap()->get_epoch());
|
||||
if (con) {
|
||||
osd->share_map_outgoing(from.osd, con.get(), get_osdmap());
|
||||
osd->share_map_peer(from.osd, con.get(), get_osdmap());
|
||||
osd->send_message_osd_cluster(mlog, con.get());
|
||||
} else {
|
||||
mlog->put();
|
||||
|
Loading…
Reference in New Issue
Block a user