Improve log warnings:

Log non-account transaction in warning (RIPD-1440)
Log warning on PeerImp::fail (RIPD-1444)
This commit is contained in:
Brad Chase
2017-03-09 11:08:04 -05:00
committed by Scott Schurr
parent 95aebfc38c
commit c981eb81d9
2 changed files with 4 additions and 2 deletions

View File

@@ -942,6 +942,8 @@ static bool saveValidatedLedger (
JLOG (j.warn())
<< "Transaction in ledger " << seq
<< " affects no accounts";
JLOG (j.warn())
<< vt.second->getTxn()->getJson(0);
}
*db <<

View File

@@ -442,7 +442,7 @@ PeerImp::fail(std::string const& reason)
shared_from_this(), reason));
if (socket_.is_open())
{
JLOG (journal_.debug()) << reason;
JLOG (journal_.warn()) << reason;
}
close();
}
@@ -453,7 +453,7 @@ PeerImp::fail(std::string const& name, error_code ec)
assert(strand_.running_in_this_thread());
if (socket_.is_open())
{
JLOG(journal_.debug()) << name << ": " << ec.message();
JLOG(journal_.warn()) << name << ": " << ec.message();
}
close();
}