]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
msg/async: better debug output 25884/head
authorSage Weil <sage@redhat.com>
Wed, 9 Jan 2019 21:39:41 +0000 (15:39 -0600)
committerSage Weil <sage@redhat.com>
Fri, 11 Jan 2019 18:31:35 +0000 (12:31 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
src/msg/async/AsyncConnection.cc
src/msg/async/ProtocolV1.cc
src/msg/async/ProtocolV2.cc

index cdfed844eca584677325f28716fdf90f5d7412ac..13711c98bc933a3ae4ba2c84c4467a7ba3afa421 100644 (file)
@@ -38,7 +38,8 @@
 ostream& AsyncConnection::_conn_prefix(std::ostream *_dout) {
   return *_dout << "-- " << async_msgr->get_myaddrs() << " >> "
                << *peer_addrs << " conn(" << this
-               << (msgr2 ? " msgr2" : " legacy")
+               << (msgr2 ? " msgr2=" : " legacy=")
+               << protocol.get()
                 << " :" << port
                 << " s=" << get_state_name(state)
                 << " l=" << policy.lossy
index 33b06dbe768335b77a1d10958ee4f30836f77673..3178f38ba2d36fcdb19e79968c4ad3c191098312 100644 (file)
@@ -15,8 +15,9 @@
 #define dout_prefix _conn_prefix(_dout)
 ostream &ProtocolV1::_conn_prefix(std::ostream *_dout) {
   return *_dout << "--1- " << messenger->get_myaddrs().legacy_addr() << " >> "
-                << connection->peer_addrs->legacy_addr() << " conn("
-                << connection << (connection->msgr2 ? " msgr2" : " legacy")
+                << connection->peer_addrs->legacy_addr()
+               << " conn("
+                << connection << " " << this
                 << " :" << connection->port << " s=" << get_state_name(state)
                 << " pgs=" << peer_global_seq << " cs=" << connect_seq
                 << " l=" << connection->policy.lossy << ").";
@@ -1984,6 +1985,8 @@ CtPtr ProtocolV1::handle_connect_message_2() {
                             // AsyncConnection here)
 
     ProtocolV1 *exproto = dynamic_cast<ProtocolV1 *>(existing->protocol.get());
+    ldout(cct,10) << __func__ << " existing=" << existing << " exproto="
+                 << exproto << dendl;
     assert(exproto->proto_type == 1);
 
     if (!exproto) {
index d249c8c7b257fd078f35f18368723a33718ecac3..faf51b7ce57fcabaa9fdfb0b2a6e63cb3aed88a6 100644 (file)
@@ -15,8 +15,9 @@
 #define dout_prefix _conn_prefix(_dout)
 ostream &ProtocolV2::_conn_prefix(std::ostream *_dout) {
   return *_dout << "--2- " << messenger->get_myaddrs() << " >> "
-                << *connection->peer_addrs << " conn("
-                << connection << (connection->msgr2 ? " msgr2" : " legacy")
+                << *connection->peer_addrs
+               << " conn("
+                << connection << " " << this
                 << " :" << connection->port << " s=" << get_state_name(state)
                 << " pgs=" << peer_global_seq << " cs=" << connect_seq
                 << " l=" << connection->policy.lossy << ").";
@@ -2032,6 +2033,8 @@ CtPtr ProtocolV2::handle_connect_message_2() {
                             // AsyncConnection here)
 
     ProtocolV2 *exproto = dynamic_cast<ProtocolV2 *>(existing->protocol.get());
+    ldout(cct,10) << __func__ << " existing=" << existing << " exproto="
+                 << exproto << dendl;
     assert(exproto->proto_type == 2);
 
     if (!exproto) {