mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-25 22:39:13 +02:00
Merge bitcoin/bitcoin#34465: refactor: separate log generation from log handling
37cc2a2d95logging: use util/log.h where possible (stickies-v)bb8e9e7c4clogging: Move message formatting to util/log.h (stickies-v)001f0a428emove-only: Move logging macros to util/log.h (stickies-v)94c0adf4e8move-onlyish: Move logging levels to util/log.h (stickies-v)56d113cab0move-only: move logging categories to logging/categories.h (stickies-v)f5233f7e98move-only: Move SourceLocation to util/log.h (stickies-v) Pull request description: This is a mostly move-only change. It's a small refactoring that allows logging macros to be used by including a simple `util/log.h` header instead of the full `logging.h` logging implementation. Most of the changes here were cherry-picked from #34374. Original motivation for this change was to reduce the size and complexity of #34374 (kernel structured logging PR) and reduce the number of conflicts it causes with other PRs. But this should also make sense as a standalone change to have a clearer separation of concerns between log generation and log handling, and avoid needing to depend on the whole logging framework in call sites that only emit log messages. Recommended to review with `--color-moved=dimmed-zebra --color-moved-ws=ignore-all-space` ACKs for top commit: l0rinc: diff ACK37cc2a2d95stickies-v: re-ACK37cc2a2d95optout21: crACK37cc2a2d95sedited: ACK37cc2a2d95Tree-SHA512: c7a761323ae63f07ad290d4e3766ba1348a132c8cc68a9895fa9ae5c89206599c00646c42ef77223ac757b9d8bfe6c181bead15e7058e4d8966b3bac88a8f950
This commit is contained in:
@@ -12,13 +12,13 @@
|
||||
#include <crypto/hex_base.h>
|
||||
#include <hash.h>
|
||||
#include <kernel/messagestartchars.h>
|
||||
#include <logging.h>
|
||||
#include <primitives/block.h>
|
||||
#include <primitives/transaction.h>
|
||||
#include <script/interpreter.h>
|
||||
#include <script/script.h>
|
||||
#include <uint256.h>
|
||||
#include <util/chaintype.h>
|
||||
#include <util/log.h>
|
||||
#include <util/strencodings.h>
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
#include <coins.h>
|
||||
#include <crypto/muhash.h>
|
||||
#include <hash.h>
|
||||
#include <logging.h>
|
||||
#include <node/blockstorage.h>
|
||||
#include <primitives/transaction.h>
|
||||
#include <script/script.h>
|
||||
@@ -17,6 +16,7 @@
|
||||
#include <sync.h>
|
||||
#include <uint256.h>
|
||||
#include <util/check.h>
|
||||
#include <util/log.h>
|
||||
#include <util/overflow.h>
|
||||
#include <validation.h>
|
||||
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
#include <kernel/context.h>
|
||||
|
||||
#include <crypto/sha256.h>
|
||||
#include <logging.h>
|
||||
#include <random.h>
|
||||
#include <util/log.h>
|
||||
|
||||
#include <mutex>
|
||||
#include <string>
|
||||
|
||||
Reference in New Issue
Block a user