mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
subpackages: * adapters: * msgpipes for simulated test connections * rlpx the RLPx adapter for normal non-test use * inproc simulated in-process network adapter * docker placeholder for docker cluster remote adapter * protocols: easy-to-setup modular protocols * simulations: * generic network model * journal, events, snapshots * cytoscape visualisation plugin * resourceful controller suite + REST API server * example: connectivity UX backend * testing: test resource drivers * exchange: trigger/expect style driver for single node and its peers * sessions: for unit testing protocols and protocol modules * (network: for network testing, benchmarking, stats, correctness, fault tolerance) * test peerpool see more in the README-s in each subpackage * p2p/server : conn/disconn hooks * reporter remote client skeleton
22 lines
378 B
Go
22 lines
378 B
Go
package main
|
|
|
|
import (
|
|
"runtime"
|
|
|
|
"github.com/ethereum/go-ethereum/logger/glog"
|
|
"github.com/ethereum/go-ethereum/p2p/simulations"
|
|
)
|
|
|
|
// var server
|
|
func main() {
|
|
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
glog.SetV(6)
|
|
glog.SetToStderr(true)
|
|
|
|
c, quitc := simulations.NewSessionController()
|
|
|
|
simulations.StartRestApiServer("8888", c)
|
|
// wait until server shuts down
|
|
<-quitc
|
|
|
|
}
|