* Add a `fastmap` crate that provides the H256FastMap specialized HashMap
* Use `fastmap` instead of `plain_hasher`
* Update submodules for Reasons™
* Submodule update
Closes#9255
This PR also removes the limit of max 64 transactions per packet, currently we only attempt to prevent the packet size to go over 8MB. This will only be the case for super-large transactions or high-block-gas-limit chains.
Patching this is important only for chains that have blocks that can fit more than 4k transactions (over 86M block gas limit)
For mainnet, we should actually see a tiny bit faster propagation since instead of computing 4k pending set, we only need `4 * 8M / 21k = 1523` transactions.
Running some tests on `dekompile` node right now, to check how it performs in the wild.
Previously we only allow downloading of old blocks if the peer
difficulty was greater than our syncing difficulty. This change allows
downloading of blocks from peers where the difficulty is greater then
the last downloaded old block.
* Bump parking_lot to 0.6
* Bump parity-wasm to 0.31 so it gets rid of parking_lot
ref https://github.com/paritytech/parity-wasm/pull/206
* Update jsonrpc versions
* Update wasmi and pwasm-utils version
* Fix compile
* Update jsonrpc crates
* Store recently rejected transactions.
* Don't cache AlreadyImported rejections.
* Make the size of transaction verification queue dependent on pool size.
* Add a test for recently rejected.
* Fix logging for recently rejected.
* Make rejection cache smaller.
* obsolete test removed
* obsolete test removed
* Construct cache with_capacity.
The `patricia_trie` crate is generic over the hasher (by way of HashDB) and node encoding scheme. Adds a new `patricia_trie_ethereum` crate with concrete impls for Keccak/RLP.
* new blooms database
* fixed conflict in Cargo.lock
* removed bloomchain
* cleanup in progress
* all tests passing in trace db with new blooms-db
* added trace_blooms to BlockChainDB interface, fixed db flushing
* BlockChainDB no longer exposes RwLock in the interface
* automatically flush blooms-db after every insert
* blooms-db uses io::BufReader to read files, wrap blooms-db into Mutex, cause fs::File is just a shared file handle
* fix json_tests
* blooms-db can filter multiple possibilities at the same time
* removed enum trace/db.rs CacheId
* lint fixes
* fixed tests
* kvdb-rocksdb uses fs-swap crate
* update Cargo.lock
* use fs::rename
* fixed failing test on linux
* fix tests
* use fs_swap
* fixed failing test on linux
* cleanup after swap
* fix tests
* fixed osx permissions
* simplify parity database opening functions
* added migration to blooms-db
* address @niklasad1 grumbles
* fix license and authors field of blooms-db Cargo.toml
* restore blooms-db after snapshot
* Unordered iterator.
* Use unordered and limited set if full not required.
* Split timeout work into smaller timers.
* Avoid collecting all pending transactions when mining
* Remove println.
* Use priority ordering in eth-filter.
* Fix ethcore-miner tests and tx propagation.
* Review grumbles addressed.
* Add test for unordered not populating the cache.
* Fix ethcore tests.
* Fix light tests.
* Fix ethcore-sync tests.
* Fix RPC tests.
* Mark test helpers and test-only specs as cfg(test)
* Use test-probe to conditionally compile test helpers
* Remove test probe and directly use features tag
* Update `add_license` script
* run script
* add `remove duplicate lines script` and run it
* Revert changes `English spaces`
* strip whitespaces
* Revert `GPL` in files with `apache/mit license`
* don't append `gpl license` in files with other lic
* Don't append `gpl header` in files with other lic.
* re-ran script
* include c and cpp files too
* remove duplicate header
* rebase nit
* rlp::decode returns Result
* Fix journaldb to handle rlp::decode Result
* Fix ethcore to work with rlp::decode returning Result
* Light client handles rlp::decode returning Result
* Fix tests in rlp_derive
* Fix tests
* Cleanup
* cleanup
* Allow panic rather than breaking out of iterator
* Let decoding failures when reading from disk blow up
* syntax
* Fix the trivial grumbles
* Fix failing tests
* Make Account::from_rlp return Result
* Syntx, sigh
* Temp-fix for decoding failures
* Header::decode returns Result
Handle new return type throughout the code base.
* Do not continue reading from the DB when a value could not be read
* Fix tests
* Handle header decoding in light_sync
* Handling header decoding errors
* Let the DecodeError bubble up unchanged
* Remove redundant error conversion
* Alter IO queueing.
* Don't require IoMessages to be Clone
* Ancient blocks imported via IoChannel.
* Get rid of private transactions io message.
* Get rid of deadlock and fix disconnected handler.
* Revert to old disconnect condition.
* Fix tests.
* Fix deadlock.
* Keep all enacted blocks notify in order
* Collect is unnecessary
* Update ChainNotify to use ChainRouteType
* Fix all ethcore fn defs
* Wrap the type within ChainRoute
* Fix private-tx and sync api
* Fix secret_store API
* Fix updater API
* Fix rpc api
* Fix informant api
* Eagerly cache enacted/retracted and remove contain_enacted/retracted
* Fix indent
* tests: should use full expr form for struct constructor
* Use into_enacted_retracted to further avoid copy
* typo: not a function
* rpc/tests: ChainRoute -> ChainRoute::new
* WIP
* Convert Ethcore error to use error_chain
* Use error_chain for ImportError and BlockImportError
* Fix error pattern matches for error_chain in miner
* Implement explicit From for AccountsError
* Fix pattern matches for ErrorKinds
* Handle ethcore error_chain in light client
* Explicitly define Result type to avoid shadowing
* Fix remaining Error pattern matches
* Fix tab space formatting
* Helps if the tests compile
* Fix error chain matching after merge
* WIP
* Replace Rlp with UntrustedRlp in views, explicity unwrap with expect
First pass to get it to compile. Need to figure out whether to do this or to propogate Errors upstream, which would require many more changes to dependent code. If we do this way we are assuming that the views are always used in a context where the rlp is trusted to be valid e.g. when reading from our own DB. So need to fid out whether views are used with data received from an untrusted (e.g. extrernal peer).
* Remove original Rlp impl, rename UntrustedRlp -> Rlp
* Create rlp views with view! macro to record debug info
Views are assumed to be over valid rlp, so if there is a decoding error we record where the view was created in the first place and report it in the expect
* Use $crate in view! macro to avoid import, fix tests
* Expect valid rlp in decode functions for now
* Replace spaces with tabs in new file
* Add doc tests for creating views with macro
* Update rlp docs to reflect removing of UntrustedRlp
* Replace UntrustedRlp usages in private-tx merge
* Implementation of Verifier, Scoring and Ready.
* Queue in progress.
* TransactionPool.
* Prepare for txpool release.
* Miner refactor [WiP]
* WiP reworking miner.
* Make it compile.
* Add some docs.
* Split blockchain access to a separate file.
* Work on miner API.
* Fix ethcore tests.
* Refactor miner interface for sealing/work packages.
* Implement next nonce.
* RPC compiles.
* Implement couple of missing methdods for RPC.
* Add transaction queue listeners.
* Compiles!
* Clean-up and parallelize.
* Get rid of RefCell in header.
* Revert "Get rid of RefCell in header."
This reverts commit 0f2424c9b7319a786e1565ea2a8a6d801a21b4fb.
* Override Sync requirement.
* Fix status display.
* Unify logging.
* Extract some cheap checks.
* Measurements and optimizations.
* Fix scoring bug, heap size of bug and add cache
* Disable tx queueing and parallel verification.
* Make ethcore and ethcore-miner compile again.
* Make RPC compile again.
* Bunch of txpool tests.
* Migrate transaction queue tests.
* Nonce Cap
* Nonce cap cache and tests.
* Remove stale future transactions from the queue.
* Optimize scoring and write some tests.
* Simple penalization.
* Clean up and support for different scoring algorithms.
* Add CLI parameters for the new queue.
* Remove banning queue.
* Disable debug build.
* Change per_sender limit to be 1% instead of 5%
* Avoid cloning when propagating transactions.
* Remove old todo.
* Post-review fixes.
* Fix miner options default.
* Implement back ready transactions for light client.
* Get rid of from_pending_block
* Pass rejection reason.
* Add more details to drop.
* Rollback heap size of.
* Avoid cloning hashes when propagating and include more details on rejection.
* Fix tests.
* Introduce nonces cache.
* Remove uneccessary hashes allocation.
* Lower the mem limit.
* Re-enable parallel verification.
* Add miner log. Don't check the type if not below min_gas_price.
* Add more traces, fix disabling miner.
* Fix creating pending blocks twice on AuRa authorities.
* Fix tests.
* re-use pending blocks in AuRa
* Use reseal_min_period to prevent too frequent update_sealing.
* Fix log to contain hash not sender.
* Optimize local transactions.
* Fix aura tests.
* Update locks comments.
* Get rid of unsafe Sync impl.
* Review fixes.
* Remove excessive matches.
* Fix compilation errors.
* Use new pool in private transactions.
* Fix private-tx test.
* Fix secret store tests.
* Actually use gas_floor_target
* Fix config tests.
* Fix pool tests.
* Address grumbles.