Skip to content

Conversation

@zelig
Copy link
Contributor

@zelig zelig commented Mar 21, 2015

re #538

  • logjson flag remove logformat flag
  • passed to eth Config
  • logsystem not a field of Ethereum
  • LogSystem does not need to expose GetLogLevel/SetLogLevel
  • message struct just implements more generic LogMsg interface
  • LogMsg is a fmt.Stringer with Level()
  • jsonMsg ([]byte) implements LogMsg
  • remove "raw" systems
  • move level logic inside StdLogSystem
  • logsystems only print their kind of msg: jsonLogSystem prints jsonMsg, StdLogSystem prints stdMsg

@zelig
Copy link
Contributor Author

zelig commented Mar 21, 2015

re #538 i hacked something together quick,still horribly inefficient
my 2c: if we take format seriously, all logs should be structured originally, which is not realistic. alternatively, we see it from the clumsiness of this code that jsonlogsystem should be completely separate from the other logging, or systemIn channels should be typed similar to event subscription. But most importantly loglevel check should be as global as possible for effieciency, even allowing compile time -nodebug

@tgerring
Copy link
Contributor

+1 tested locally and works as expected

ethereum --loglevel "3" to output Info logs and above (Default setting)
ethereum --logjson "-" --loglevel "0" to output JSON-only logs
ethereum --logjson "-" --loglevel "5" to output JSON in addition to DebugDetail (and above) logs

zelig added 2 commits March 22, 2015 02:16
- logjson flag remove logformat flag
- passed to eth Config
- logsystem not a field of Ethereum
- LogSystem does not need to expose GetLogLevel/SetLogLevel
- message struct just implements more generic LogMsg interface
- LogMsg is a fmt.Stringer with Level()
- jsonMsg ([]byte) implements LogMsg
- remove "raw" systems
- move level logic inside StdLogSystem
- logsystems only print their kind of msg: jsonLogSystem prints jsonMsg, StdLogSystem prints stdMsg
@zelig zelig self-assigned this Mar 22, 2015
@zelig zelig added this to the Frontier milestone Mar 22, 2015
@tgerring
Copy link
Contributor

Tagging @LefterisJP @sveneh @heikoheiko to let them know of this pending change

@obscuren obscuren merged commit 0edb335 into ethereum:develop Mar 22, 2015
ngtuna added a commit to ngtuna/tomochain that referenced this pull request Aug 15, 2019
maoueh pushed a commit to streamingfast/go-ethereum that referenced this pull request Jun 9, 2023
Add logs for transactions while committing a block
billettc pushed a commit to streamingfast/go-ethereum that referenced this pull request Apr 10, 2025
rjl493456442 pushed a commit to rjl493456442/go-ethereum that referenced this pull request Jul 1, 2025
* all: load/dump trie disklayer into file

Signed-off-by: jsvisa <delweng@gmail.com>

* cmd: set cache.trie.journal=trie-disklayer.rlp as default

Signed-off-by: jsvisa <delweng@gmail.com>

* journal: directly write into file

Signed-off-by: jsvisa <delweng@gmail.com>

---------

Signed-off-by: jsvisa <delweng@gmail.com>
maoueh pushed a commit to streamingfast/go-ethereum that referenced this pull request Nov 11, 2025
…-cost

core: Add WasmLogCost acl operation anf unify log cost
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants