diff --git a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/fs/filehandle.cc b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/fs/filehandle.cc index 03c517b0c8..1f553a090f 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/fs/filehandle.cc +++ b/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/fs/filehandle.cc @@ -225,6 +225,12 @@ void FileHandleImpl::AsyncPreadSome( DatanodeInfoProto &chosen_dn = *it; + std::string dnIpAddr = chosen_dn.id().ipaddr(); + std::string dnHostName = chosen_dn.id().hostname(); + LOG_DEBUG(kFileHandle, << "FileHandleImpl::AsyncPreadSome(" + << FMT_THIS_ADDR << "), ...) Datanode hostname=" << dnHostName << ", IP Address=" << dnIpAddr + << ", file path=\"" << path_ << "\", offset=" << offset); + uint64_t offset_within_block = offset - block->offset(); uint64_t size_within_block = std::min( block->b().numbytes() - offset_within_block, asio::buffer_size(buffers));