aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/swarm
Commit message (Collapse)AuthorAgeFilesLines
* cmd/swarm, metrics, swarm/api/client, swarm/storage, swarm/metrics, ↵Elad2018-12-113-62/+233
| | | | swarm/api/http: add instrumentation (#18274)
* cmd/swarm: add flag for application name (swarm or swarm-private) (#18189)Anton Evangelatov2018-11-303-7/+14
| | | | | | | | | | * cmd/swarm: add flag for application name (swarm or swarm-private) * cmd/swarm/swarm-smoke: return correct exit code * cmd/swarm/swarm-smoke: remove colorable * remove swarm/grafana_dashboards
* cmd/swarm: update should error on manifest mismatch (#18047)Javier Peletier2018-11-272-6/+41
| | | | | | | | | | * cmd/swarm: fix ethersphere/go-ethereum#979: update should error on manifest mistmatch * cmd/swarm: fixed comments and remove sprintf from log.Info * cmd/swarm: remove unnecessary comment
* Remove multihash from Swarm bzz:// for Feeds (#18175)Javier Peletier2018-11-261-4/+2
|
* cmd/swarm: FUSE do not require --ipcpath (#18112)Ferenc Szabo2018-11-233-35/+55
| | | | | | | | | - Have `${DataDir}/bzzd.ipc` as IPC path default. - Respect the `--datadir` flag. - Keep only the global `--ipcpath` flag and drop the local `--ipcpath` flag as flags might overwrite each other. (Note: before global `--ipcpath` was ignored even if it was set) fixes ethersphere#795
* cmd/swarm/swarm-smoke: update smoke tests to fit the new scheme for the k8s ↵Anton Evangelatov2018-11-192-12/+15
| | | | cluster (#18104)
* cmd/swarm: speed up tests - use global cluster (#18129)Anton Evangelatov2018-11-196-92/+101
|
* cmd/swarm, swarm/api/http, swarm/bmt, swarm/fuse, swarm/network/stream, ↵Alexey Sharov2018-11-146-79/+29
| | | | | | swarm/storage, swarm/storage/encryption, swarm/testutil: use pseudo-random instead of crypto-random for test files content generation (#18083) - Replace "crypto/rand" to "math/rand" for files content generation - Remove swarm/network_test.go.Shuffle and swarm/btm/btm_test.go.Shuffle - because go1.9 support dropped (see https://github.com/ethereum/go-ethereum/pull/17807 and comments to swarm/network_test.go.Shuffle)
* Imply that SwarmApiFlag is the API endpoint to connect to, not to listen on ↵Andrew Chiw2018-11-121-1/+1
| | | | (#18071)
* swarm, cmd/swarm: address ineffectual assignments (#18048)Anton Evangelatov2018-11-083-2/+10
| | | | | | | | * swarm, cmd/swarm: address ineffectual assignments * swarm/network: remove unused vars from testHandshake * swarm/storage/feed: revert cursor changes
* cmd/swarm: auto resolve default path according to env flag (#17960)Elad2018-11-042-10/+29
|
* cmd/swarm/swarm-smoke: fix issue that loop variable capture in func (#17992)Roc Yu2018-10-291-8/+5
|
* cmd/swarm: Smoke test for Swarm Feed (#17892)lash2018-10-123-6/+351
|
* cmd/swarm: split flags and cli command declarations to the relevant files ↵Elad2018-10-1211-422/+468
| | | | (#17896)
* cmd/swarm: speed up tests (#17878)Elad2018-10-094-31/+38
| | | These minor changes already shaved off around 30s.
* cmd/swarm: disable tests under Windows until they are fixed (#17827)Anton Evangelatov2018-10-041-0/+17
|
* Merge pull request #17796 from epiclabs-io/mru-feedsViktor Trón2018-10-033-91/+91
|\ | | | | swarm/storage/feeds: Renamed MRU to Swarm Feeds
| * swarm/storage/feed: Renamed packageJavier Peletier2018-10-032-18/+18
| |
| * swarm/storage/feeds: renamed vars that can conflict with package nameJavier Peletier2018-10-031-4/+4
| |
| * swarm/storage/feeds: removed capital Feed throughoutJavier Peletier2018-10-033-6/+6
| |
| * swarm/storage/feeds: Final package rename and moved filesJavier Peletier2018-10-032-21/+21
| |
| * swarm/storage/mru: Renamed rest of MRU referencesJavier Peletier2018-10-033-76/+76
| |
| * swarm/storage/mru: Renamed all identifiers to FeedsJavier Peletier2018-10-032-5/+5
| |
* | swarm: schemas and migrations (#17813)Anton Evangelatov2018-10-032-23/+0
|/
* cmd/swarm: fix appveyor build (#17808)Elad2018-10-023-7/+24
|
* Merge pull request #17771 from ethersphere/cmd-config-errorsViktor Trón2018-10-021-13/+30
|\ | | | | swarm: handle errors in cmdLineOverride and envVarsOverride
| * cmd/swarm: fix TestConfigFileOverridesJanos Guljas2018-09-282-3/+6
| |
| * cmd/swarm: handle errors in cmdLineOverride and envVarsOverride functionsJanos Guljas2018-09-272-13/+27
| |
* | Merge pull request #17799 from ethersphere/correct_swarm_versionViktor Trón2018-10-021-2/+2
|\ \ | | | | | | cmd/swarm: correct swarm version on --help
| * | cmd/swarm: correct swarm version on --helpAnton Evangelatov2018-10-011-2/+2
| | |
* | | cmd/swarm: disable export and upload tests on WindowsAnton Evangelatov2018-10-012-0/+4
| | |
* | | cmd/swarm, swarm: cross-platform Content-Type detection (#17782)Alexey Sharov2018-10-014-23/+1957
|/ / | | | | | | | | | | | | - Mime types generator (Standard "mime" package rely on system-settings, see mime.osInitMime) - Changed swarm/api.Upload: - simplify I/O throttling by semaphore primitive and use file name where possible - f.Close() must be called in Defer - otherwise panic or future added early return will cause leak of file descriptors - one error was suppressed
* | cmd/swarm: remove swarm binary (#17784)Wenbiao Zheng2018-09-301-0/+0
| |
* | cmd/swarm: respect --loglevel in run_test helpers (#17739)Ferenc Szabo2018-09-291-2/+2
| | | | | | | | | | | | | | When CLI tests were spanning new nodes, the log level verbosity was hard coded as 6. So the Swarm process was always polluting the test output with TRACE level logs. Now `go test -v ./cmd/swarm -loglevel 0` works as expected.
* | cmd/swarm: trim new lines from filesAnton Evangelatov2018-09-281-2/+2
| |
* | Swarm MRUs: Adaptive frequency / Predictable lookups / API simplification ↵Javier Peletier2018-09-284-82/+301
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#17559) * swarm/storage/mru: Adaptive Frequency swarm/storage/mru/lookup: fixed getBaseTime Added NewEpoch constructor swarm/api/client: better error handling in GetResource() swarm/storage/mru: Renamed structures. Renamed ResourceMetadata to ResourceID. Renamed ResourceID.Name to ResourceID.Topic swarm/storage/mru: Added binarySerializer interface and test tools swarm/storage/mru/lookup: Changed base time to time and + marshallers swarm/storage/mru: Added ResourceID (former resourceMetadata) swarm/storage/mru: Added ResourceViewId and serialization tests swarm/storage/mru/lookup: fixed epoch unmarshaller. Added Epoch Equals swarm/storage/mru: Fixes as per review comments cmd/swarm: reworded resource create/update help text regarding topic swarm/storage/mru: Added UpdateLookup and serializer tests swarm/storage/mru: Added UpdateHeader, serializers and tests swarm/storage/mru: changed UpdateAddr / epoch to Base() swarm/storage/mru: Added resourceUpdate serializer and tests swarm/storage/mru: Added SignedResourceUpdate tests and serializers swarm/storage/mru/lookup: fixed GetFirstEpoch bug swarm/storage/mru: refactor, comments, cleanup Also added tests for Topic swarm/storage/mru: handler tests pass swarm/storage/mru: all resource package tests pass swarm/storage/mru: resource test pass after adding timestamp checking support swarm/storage/mru: Added JSON serializers to ResourceIDView structures swarm/storage/mru: Sever, client, API test pass swarm/storage/mru: server test pass swarm/storage/mru: Added topic length check swarm/storage/mru: removed some literals, improved "previous lookup" test case swarm/storage/mru: some fixes and comments as per review swarm/storage/mru: first working version without metadata chunk swarm/storage/mru: Various fixes as per review swarm/storage/mru: client test pass swarm/storage/mru: resource query strings and manifest-less queries swarm/storage/mru: simplify naming swarm/storage/mru: first autofreq working version swarm/storage/mru: renamed ToValues to AppendValues swarm/resource/mru: Added ToValues / FromValues for URL query strings swarm/storage/mru: Changed POST resource to work with query strings. No more JSON. swarm/storage/mru: removed resourceid swarm/storage/mru: Opened up structures swarm/storage/mru: Merged Request and SignedResourceUpdate swarm/storage/mru: removed initial data from CLI resource create swarm/storage/mru: Refactor Topic as a direct fixed-length array swarm/storage/mru/lookup: Comprehensive GetNextLevel tests swarm/storage/mru: Added comments Added length checks in Topic swarm/storage/mru: fixes in tests and some code comments swarm/storage/mru/lookup: new optimized lookup algorithm swarm/api: moved getResourceView to api out of server swarm/storage/mru: Lookup algorithm working swarm/storage/mru: comments and renamed NewLookupParams Deleted commented code swarm/storage/mru/lookup: renamed Epoch.LaterThan to After swarm/storage/mru/lookup: Comments and tidying naming swarm/storage/mru: fix lookup algorithm swarm/storage/mru: exposed lookup hint removed updateheader swarm/storage/mru/lookup: changed GetNextEpoch for initial values swarm/storage/mru: resource tests pass swarm/storage/mru: valueSerializer interface and tests swarm/storage/mru/lookup: Comments, improvements, fixes, more tests swarm/storage/mru: renamed UpdateLookup to ID, LookupParams to Query swarm/storage/mru: renamed query receiver var swarm/cmd: MRU CLI tests * cmd/swarm: remove rogue fmt * swarm/storage/mru: Add version / header for future use * swarm/storage/mru: Fixes/comments as per review cmd/swarm: remove rogue fmt swarm/storage/mru: Add version / header for future use- * swarm/storage/mru: fix linter errors * cmd/swarm: Speeded up TestCLIResourceUpdate
* | cmd/swarm: fail on SWARM_ENV_MAX_STREAM_PEER_SERVERS parsing errorJanos Guljas2018-09-271-2/+4
| |
* | Merge branch 'master' into max-stream-peer-serversJanos Guljas2018-09-272-3/+13
|\|
| * Merge pull request #17755 from JekaMas/implement-home-directory-expansionViktor Trón2018-09-272-3/+13
| |\ | | | | | | cmd/swarm: use expandPath for swarm cli path parameters
| | * cmd/swarm: use expandPath for swarm cli path parametersEvgeny Danienko2018-09-252-3/+13
| | |
* | | Merge branch 'master' into max-stream-peer-serversJanos Guljas2018-09-252-9/+10
|\| |
| * | all: new p2p node representation (#17643)Felix Lange2018-09-252-9/+10
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Package p2p/enode provides a generalized representation of p2p nodes which can contain arbitrary information in key/value pairs. It is also the new home for the node database. The "v4" identity scheme is also moved here from p2p/enr to remove the dependency on Ethereum crypto from that package. Record signature handling is changed significantly. The identity scheme registry is removed and acceptable schemes must be passed to any method that needs identity. This means records must now be validated explicitly after decoding. The enode API is designed to make signature handling easy and safe: most APIs around the codebase work with enode.Node, which is a wrapper around a valid record. Going from enr.Record to enode.Node requires a valid signature. * p2p/discover: port to p2p/enode This ports the discovery code to the new node representation in p2p/enode. The wire protocol is unchanged, this can be considered a refactoring change. The Kademlia table can now deal with nodes using an arbitrary identity scheme. This requires a few incompatible API changes: - Table.Lookup is not available anymore. It used to take a public key as argument because v4 protocol requires one. Its replacement is LookupRandom. - Table.Resolve takes *enode.Node instead of NodeID. This is also for v4 protocol compatibility because nodes cannot be looked up by ID alone. - Types Node and NodeID are gone. Further commits in the series will be fixes all over the the codebase to deal with those removals. * p2p: port to p2p/enode and discovery changes This adapts package p2p to the changes in p2p/discover. All uses of discover.Node and discover.NodeID are replaced by their equivalents from p2p/enode. New API is added to retrieve the enode.Node instance of a peer. The behavior of Server.Self with discovery disabled is improved. It now tries much harder to report a working IP address, falling back to 127.0.0.1 if no suitable address can be determined through other means. These changes were needed for tests of other packages later in the series. * p2p/simulations, p2p/testing: port to p2p/enode No surprises here, mostly replacements of discover.Node, discover.NodeID with their new equivalents. The 'interesting' API changes are: - testing.ProtocolSession tracks complete nodes, not just their IDs. - adapters.NodeConfig has a new method to create a complete node. These changes were needed to make swarm tests work. Note that the NodeID change makes the code incompatible with old simulation snapshots. * whisper/whisperv5, whisper/whisperv6: port to p2p/enode This port was easy because whisper uses []byte for node IDs and URL strings in the API. * eth: port to p2p/enode Again, easy to port because eth uses strings for node IDs and doesn't care about node information in any way. * les: port to p2p/enode Apart from replacing discover.NodeID with enode.ID, most changes are in the server pool code. It now deals with complete nodes instead of (Pubkey, IP, Port) triples. The database format is unchanged for now, but we should probably change it to use the node database later. * node: port to p2p/enode This change simply replaces discover.Node and discover.NodeID with their new equivalents. * swarm/network: port to p2p/enode Swarm has its own node address representation, BzzAddr, containing both an overlay address (the hash of a secp256k1 public key) and an underlay address (enode:// URL). There are no changes to the BzzAddr format in this commit, but certain operations such as creating a BzzAddr from a node ID are now impossible because node IDs aren't public keys anymore. Most swarm-related changes in the series remove uses of NewAddrFromNodeID, replacing it with NewAddr which takes a complete node as argument. ToOverlayAddr is removed because we can just use the node ID directly.
* / cmd/swarm, swarm: add stream peer servers limitJanos Guljas2018-09-242-21/+38
|/
* swarm: Chunk refactor (#17659)Balint Gabor2018-09-133-13/+13
| | | | | | Co-authored-by: Janos Guljas <janos@resenje.org> Co-authored-by: Balint Gabor <balint.g@gmail.com> Co-authored-by: Anton Evangelatov <anton.evangelatov@gmail.com> Co-authored-by: Viktor Trón <viktor.tron@gmail.com>
* Merge pull request #17651 from ethersphere/wet-run-bugViktor Trón2018-09-121-1/+0
|\ | | | | cmd/swarm: password threw on upload manifest
| * cmd/swarm: password threw on upload manifestElad2018-09-121-1/+0
| |
* | cmd/swarm: added password to ACT (#17598)Elad2018-09-073-127/+97
|/
* cmd/swarm: added publisher key assertion to act tests (#17471)Elad2018-09-052-4/+64
|
* cmd/swarm: added scaling test for ACT manifests (#17496)Elad2018-09-041-6/+37
|
* cmd/swarm: disable ACT tests on windows (#17536)Anton Evangelatov2018-08-291-0/+3
|
* cmd/swarm: added swarm bootnodes (#17414)Elad2018-08-203-38/+98
|
* cmd/swarm, swarm: added access control functionality (#17404)Elad2018-08-157-34/+929
| | | | | Co-authored-by: Janos Guljas <janos@resenje.org> Co-authored-by: Anton Evangelatov <anton.evangelatov@gmail.com> Co-authored-by: Balint Gabor <balint.g@gmail.com>
* Manifest cli fix and upload defaultpath only once (#17375)Janoš Guljaš2018-08-105-128/+787
| | | | | | | | | | | | | | | | * cmd/swarm: fix manifest subcommands and add tests * cmd/swarm: manifest update: update default entry for non-encrypted uploads * swarm/api: upload defaultpath file only once * swarm/api/client: improve UploadDirectory default path handling * cmd/swarm: support absolute and relative default path values * cmd/swarm: fix a typo in test * cmd/swarm: check encrypted uploads in manifest update tests
* cmd/swarm: solve rare cases of using the same random port in tests (#17352)Janoš Guljaš2018-08-092-19/+131
|
* cmd/swarm: disable TestCLISwarmFs fuse test on darwin (#17340)Janoš Guljaš2018-08-091-6/+6
|
* cmd/swarm: remove shadow err (#17360)Anton Evangelatov2018-08-091-2/+3
|
* swarm: Added lightnode flag (#17291)Attila Gazso2018-08-072-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | * swarm: Added lightnode flag Added --lightnode command line parameter Added LightNode to Handshake message * swarm/config: Fixed variable naming * cmd/swarm: Changed BoolTFlag to BoolFlag for SwarmLightNodeEnabled * swarm/network: Changed logging * swarm/network: Changed protocol version testing * swarm/network: Renamed DefaultNetworkID variable to TestProtocolNetworkID * swarm/network: Bumped protocol version * swarm/network: Changed LightNode handhsake test to table driven * swarm/network: Changed back TestProtocolVersion to 5 for now * swarm/network: Moved the test configuration inside the test function scope
* cmd/swarm, swarm: various test fixes (#17299)Janoš Guljaš2018-08-062-1/+6
| | | | | | | | | | | | * swarm/network/simulation: increase the sleep duration for TestRun * cmd/swarm, swarm: fix failing tests on mac * cmd/swarm: update TestCLISwarmFs skip comment * swarm/network/simulation: adjust disconnections on simulation close * swarm/network/simulation: call cleanups after net shutdown
* build: rename swarm deb package to ethereum-swarm; change swarm deb version ↵Anton Evangelatov2018-07-302-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | from 1.8.x to 0.3.x (#16988) * build: add support for different package and binary names * build: bump up copyright date * build: change default PackageName to empty string * build, internal, swarm: enhance build/release process * build: hack ethereum-swarm as a "depends" in deb package * build/ci: remove redundant variables * build, cmd, mobile, params, swarm: remove VERSION file; rename Version to VersionMeta; * internal: remove VERSION() method which reads VERSION file * build: fix VersionFilePath to Version * Makefile: remove clean_go_build_cache.sh until it works * Makefile: revert removal of clean_go_build_cache.sh
* swarm/storage/mru: Client-side MRU signatures (#784)Javier Peletier2018-07-232-0/+236
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * swarm/storage/mru: Add embedded publickey and remove ENS dep This commit breaks swarm, swarm/api... but tests in swarm/storage/mru pass * swarm: Refactor swarm, swarm/api to mru changes, make tests pass * swarm/storage/mru: Remove self from recv, remove test ens vldtr * swarm/storage/mru: Remove redundant test, expose ResourceHash mthd * swarm/storage/mru: Make HeaderGetter mandatory + godoc fixes * swarm/storage: Remove validator prefix for metadata chunk * swarm/storage/mru: Use Address instead of PublicKey * swarm/storage/mru: Change index from name to metadata chunk addr * swarm/storage/mru: Refactor swarm/api/... to MRU index changes * swarm/storage/mru: Refactor cleanup * swarm/storage/mru: Rebase cleanup * swarm: Use constructor for GenericSigner MRU in swarm.go * swarm/storage: Change to BMTHash for MRU hashing * swarm/storage: Reduce loglevel on chunk validator logs * swarm/storage/mru: Delint * swarm: MRU Rebase cleanup * swarm/storage/mru: client-side mru signatures Rebase to PR #668 and fix all conflicts * swarm/storage/mru: refactor and documentation * swarm/resource/mru: error-checking tests for parseUpdate/newUpdateChunk * swarm/storage/mru: Added resourcemetadata tests * swarm/storage/mru: Added tests for UpdateRequest * swarm/storage/mru: more test coverage for UpdateRequest and comments * swarm/storage/mru: Avoid fake chunks in parseUpdate() * swarm/storage/mru: Documented resource.go extensively moved some functions where they make most sense * swarm/storage/mru: increase test coverage for UpdateRequest and variable name changes throughout to increase consistency * swarm/storage/mru: moved default timestamp to NewCreateRequest- * swarm/storage/mru: lookup refactor * swarm/storage/mru: added comments and renamed raw flag to rawmru * swarm/storage/mru: fix receiver typo * swarm/storage/mru: refactored update chunk new/create * swarm/storage/mru: refactored signature digest to avoid malleability * swarm/storage/mru: optimize update data serialization * swarm/storage/mru: refactor and cleanup * swarm/storage/mru: add timestamp struct and serialization * swarm/storage/mru: fix lint error and mark some old code for deletion * swarm/storage/mru: remove unnecessary variable * swarm/storage/mru: Added more comments throughout * swarm/storage/mru: Refactored metadata chunk layout + extensive error... * swarm/storage/mru: refactor cli parser Changed resource info output to JSON * swarm/storage/mru: refactor serialization for extensibility refactored error messages to NewErrorf * swarm/storage/mru: Moved Signature to resource_sign. Check Sign errors in server tests * swarm/storage/mru: Remove isSafeName() checks * swarm/storage/mru: scrubbed off all references to "block" for time * swarm/storage/mru: removed superfluous isSynced() call. * swarm/storage/mru: remove isMultihash() and ToSafeName functions * swarm/storage/mru: various fixes and comments * swarm/storage/mru: decoupled cli for independent create/update * Made resource name optional * Removed unused LookupPrevious * swarm/storage/mru: Decoupled resource create / update & refactor * swarm/storage/mru: Fixed some comments as per issues raised in PR #743 * swarm/storage/mru: Cosmetic changes as per #743 comments * swarm/storage/mru: refct request encoder/decoder > marshal/unmarshal * swarm/storage/mru: Cosmetic changes as per review in #748 * swarm/storage/mru: removed timestamp proof placeholder * swarm/storage/mru: cosmetic/doc/fixes changes as per comments in #704 * swarm/storage/mru: removed unnecessary check in Handler.update * swarm/storage/mru: Implemented Marshaler/Unmarshaler iface in Request * swarm/storage/mru: Fixed linter error * swarm/storage/mru: removed redundant address in signature digest * swarm/storage/mru: fixed bug: LookupLatestVersionInPeriod not working * swarm/storage/mru: Unfold Request creation API for create or update+create set common time source for mru package * swarm/api/http: fix HandleGetResource error variable shadowed when requesting a resource that does not exist * swarm/storage/mru: Add simple check to detect duplicate updates * swarm/storage/mru: moved Multihash() to the right place. * cmd/swarm: remove unneeded clientaccountmanager.go * swarm/storage/mru: Changed some comments as per reviews in #784 * swarm/storage/mru: Made SignedResourceUpdate.GetDigest() public * swarm/storage/mru: cosmetic changes as per comments in #784 * cmd/swarm: Inverted --multihash flag default * swarm/storage/mru: removed Verify from SignedResourceUpdate.fromChunk * swarm/storage/mru: Moved validation code out of serializer Cosmetic / comment changes * swarm/storage/mru: Added unit tests for UpdateLookup * swarm/storage/mru: Increased coverage of metadata serialization * swarm/storage/mru: Increased test coverage of updateHeader serializers * swarm/storage/mru: Add resourceUpdate serializer test
* cmd/swarm: add implicit subcommand help (fix #786) (#788)Javier Peletier2018-07-231-0/+27
| | | | | | * cmd/swarm: add implicit subcommand help (fix #786) * cmd/swarm: moved implicit help to a recursive func
* cmd/swarm: change version of swarm binary (#17174)Anton Evangelatov2018-07-141-1/+1
|
* swarm: integrate OpenTracing; propagate ctx to internal APIs (#17169)Anton Evangelatov2018-07-132-2/+6
| | | | | | * swarm: propagate ctx, enable opentracing * swarm/tracing: log error when tracing is misconfigured
* cmd, dashboard, log: log collection and exploration (#17097)Kurkó Mihály2018-07-111-1/+1
| | | | | | | | | | | | * cmd, dashboard, internal, log, node: logging feature * cmd, dashboard, internal, log: requested changes * dashboard, vendor: gofmt, govendor, use vendored file watcher * dashboard, log: gofmt -s -w, goimports * dashboard, log: gosimple
* swarm: ctx propagation; bmt fixes; pss generic notification framework (#17150)Anton Evangelatov2018-07-094-4/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * cmd/swarm: minor cli flag text adjustments * swarm/api/http: sticky footer for swarm landing page using flex * swarm/api/http: sticky footer for error pages and fix for multiple choices * cmd/swarm, swarm/storage, swarm: fix mingw on windows test issues * cmd/swarm: update description of swarm cmd * swarm: added network ID test * cmd/swarm: support for smoke tests on the production swarm cluster * cmd/swarm/swarm-smoke: simplify cluster logic as per suggestion * swarm: propagate ctx to internal apis (#754) * swarm/metrics: collect disk measurements * swarm/bmt: fix io.Writer interface * Write now tolerates arbitrary variable buffers * added variable buffer tests * Write loop and finalise optimisation * refactor / rename * add tests for empty input * swarm/pss: (UPDATE) Generic notifications package (#744) swarm/pss: Generic package for creating pss notification svcs * swarm: Adding context to more functions * swarm/api: change colour of landing page in templates * swarm/api: change landing page to react to enter keypress
* swarm: network rewrite mergeethersphere2018-06-2215-302/+1559
|
* cmd/swarm: fix some typos in manifest cmd (#16227)Zhenguo Niu2018-03-021-3/+3
| | | Replace "atleast" with "at least" in the manifest error message.
* swarm: initial instrumentation (#15969)Anton Evangelatov2018-02-231-1/+7
| | | | | | | | | | | | | | | | | | * swarm: initial instrumentation with go-metrics * swarm: initialise metrics collection and add ResettingTimer to HTTP requests * swarm: update metrics flags names. remove redundant Timer. * swarm: rename method for periodically updating gauges * swarm: finalise metrics after feedback * swarm/network: always init kad metrics containers * swarm/network: off-by-one index in metrics containers * swarm, metrics: resolved conflicts
* swarm, cmd/swarm: Merge branch 'master' into multiple-ens-endpointsJanos Guljas2018-02-232-2/+2
|\
| * all: update license information (#16089)Felix Lange2018-02-142-2/+2
| |
* | swarm, cmd/swarm: Merge branch 'master' into multiple-ens-endpointsJanos Guljas2018-02-221-1/+1
|\|
| * various: remove redundant parentheses (#15793)Furkan KAMACI2018-01-031-1/+1
| |
* | cmd/swarm: return error early in buildConfig functionJanos Guljas2017-12-201-0/+3
| |
* | cmd/swarm: add validation for EnsAPIs configuration parameterJanos Guljas2017-12-192-0/+130
| |
* | cmd/swarm, swarm: disable ENS API by defaultJanos Guljas2017-12-181-18/+5
| | | | | | | | | | | | Specifying ENS API CLI flag, env variable or configuration field is required for ENS resolving. Backward compatibility is preserved with --ens-api="" CLI flag value.
* | cmd/swarm: Merge branch 'master' into multiple-ens-endpointsJanos Guljas2017-12-142-5/+5
|\| | | | | | | Fix a conflict in cmd/swarm envVarsOverride function.
| * all: use gometalinter.v2, fix new gosimple issues (#15650)Zach2017-12-132-5/+5
| |
* | swarm, cmd/swarm: Merge branch 'master' into multiple-ens-endpointsJanos Guljas2017-12-136-300/+896
|\| | | | | | | | | | | | | | | | | | | | | | | Merge with changes that implement config file PR #15548. Field *EnsApi string* in swarm/api.Config is replaced with *EnsAPIs []string*. A new field *EnsDisabled bool* is added to swarm/api.Config for easy way to disable ENS resolving with config file. Signature of function swarm.NewSwarm is changed and simplified.
| * cmd/swarm: add config file (#15548)holisticode2017-12-124-90/+879
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds a TOML configuration option to swarm. It reuses the TOML configuration structure used in geth with swarm customized items. The commit: * Adds a "dumpconfig" command to the swarm executable which allows printing the (default) configuration to stdout, which then can be redirected to a file in order to customize it. * Adds a "--config <file>" option to the swarm executable which will allow to load a configuration file in TOML format from the specified location in order to initialize the Swarm node The override priorities are like follows: environment variables override command line arguments override config file override default config.
| * buld: enable goconst linter (#15566)Zach2017-11-301-3/+5
| |
* | swarm: deprecate --ens-addr CLI flag with a warning messageJanos Guljas2017-12-051-6/+10
| |
* | swarm: check if "--ens-api ''" is specified in order to disable ENSJanos Guljas2017-12-051-0/+4
| |
* | swarm: add comment for parseFlagEnsAPI and fix a mistake in comment in codeJanos Guljas2017-12-051-1/+3
| |
* | swarm: multiple --ens-api flagsJanos Guljas2017-12-042-20/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow multiple --ens-api flags to be specified with value format [tld:][contract-addr@]url. Backward compatibility with only one --ens-api flag and --ens-addr flag is preserved and conflict cases are handled: - multiple --ens-api with --ens-addr returns an error - single --ens-api with contract address and --ens-addr with different contract address returns an error Previously implemented --ens-endpoint is removed. Its functionality is replaced with multiple --ens-api flags.
* | swarm: add CLI --ens-endpoint flag (#14386)Janos Guljas2017-12-012-54/+190
|/ | | | | Implement a CLI flag that can be repeated to allow multiple ENS resolvers for different TLDs.
* cmd/geth, cmd/swarm: sort commands and flags by name (#3462)Maximilian Meister2017-08-111-0/+2
|
* swarm/api: make api.NewManifest synchronous (#14880)Lewis Marshall2017-07-312-2/+1
| | | | | Previously, NewManifest was asynchronous so subsequent code which tried to use the returned manifest could error as the manifest was not yet persisted.
* cmd/swarm: support exporting, importing chunk db (#14868)Lewis Marshall2017-07-313-41/+172
|
* params: remove redundant consts, disable metro on AllProtocolChangesPéter Szilágyi2017-07-041-2/+2
|
* cmd/swarm: Exit if --ethapi is setLewis Marshall2017-06-302-15/+14
| | | | | | | | The previous attempt to use --ethapi as a fallback if --ens-api is not set does not work because --ens-api has a default value, and also setting --ens-api to "" is the suggested way to disable ENS lookups. Signed-off-by: Lewis Marshall <lewis@lmars.net>
* cmd/swarm: Support using Mainnet for resolving ENS namesLewis Marshall2017-06-261-8/+97
| | | | Signed-off-by: Lewis Marshall <lewis@lmars.net>
* cmd/swarm: disable TestCLISwarmUp because it's flakyFelix Lange2017-06-231-0/+2
|
* swarm/test: add integration test for 'swarm up' (#14353)Lewis Marshall2017-06-212-0/+331
|
* cmd/swarm: fix error handling in 'swarm up' (#14557)Lewis Marshall2017-06-061-13/+22
| | | | | | The error returned by client.Upload was previously being ignored due to becoming out of scope outside the if statement. This has been fixed by instead defining a function which returns the hash and error (rather than trying to set the hash in each branch of the if statement).
* cmd/swarm: Add --httpaddr flag (#14475)Lewis Marshall2017-05-221-0/+8
| | | | | Fixes #14474. Signed-off-by: Lewis Marshall <lewis@lmars.net>
* all: update license informationFelix Lange2017-04-143-10/+10
|
* swarm/api: better name resolver handling (#3754)holisticode2017-04-131-0/+2
| | | Fixes #3608
* cmd/geth: add --config file flag (#13875)Felix Lange2017-04-121-13/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * p2p/discover, p2p/discv5: add marshaling methods to Node * p2p/netutil: make Netlist decodable from TOML * common/math: encode nil HexOrDecimal256 as 0x0 * cmd/geth: add --config file flag * cmd/geth: add missing license header * eth: prettify Config again, fix tests * eth: use gasprice.Config instead of duplicating its fields * eth/gasprice: hide nil default from dumpconfig output * cmd/geth: hide genesis block in dumpconfig output * node: make tests compile * console: fix tests * cmd/geth: make TOML keys look exactly like Go struct fields * p2p: use discovery by default This makes the zero Config slightly more useful. It also fixes package node tests because Node detects reuse of the datadir through the NodeDatabase. * cmd/geth: make ethstats URL settable through config file * cmd/faucet: fix configuration * cmd/geth: dedup attach tests * eth: add comment for DefaultConfig * eth: pass downloader.SyncMode in Config This removes the FastSync, LightSync flags in favour of a more general SyncMode flag. * cmd/utils: remove jitvm flags * cmd/utils: make mutually exclusive flag error prettier It now reads: Fatal: flags --dev, --testnet can't be used at the same time * p2p: fix typo * node: add DefaultConfig, use it for geth * mobile: add missing NoDiscovery option * cmd/utils: drop MakeNode This exposed a couple of places that needed to be updated to use node.DefaultConfig. * node: fix typo * eth: make fast sync the default mode * cmd/utils: remove IPCApiFlag (unused) * node: remove default IPC path Set it in the frontends instead. * cmd/geth: add --syncmode * cmd/utils: make --ipcdisable and --ipcpath mutually exclusive * cmd/utils: don't enable WS, HTTP when setting addr * cmd/utils: fix --identity
* cmd/swarm: add --password (#3748)Victor Farazdagi2017-04-121-6/+18
|
* swarm/api: refactor and improve HTTP API (#3773)Lewis Marshall2017-04-073-71/+77
| | | | | | | This PR deprecates the file related RPC calls in favour of an improved HTTP API. The main aim is to expose a simple to use API which can be consumed by thin clients (e.g. curl and HTML forms) without the need for complex logic (e.g. manipulating prefix trie manifests).
* cmd/swarm: allow uploading from stdin (#3744)Louis Holbrook2017-04-062-6/+39
| | | | | | - intended to be a swarm alternative to termbin.com - added --stdin flag to swarm executable. if set, swarm will read data from stdin and postRaw it.
* cmd/swarm, swarm/api/client: add HTTP API client and 'swarm ls' command (#3742)Lewis Marshall2017-04-054-182/+99
| | | | | | | | This adds a swarm ls command which lists files and directories stored in a manifest. Rather than listing all files, it uses "directory prefixes" in case there are a lot of files in a manifest but you just want to traverse it. This also includes some refactoring to the tests and the introduction of a swarm/api/client package to make things easier to test.
* swarm/api: support mounting manifests via FUSE (#3690)Zahoor Mohamed2017-03-231-1/+1
|
* Logger updates 3 (#3730)Péter Szilágyi2017-03-025-39/+36
| | | | | | | | * accounts, cmd, eth, ethdb: port logs over to new system * ethdb: drop concept of cache distribution between dbs * eth: fix some log nitpicks to make them nicer
* cmd, whisper/mailserver: revert to utils.FatalfPéter Szilágyi2017-02-231-9/+9
|
* all: blidly swap out glog to our log15, logs need reworkPéter Szilágyi2017-02-233-67/+55
|
* cmd/swarm: handle SIGTERM unix signal for clean exitzelig2017-02-131-0/+10
|
* Merge pull request #3592 from karalabe/hw-walletsPéter Szilágyi2017-02-131-7/+15
|\ | | | | accounts: initial support for Ledger hardware wallets
| * accounts, cmd, internal, mobile, node: canonical account URLsPéter Szilágyi2017-02-131-1/+1
| |
| * accounts, cmd, eth, internal, miner, node: wallets and HD APIsPéter Szilágyi2017-02-131-1/+1
| |
| * accounts, cmd, eth, internal, mobile, node: split account backendsPéter Szilágyi2017-02-131-7/+15
| |
* | swarm/network: fix chunk integrity checks (#3665)Viktor Trón2017-02-132-0/+48
|/ | | | | | | | | | * swarm/network: integrity on incoming known chunks * swarm/network: fix integrity check for incoming chunks * swarm/storage: imrpoved integrity checking on chunks * dbstore panics on corrupt chunk entry an prompts user to run cleandb * memstore adds logging for garbage collection * dbstore refactor item delete. correct partial deletes in Get * cmd/swarm: added cleandb subcommand
* cmd/swarm: manifest manipulation commands (#3645)Zahoor Mohamed2017-02-133-0/+423
|
* Merge pull request #3615 from nolash/bzzpathfix_real5Péter Szilágyi2017-01-301-2/+3
|\ | | | | cmd/swarm, swarm/api: bzzr improve + networkid prio
| * cmd/swarm, swarm/api: bzzr improve + networkid prionolash2017-01-271-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fixes #3444 fixes #3494 networkid override Added comments to explain why test against 0 appears twice * Command line overrides saved config, saved config overrides system default --- fixes #3476 bzzr get with path Finally a hopefully clean commit for this PR Added check for empty path to avoid SIGSEGV in path parser and resolver Added requested tests for empty path and non-existing manifest. However signature for StartHTTPServer had changed. Now it's hacked as so: StartHttpServer(api.API, &Server{Addr: "127.0.0.1:8504", CorsString: ""}) * Parse url before resolve when path and ENS is supplied, example * swarm/api/http proxy server test for retrieval of subpath through get * Removed nil entry assignment on subtrie leaf in recursive key retrieval * Cleaned up path-or-no-path condition in proxy server get handler * swarm: processed with gofmt refers to lash/go-ethereum@90daa7a * swarm: Added public access method Parse alias to parse * swarm: processed with gofmt References nolash/go-ethereum@2ec3fd7 * Rename parse to Parse, removed alias
* | cmd/geth, cmd/swarm: Fix to close file handler appropriatelyShintaro Kaneko2017-01-301-0/+1
|/
* cmd/swarm: uploader uses HTTP PUT for directories (#3488)Viktor Trón2017-01-091-26/+56
|
* all: fix spelling errorsPéter Szilágyi2017-01-071-1/+1
|
* all: gofmt -w -sFelix Lange2017-01-061-3/+3
|
* swarm/api/http: add support for CORS headers (#3388)Maran2017-01-051-10/+16
|
* cmd/swarm: testnet bootnodes IP address changezelig2016-12-141-5/+5
|
* cmd/swarm: improve uploader output and add defaultpath optionzelig2016-12-132-22/+68
|
* cmd/swarm: ethapi not requiredzelig2016-12-131-6/+4
|
* cmd/swarm: trim trailing slash from bzzapi urlzelig2016-12-131-1/+1
|
* cmd/swarm: add default bootnodes for testnet 3zelig2016-12-131-6/+13
|
* swarm/network, cmd/swarm: swarm default network id is 3 (to match Ropsten)zelig2016-12-131-1/+1
|
* cmd/swarm: subsume cmd/bzz* as subcommands under swarmzelig2016-12-133-0/+535
cmd/swarm: subsume cmd/bzz* under cmd/swarm as subcommands