// Copyright 2015 The go-ethereum Authors // This file is part of the go-ethereum library. // // The go-ethereum library is free software: you can redistribute it and/or modify // it under the terms of the GNU Lesser General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // The go-ethereum library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Lesser General Public License for more details. // // You should have received a copy of the GNU Lesser General Public License // along with the go-ethereum library. If not, see . package logger import ( "fmt" "io" "log" "os" "github.com/ethereum/go-ethereum/common" ) func openLogFile(datadir string, filename string) *os.File { path := common.AbsolutePath(datadir, filename) file, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666) if err != nil { panic(fmt.Sprintf("error opening log file '%s': %v", filename, err)) } return file } func New(datadir string, logFile string, logLevel int) LogSystem { var writer io.Writer if logFile == "" { writer = os.Stdout } else { writer = openLogFile(datadir, logFile) } var sys LogSystem sys = NewStdLogSystem(writer, log.LstdFlags, LogLevel(logLevel)) AddLogSystem(sys) return sys } func NewJSONsystem(datadir string, logFile string) LogSystem { var writer io.Writer if logFile == "-" { writer = os.Stdout } else { writer = openLogFile(datadir, logFile) } var sys LogSystem sys = NewJsonLogSystem(writer) AddLogSystem(sys) return sys } option value='s-network-monitor'>s-network-monitor DEXON full node (https://github.com/dexon-foundation/dexon)
aboutsummaryrefslogtreecommitdiffstats
path: root/log/handler_go13.go
blob: 0843ed0e5f388b60c82b15fb53a00f9aac069d8a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
span class='insertions'>+10
* all: update generated code (#15808)Felix Lange2018-01-083-5/+5
* tests: update to upstream commit 2bb0c3da3b (#15806)Felix Lange2018-01-042-8/+5
* all: switch gas limits from big.Int to uint64Péter Szilágyi2018-01-036-34/+34
* cmd, core, eth/tracers: support fancier js tracing (#15516)Péter Szilágyi2017-12-212-3/+3
* all: gofmt -w -s (#15419)ferhat elmas2017-11-082-10/+10
* tests: add ethash difficulty tests (#15191)Martin Holst Swende2017-09-276-8/+234
* params: Updated finalized gascosts for ECMUL/MODEXP (#15135)Martin Holst Swende2017-09-143-3/+9
* consensus, core, params: rebrand Metro to ByzantiumPéter Szilágyi2017-09-142-19/+19
* cmd/evm: adds ability to run individual state test file (#14998)Martin Holst Swende2017-09-052-7/+8
* core/vm: Make MaxCodesize non-retroactive (#15072)Martin Holst Swende2017-09-041-2/+0
* core, tests: implement Metropolis EIP 684Péter Szilágyi2017-08-253-3/+0
* Merge pull request #15028 from karalabe/metropolis-iceagePéter Szilágyi2017-08-255-116/+26
|\
| * consensus, core, tests: implement Metropolis EIP 649Péter Szilágyi2017-08-245-116/+26
* | core/state: revert metro suicide map addition (#15024)Péter Szilágyi2017-08-241-1/+0
|/
* Merge pull request #15014 from rjl493456442/metropolis-eip658Péter Szilágyi2017-08-233-4/+5
|\
| * tests: pull in new test suite, enable most block testsPéter Szilágyi2017-08-222-3/+4
| * core: implement Metropolis EIP 658, receipt status byterjl4934564422017-08-221-1/+1
* | tests: enable Byzantium state tests for CIPéter Szilágyi2017-08-221-2/+2
|/
* Merge pull request #14983 from karalabe/metropolis-revertPéter Szilágyi2017-08-211-0/+3
|\
| * tests: skip the bad tests from colliding account touchesPéter Szilágyi2017-08-171-0/+3
* | core, light: send chain events using event.Feed (#14865)Miya Chen2017-08-181-2/+1
|/
* tests: pull in latest tests from upstreamPéter Szilágyi2017-08-161-0/+0
* tests: update tests, use blockchain test "network" fieldFelix Lange2017-08-116-84/+110
* tests: update tests and implement general state tests (#14734)Felix Lange2017-07-11