* Make it possible to explicitly disable discovery
Discovery will be disabled in following cases:
- if there are not bootnodes - v5 server will be disabled
because there is no point in running it
- if user defined in config NoDiscovery=true this value will be preserved
even if we have bootnodes
So, basically discovery will be always enabled by default on mobile, unless
it is explicitly specified otherwise.
When statusd is used current behavior is that discovery is disabled by default.
I kept it in this change, but it would be better to change it.
* Fix leftovers
* Add wait group to peer pool to protect from races with p2p.Server
* Change fields only when all goroutines finished
* Turn off discovery after topic searches are stopped
* Don't set period to nil to avoid race with SearchTopic
* Close period chan only when all writers are finished
* add `-status` flag to enable the Status service
* remove status from default APIModules and add it only from statusd if specified
* remove AddAPIModule method
* allow -status flag values to be http or ipc
* add LogEnabled attribute to NodeConfig, used in the call from status-react
* fix use of OverrideRootLogin in tests
* enable logger in tests based on LogLevel
* move LogEnabled before LogFile
* Add default peer limits configuration
If discovery is enabled for a given cluster - we will set a default
expected number of peers for each enabled service. For example:
- if cluster is rinkeby has a discovery enabled we will
check which services are enabled
- if whisper is enabled we will set min and max limits by default
- if les is enabled and infura is not used we will set limits too
When statusd is used - configuration must be provided using configuration
supported by statusd.
* Fix deadlock in les peer set
* Start enabling to test Mainnet
* Minor corrections found during code scan
* Set mainnet blocker in E2E again
* Introduced securing of mainnet transaction tests
* Fix typing error
* Typo led to follow-up errors
* Linter problem
* Change to individual test skips after review
* More flexible skip control for mainnet and status chain
* Fix double space
* Change of skipping method and fixing wrong skipped networks
This change will greatly simplify writing unit tests when a node is required but data persistence is irrelevant.
I also Introduced some refactoring and unit tests for `StatusNode`.
We need to be able to sign more than just transactions to make DApps
work properly. This change separates signing requests from the
transactions and make it more general to prepare to intoduce different
types of signing requests.
This change is designed to preserve status APIs, so it is
backward-comparible with the current API bindings.
* Rename bootnode to static peers
Also add some groupings between types.
* Remove not needed genesisHash
* More cleanup of bootnodes with static peers
* Add option of cluster configuration file
* New generated bindata.go
* Changes after npm install
* Add argument for cluster configuration file
* Add test for dynamic cluster loading
Not yet sure with name "cluster config".
* Solved conflicts
* Renaming of static peers
* Remove static peers population
* Missing argument for config
* Renaming of static peers to boot nodes for consistency
* Fix of name change
* Cluster config is now cluster data
* Load static nodes from configuration
* Final renaming of var for file content
* Add debug log to test package t
* Add comments for test restrictions
* Add explicit errors for mainnet
* Panic instead of error in case of mainnet during tests
* Now panic with illegal network
* Validate the compiler flag for mainnet
* Made test for unset mainnet explicit
* Forgot to use my flag
* Linter has troubles with unused field
* Add default network id
In e2e tests there's no default anymore in go code. So ensure in Makefile.
* Fix dumb syntax error
* CI needs build with Mainnet
* Explicit rebuild only for tests
* No more separation of mainnet and testnet builds
* Build flags now set in Makefile
* Update project to use Whisper v6. Part of #638
* Revert "Add patch to downgrade usage of Whisper v6 to v5 in some geth 1.8.1 vendor files. Part of #665" - this reverts commit 6aefb4c8fd02dbcfffac6b69e8bb22b13ef86b6b.
* Enable light mode on Whisper v6 for non-mail servers. Part of #638
* Fix race condition in whisperv6/peer.go. Part of #665 (PR already accepted upstream for 1.8.2)
* Update bootnode addresses in staticnodes.json. Part of #638
* Add `shh.lightclient` flag and tests for bloom filter setting logic. Part of #638
* Move MakeTestNodeConfig to utils. Part of #638
* Reduce PoW in `whisper_jail_test.go` to fix flaky test. Part of #638
1. A new private testing network (StatusChain) is introduced.
2. An example test case implemented (TestSendEtherOnStatusChainTx)
3. Genesis file added static/config/status-chain-genesis.json
This change moves our e2e tests into a separate package to make room for proper unit and integration tests.
This is Phase 1 described in #371.
Changes:
Makefile has separate directives to run unit/integration tests and e2e tests,
CI runs unit/integration tests first and then e2e tests,
E2e tests are in reliability order, i.e. the least reliable tests are run in the end to be sure that nothing else is broken,
Some tests are fixed or quarantined.