* Only insert hard-coded tips if both DB and files recovery failed
* Prevent deadlock
* Report some efficiency numbers
* Count properly unrequested bodies
* Initialise allRequests
* Increase timeout
* Fixes to scheduling
* Small fix
* Simplified scheduling
* Remove separate bodyLoop goroutine
* Update from DB at the beginnig of block bodies forward
* Timeout for repeating the request cycle
* Fix timeout
* Fix
* Increase timeout
* Increase timeout
* Try to make flow if possible
* Fix flow
* Lower timeout
* timeout for each blockNum
* Adjustable timeout
* Better log timing
* Track peers
* copy peerID
* fix scheduling
* Too much logging
* Print delivery speed
* Print committed blocks
* Fix race
* Sentry to only reset back-off timer when response to a request is received
* Print bytes/sec and wasted traffic
* Fix bandwidth accounting
* Less logging
* not to wake up on deliveries
* Spam every second
* Print peer map
* Fix npe, print requests
* Timestamps
* Improved logging
* Penalty for peers
* Log penalties only when disconnecting
* Try with smaller window
* window parameter
* Dealing with partially delivered requests
* Init bodyReq
* Fix array index
* More fix for NPE
* More NPE checks
* Print out body progress and header progress
* Fix ending condition
* Bring back waking up and penalties
* Fix duplicate tip
* Duplicate segment
* Fix lint
* Fix lint
* fix lint
* Fix lint
* Hard coded headers in the source files
* Fix lint
* Replace hix-sized header serialisation with rlp (to support clique)
* Remove anchor records from the files
* Fixeds for DB recovery
* Fix compilation
* Fix compile errors
* Fix formatting
* Fix lint
* Fix comments
* Remove headerLoop
* Properly terminate body download
* Support for StatusData p2p proto
* Fix forkid test
* Fix test
* Fix lint
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
This change adds a test framework for the "eth" protocol and some basic
tests. The tests can be run using the './devp2p rlpx eth-test' command.
# Conflicts:
# core/forkid/forkid.go
# eth/discovery.go
# eth/handler.go
# eth/helper_test.go
# eth/protocol_test.go
This PR reimplements the light client server pool. It is also a first step
to move certain logic into a new lespay package. This package will contain
the implementation of the lespay token sale functions, the token buying and
selling logic and other components related to peer selection/prioritization
and service quality evaluation. Over the long term this package will be
reusable for incentivizing future protocols.
Since the LES peer logic is now based on enode.Iterator, it can now use
DNS-based fallback discovery to find servers.
This document describes the function of the new components:
https://gist.github.com/zsfelfoldi/3c7ace895234b7b345ab4f71dab102d4
# Conflicts:
# cmd/utils/flags.go
# core/forkid/forkid.go
# les/client.go
# les/client_handler.go
# les/commons.go
# les/distributor.go
# les/enr_entry.go
# les/fetcher.go
# les/lespay/client/valuetracker.go
# les/metrics.go
# les/peer.go
# les/protocol.go
# les/retrieve.go
# les/server.go
# les/serverpool.go
# les/test_helper.go
# les/utils/expiredvalue.go
# les/utils/weighted_select.go
# les/utils/weighted_select_test.go
# params/bootnodes.go
* build: use golangci-lint
This changes build/ci.go to download and run golangci-lint instead
of gometalinter.
* core/state: fix unnecessary conversion
* p2p/simulations: fix lock copying (found by go vet)
* signer/core: fix unnecessary conversions
* crypto/ecies: remove unused function cmpPublic
* core/rawdb: remove unused function print
* core/state: remove unused function xTestFuzzCutter
* core/vm: disable TestWriteExpectedValues in a different way
* core/forkid: remove unused function checksum
* les: remove unused type proofsData
* cmd/utils: remove unused functions prefixedNames, prefixFor
* crypto/bn256: run goimports
* p2p/nat: fix goimports lint issue
* cmd/clef: avoid using unkeyed struct fields
* les: cancel context in testRequest
* rlp: delete unreachable code
* core: gofmt
* internal/build: simplify DownloadFile for Go 1.11 compatibility
* build: remove go test --short flag
* .travis.yml: disable build cache
* whisper/whisperv6: fix ineffectual assignment in TestWhisperIdentityManagement
* .golangci.yml: enable goconst and ineffassign linters
* build: print message when there are no lint issues
* internal/build: refactor download a bit
* eth: chain config (genesis + fork) ENR entry
* core/forkid, eth: protocol independent fork ID, update to CRC32 spec
* core/forkid, eth: make forkid a struct, next uint64, enr struct, RLP
* core/forkid: change forkhash rlp encoding from int to [4]byte
* eth: fixup eth entry a bit and update it every block
* eth: fix lint
* eth: fix crash in ethclient tests