Commit graph

25 commits

Author SHA1 Message Date
nolash
339e3c89a7 swarm, swarm/network, swarm/pss, les: fixed swarm bin + minor adj
removed all Pss in symbol names whereever possible (and sensible)

discovery switch in hive now prevents add of suggested peers
this is probably not a permanent solution

bzz and pss now started from swarm.go,
Outputs from bzz/pss Protocols() and APIs()
are appended to the Swarm methods
2017-06-06 22:20:21 +02:00
Lewis Marshall
da6d15da4c p2p/simulations: Drop adapters.NodeId in favour of discover.NodeID
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-27 16:11:03 +01:00
nolash
d219b0edb0 WIP 2017-05-17 22:45:17 -07:00
zelig
6de0d73449 swarm/network: kademlia health check for discovery test 2017-05-17 22:01:07 -07:00
Lewis Marshall
0534fa4f97 swarm/network: Wake the hive when a peer is registered
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-17 21:56:30 -07:00
Lewis Marshall
0b28cf8544 swarm/network: Remove hive keep alive toggle
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-17 21:56:06 -07:00
zelig
5307e1ea77 swarm/network: Kademlia fixes 2017-05-16 21:17:44 -07:00
zelig
a03781dfb0 swarm/network: refactor, fix kademlia 2017-05-16 20:57:31 -07:00
Lewis Marshall
3ba68dc7af p2p: Change p2p.Server back to a concrete type 2017-05-16 20:57:31 -07:00
Lewis Marshall
91c198778c p2p/protocols: Refactor
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-16 20:57:31 -07:00
zelig
c870e2be26 WIP network rewrite 2017-05-15 18:31:40 -07:00
Lewis Marshall
12eb088e5b p2p/simulations: Refactor
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-06 14:25:00 +01:00
Lewis Marshall
b865560130 swarm/network: Trigger simulations checks on peer events
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-06 14:25:00 +01:00
nolash
b8bf32bce3 swarm/network: pss 0.1
General:
    - Message encapsulation is temporary until integration with whisper

    Incoming message handling:
    - Implements a dispatcher for registering handler functions to pss topics
    - Handlers can be any sort of function, and can send/receive on p2p.MsgReadWriter
    - Actual p2p.Protocol handling now as pluggable convenience function

Sending and routing:
    - Added temporary cache solution based on message hash digest
    - Send and forward split up as separate methods
    - Send is now payload agnostic (p2p.Protocol replies massaged in p2p.MsgWriter)

Tests:
    - TestPssRandom...
	Sends PSS between randomly selected nodes in different population magnitudes
    - TestPssFullLinearEcho
        A->B->C->B->A ping/pong over pss, where A and C are running pss
    - TestPssFullRandom50Pct
        10 nodes where 5 are running pss, 5 sends to/from random nodes
        (messages currently get stuck in kad. routing, discarded by cache block)
    - Protocoltester tests status unknown
2017-05-06 14:25:00 +01:00
Lewis Marshall
24dcc8d6e1 swarm/network: Pass p2p.Server to Hive.Start
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-06 14:25:00 +01:00
Lewis Marshall
4c6648ef49 all: Fix logging
Signed-off-by: Lewis Marshall <lewis@lmars.net>
2017-05-06 14:23:39 +01:00
zelig
b7860c7fc6 kademlia fixes 2017-05-06 14:23:38 +01:00
nolash
140c7f7f23 swarm/network: WIP protocol testfixes 2017-05-06 14:23:38 +01:00
zelig
7f22abaead swarm/network, p2p: fixes 2017-05-06 14:23:38 +01:00
zelig
8cd9adcf38 extending kademlia with bootstrapping, refactor discovery from hive 2017-05-06 14:23:38 +01:00
zelig
7c0a205335 swarm/network: kademlia implementation initial commit 2017-05-06 14:23:38 +01:00
zelig
7a6ff56333 p2p: network testing framework and protocol abstraction
subpackages:

* adapters:
  * msgpipes for simulated test connections
  * rlpx the RLPx adapter for normal non-test use
  * inproc simulated in-process network adapter
  * docker placeholder for docker cluster remote adapter
* protocols: easy-to-setup modular protocols
* simulations:
  * generic network model
  * journal, events, snapshots
  * cytoscape visualisation plugin
  * resourceful controller suite + REST API server
  * example: connectivity UX backend
* testing: test resource drivers
  * exchange: trigger/expect style driver for single node and its peers
  * sessions:   for unit testing protocols and protocol modules
  * (network: for network testing, benchmarking, stats, correctness, fault tolerance)
  * test peerpool

see more in the README-s in each subpackage

* p2p/server : conn/disconn hooks
* reporter remote client skeleton
2017-05-06 14:23:38 +01:00
Péter Szilágyi
d4fd06c3dc
all: blidly swap out glog to our log15, logs need rework 2017-02-23 12:16:44 +02:00
Felix Lange
e46bda5093 swarm/network: prevent relay of invalid IPs 2016-11-22 22:21:18 +01:00
ΞTHΞЯSPHΞЯΞ
4d300e4dec swarm: plan bee for content storage and distribution on web3
This change imports the Swarm protocol codebase. Compared to the 'swarm'
branch, a few mostly cosmetic changes had to be made:

* The various redundant log message prefixes are gone.
* All files now have LGPLv3 license headers.
* Minor code changes were needed to please go vet and make the tests
  pass on Windows.
* Further changes were required to adapt to the go-ethereum develop
  branch and its new Go APIs.

Some code has not (yet) been brought over:

* swarm/cmd/bzzhash: will reappear as cmd/bzzhash later
* swarm/cmd/bzzup.sh: will be reimplemented in cmd/bzzup
* swarm/cmd/makegenesis: will reappear somehow
* swarm/examples/album: will move to a separate repository
* swarm/examples/filemanager: ditto
* swarm/examples/files: will not be merged
* swarm/test/*: will not be merged
* swarm/services/swear: will reappear as contracts/swear when needed
2016-08-31 16:19:40 +02:00