forked from cerc-io/plugeth
Changed logging
This commit is contained in:
parent
43f88b2bbb
commit
30842eb8d0
@ -6,7 +6,6 @@ import (
|
|||||||
"github.com/ethereum/eth-go/ethpub"
|
"github.com/ethereum/eth-go/ethpub"
|
||||||
"github.com/ethereum/eth-go/ethrpc"
|
"github.com/ethereum/eth-go/ethrpc"
|
||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"log"
|
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -14,7 +13,7 @@ func DoRpc(ethereum *eth.Ethereum, RpcPort int) {
|
|||||||
var err error
|
var err error
|
||||||
ethereum.RpcServer, err = ethrpc.NewJsonRpcServer(ethpub.NewPEthereum(ethereum), RpcPort)
|
ethereum.RpcServer, err = ethrpc.NewJsonRpcServer(ethpub.NewPEthereum(ethereum), RpcPort)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Println("Could not start RPC interface:", err)
|
ethutil.Config.Log.Infoln("Could not start RPC interface:", err)
|
||||||
} else {
|
} else {
|
||||||
go ethereum.RpcServer.Start()
|
go ethereum.RpcServer.Start()
|
||||||
}
|
}
|
||||||
@ -25,7 +24,7 @@ func DoMining(ethereum *eth.Ethereum) {
|
|||||||
ethereum.Mining = true
|
ethereum.Mining = true
|
||||||
|
|
||||||
if ethutil.GetKeyRing().Len() == 0 {
|
if ethutil.GetKeyRing().Len() == 0 {
|
||||||
log.Println("No address found, can't start mining")
|
ethutil.Config.Log.Infoln("No address found, can't start mining")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
keyPair := ethutil.GetKeyRing().Get(0)
|
keyPair := ethutil.GetKeyRing().Get(0)
|
||||||
@ -40,7 +39,7 @@ func DoMining(ethereum *eth.Ethereum) {
|
|||||||
time.Sleep(5 * time.Second)
|
time.Sleep(5 * time.Second)
|
||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
log.Println("Miner started")
|
ethutil.Config.Log.Infoln("Miner started")
|
||||||
|
|
||||||
miner := ethminer.NewDefaultMiner(addr, ethereum)
|
miner := ethminer.NewDefaultMiner(addr, ethereum)
|
||||||
miner.Start()
|
miner.Start()
|
||||||
|
Loading…
Reference in New Issue
Block a user