]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/crimson: s/get_connection/connect_to/
authorKefu Chai <kchai@redhat.com>
Wed, 16 Jan 2019 07:54:38 +0000 (15:54 +0800)
committerKefu Chai <kchai@redhat.com>
Fri, 18 Jan 2019 04:39:39 +0000 (12:39 +0800)
in aa3d6f66, we removed Messenger::get_connection(), so update the test
accordingly.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/test/crimson/test_alien_echo.cc

index d327cd92d50175215781dca6b6057e957b4324e1..dd227b555a5e922f61c1ea4a61df64c4b2a03134 100644 (file)
@@ -200,7 +200,8 @@ struct Client {
       return true;
     }
     bool ping(Messenger* msgr, const entity_inst_t& peer) {
-      auto conn = msgr->get_connection(peer);
+      auto conn = msgr->connect_to(peer.name.type(),
+                                   entity_addrvec_t{peer.addr});
       replied = false;
       conn->send_message(new MPing);
       std::unique_lock lock{mutex};
@@ -335,7 +336,8 @@ static void ceph_echo(CephContext* cct,
     native_pingpong::Client client{cct};
     client.msgr->add_dispatcher_head(&client.dispatcher);
     client.msgr->start();
-    auto conn = client.msgr->get_connection(entity);
+    auto conn = client.msgr->connect_to(entity.name.type(),
+                                        entity_addrvec_t{entity.addr});
     for (unsigned i = 0; i < count; i++) {
       std::cout << "seq=" << i << std::endl;
       client.ping(entity);