aboutsummaryrefslogtreecommitdiffstats
path: root/les/request_test.go
Commit message (Collapse)AuthorAgeFilesLines
* les: limit state ODR retrievals to the last 100 blocks (#17744)Felföldi Zsolt2018-10-011-1/+1
|
* all: make indexer configurable (#17188)gary rong2018-08-281-31/+12
|
* light: CHT and bloom trie indexers working in light mode (#16534)Felföldi Zsolt2018-08-161-1/+2
| | | | | | | This PR enables the indexers to work in light client mode by downloading a part of these tries (the Merkle proofs of the last values of the last known section) in order to be able to add new values and recalculate subsequent hashes. It also adds CHT data to NodeInfo.
* all: get rid of error when creating memory database (#16716)gary rong2018-05-091-2/+2
| | | | | | | | * all: get rid of error when create mdb * core: clean up variables definition * all: inline mdb definition
* core/rawdb: separate raw database access to own package (#16666)Péter Szilágyi2018-05-071-5/+12
|
* les, light: LES/2 protocol version (#14970)Felföldi Zsolt2017-10-241-1/+10
| | | | | | | | | | | | | | | | | | This PR implements the new LES protocol version extensions: * new and more efficient Merkle proofs reply format (when replying to a multiple Merkle proofs request, we just send a single set of trie nodes containing all necessary nodes) * BBT (BloomBitsTrie) works similarly to the existing CHT and contains the bloombits search data to speed up log searches * GetTxStatusMsg returns the inclusion position or the pending/queued/unknown state of a transaction referenced by hash * an optional signature of new block data (number/hash/td) can be included in AnnounceMsg to provide an option for "very light clients" (mobile/embedded devices) to skip expensive Ethash check and accept multiple signatures of somewhat trusted servers (still a lot better than trusting a single server completely and retrieving everything through RPC). The new client mode is not implemented in this PR, just the protocol extension.
* core/state: access trie through Database interface, track errors (#14589)Felix Lange2017-06-271-1/+1
| | | | | | | | | With this commit, core/state's access to the underlying key/value database is mediated through an interface. Database errors are tracked in StateDB and returned by CommitTo or the new Error method. Motivation for this change: We can remove the light client's duplicated copy of core/state. The light client now supports node iteration, so tracing and storage enumeration can work with the light client (not implemented in this commit).
* les: code refactoring (#14416)Felföldi Zsolt2017-06-211-10/+17
| | | | | | | | | | | | This commit does various code refactorings: - generalizes and moves the request retrieval/timeout/resend logic out of LesOdr (will be used by a subsequent PR) - reworks the peer management logic so that all services can register with peerSet to get notified about added/dropped peers (also gets rid of the ugly getAllPeers callback in requestDistributor) - moves peerSet, LesOdr, requestDistributor and retrieveManager initialization out of ProtocolManager because I believe they do not really belong there and the whole init process was ugly and ad-hoc
* all: import "context" instead of "golang.org/x/net/context"Felix Lange2017-03-231-2/+4
| | | | | | | | | | There is no need to depend on the old context package now that the minimum Go version is 1.7. The move to "context" eliminates our weird vendoring setup. Some vendored code still uses golang.org/x/net/context and it is now vendored in the normal way. This change triggered new vet checks around context.WithTimeout which didn't fire with golang.org/x/net/context.
* les: implement request distributor, fix blocking issues (#3660)Felföldi Zsolt2017-03-231-0/+3
| | | | | * les: implement request distributor, fix blocking issues * core: moved header validation before chain mutex lock
* les: fixed selectPeer deadlock, improved request distributionZsolt Felfoldi2017-01-061-3/+4
| | | | les/flowcontrol: using proper types for relative and absolute times
* les: improved header fetcher and server statisticsZsolt Felfoldi2016-12-101-3/+4
|
* all: update license informationFelix Lange2016-11-091-0/+16
|
* core/types: remove header accessorsFelix Lange2016-11-091-2/+2
| | | | | | These accessors were introduced by light client changes, but the only method that is actually used is GetNumberU64. This commit replaces all uses of .GetNumberU64 with .Number.Uint64.
* les: light client protocol and APIZsolt Felfoldi2016-11-091-0/+94