diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2015-12-14 00:36:37 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2015-12-14 00:36:37 +0000 |
commit | 217792351da49bf3c659a403459e560a375c2b67 (patch) | |
tree | 821f8fbf11cfec18f52e6f8217df17cc870ea555 /src/cryptonote_protocol | |
parent | Merge pull request #533 (diff) | |
download | monero-217792351da49bf3c659a403459e560a375c2b67.tar.xz |
Tone down a bit L0 logs during daemon sync
Diffstat (limited to 'src/cryptonote_protocol')
-rw-r--r-- | src/cryptonote_protocol/cryptonote_protocol_handler.inl | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl index a6761101f..33a721dfe 100644 --- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl +++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl @@ -536,10 +536,12 @@ namespace cryptonote epee::misc_utils::auto_scope_leave_caller scope_exit_handler = epee::misc_utils::create_scope_leave_handler( boost::bind(&t_core::resume_mine, &m_core)); - LOG_PRINT_CCONTEXT_YELLOW( "Got NEW BLOCKS inside of " << __FUNCTION__ << ": size: " << arg.blocks.size() , LOG_LEVEL_0); + LOG_PRINT_CCONTEXT_YELLOW( "Got NEW BLOCKS inside of " << __FUNCTION__ << ": size: " << arg.blocks.size() , LOG_LEVEL_1); if (m_core.get_test_drop_download() && m_core.get_test_drop_download_height()) { // DISCARD BLOCKS for testing + uint64_t previous_height = m_core.get_current_blockchain_height(); + m_core.prepare_handle_incoming_blocks(arg.blocks); BOOST_FOREACH(const block_complete_entry& block_entry, arg.blocks) { @@ -589,9 +591,15 @@ namespace cryptonote epee::net_utils::data_logger::get_instance().add_data("calc_time", block_process_time + transactions_process_time); epee::net_utils::data_logger::get_instance().add_data("block_processing", 1); + } // each download block m_core.cleanup_handle_incoming_blocks(); + + if (m_core.get_current_blockchain_height() > previous_height) + { + LOG_PRINT_CCONTEXT_YELLOW( "Synced " << m_core.get_current_blockchain_height() << "/" << m_core.get_target_blockchain_height() , LOG_LEVEL_0); + } } // if not DISCARD BLOCK @@ -652,7 +660,7 @@ namespace cryptonote } context.m_needed_objects.erase(it++); } - LOG_PRINT_CCONTEXT_L0("-->>NOTIFY_REQUEST_GET_OBJECTS: blocks.size()=" << req.blocks.size() << ", txs.size()=" << req.txs.size() + LOG_PRINT_CCONTEXT_L1("-->>NOTIFY_REQUEST_GET_OBJECTS: blocks.size()=" << req.blocks.size() << ", txs.size()=" << req.txs.size() << "requested blocks count=" << count << " / " << count_limit); //epee::net_utils::network_throttle_manager::get_global_throttle_inreq().logger_handle_net("log/dr-monero/net/req-all.data", sec, get_avg_block_size()); |