mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Use log/journal instead of std::cerr (RIPD-1377):
Change some uses of std::cerr to log or cout.
This commit is contained in:
committed by
Edward Hennis
parent
b3eada1dc2
commit
e01f6e7455
@@ -1297,8 +1297,9 @@ rpcClient(std::vector<std::string> const& args,
|
||||
ServerHandler::Setup setup;
|
||||
try
|
||||
{
|
||||
std::stringstream ss;
|
||||
setup = setup_ServerHandler(config, ss);
|
||||
setup = setup_ServerHandler(
|
||||
config,
|
||||
beast::logstream { logs.journal ("HTTPClient").warn() });
|
||||
}
|
||||
catch (std::exception const&)
|
||||
{
|
||||
@@ -1429,10 +1430,12 @@ void fromNetwork (
|
||||
Logs& logs,
|
||||
std::function<void (Json::Value const& jvInput)> callbackFuncP)
|
||||
{
|
||||
auto j = logs.journal ("HTTPClient");
|
||||
|
||||
// Connect to localhost
|
||||
if (!quiet)
|
||||
{
|
||||
std::cerr << (bSSL ? "Securely connecting to " : "Connecting to ") <<
|
||||
JLOG(j.info()) << (bSSL ? "Securely connecting to " : "Connecting to ") <<
|
||||
strIp << ":" << iPort << std::endl;
|
||||
}
|
||||
|
||||
@@ -1449,8 +1452,6 @@ void fromNetwork (
|
||||
using namespace std::chrono_literals;
|
||||
auto constexpr RPC_NOTIFY = 10min;
|
||||
|
||||
auto j = logs.journal ("HTTPClient");
|
||||
|
||||
HTTPClient::request (
|
||||
bSSL,
|
||||
io_service,
|
||||
@@ -1467,7 +1468,7 @@ void fromNetwork (
|
||||
std::bind (&RPCCallImp::onResponse, callbackFuncP,
|
||||
std::placeholders::_1, std::placeholders::_2,
|
||||
std::placeholders::_3, j),
|
||||
logs);
|
||||
j);
|
||||
}
|
||||
|
||||
} // RPCCall
|
||||
|
||||
Reference in New Issue
Block a user