Page MenuHomePhabricator

[logging] log system time and mock time
ClosedPublic

Authored by Fabien on Jan 28 2019, 14:26.

Details

Summary
Currently, if mocktime is set, the logs will be timestamped with the
mocktime instead of the system time. It's often useful to have the
system time in the logs (for example, when running an integration test,
it's useful to know what bitcoind was doing at system time so you can
see how it's interacting with the test framework or other bitcoind
nodes).

This PR timestamps the log with the actual system time, and also prints
out the mocktime if mocktime is being used.

Backport of core PR10383

Depends on D2422

Test Plan
./test/functional/test_runner.py --nocleanup rpc_uptime

Check in the debug.log that both system time and mock time are logged

Diff Detail

Repository
rABC Bitcoin ABC
Branch
PR10383
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 4721
Build 7505: Bitcoin ABC Buildbot (legacy)
Build 7504: arc lint + arc unit