Commit Graph

42 Commits

Author SHA1 Message Date
Giovanni Petrantoni b99d2039a8
Gossip one one (#240)
* allow multiple codecs per protocol (without breaking things)

* add 1.1 protocol to gossip

* explicit peering part 1

* explicit peering part 2

* explicit peering part 3

* PeerInfo and ControlPrune protocols

* fix encodePrune

* validated always, even explicit peers

* prune by score (score is stub still)

* add a way to pass parameters to gossip

* standard setup fixes

* take into account explicit direct peers in publish

* add floodPublish logic

* small fixes, publish still half broken

* make sure to waitsub in sparse test

* use var semantics to optimize table access

* wip... lvalues don't work properly sadly...

* big publish refactor, replenish and balance

* fix internal tests

* use g.peers for fanout (todo: don't include flood peers)

* exclude non gossip from fanout

* internal test fixes

* fix flood tests

* fix test's trypublish

* test interop fixes

* make sure to not remove peers from gossip table

* restore old replenishFanout

* cleanups

* restore utility module import

* restore trace vs debug in gossip

* improve fanout replenish behavior further

* triage publish nil peers (issue is on master too but just hidden behind a if/in)

* getGossipPeers fixes

* remove topics from pubsubpeer (was unused)

* simplify rebalanceMesh (following spec) and make it finally reach D_high

* better diagnostics

* merge new pubsubpeer, copy 1.1 to new module

* fix up merge

* conditional enable gossip11 module

* add back topics in peers, re-enable flood publish

* add more heartbeat locking to prevent races

* actually lock the heartbeat

* minor fixes

* with sugar

* merge 1.0

* remove assertion in publish

* fix multistream 1.1 multi proto

* Fix merge oops

* wip

* fix gossip 11 upstream

* gossipsub11 -> gossipsub

* support interop testing

* tests fixing

* fix directchat build

* control prune updates (pb)

* wip parameters

* gossip internal tests fixes

* parameters wip

* finishup with params

* cleanups/wip

* small sugar

* grafted and pruned procs

* wip updateScores

* wip

* fix logging issue

* pubsubpeer, chronicles explicit override

* fix internal gossip tests

* wip

* tables troubleshooting

* score wip

* score wip

* fixes

* fix test utils generateNodes

* don't delete while iterating in score update

* fix grafted defect

* add a handleConnect in subscribeTopic

* pruning improvements

* wip

* score fixes

* post merge - builds gossip tests

* further merge fixes

* rebalance improvements and opportunistic grafting

* fix test for now

* restore explicit peering

* implement peer exchange graft message

* add an hard cap to PX

* backoff time management

* IWANT cap/budget

* Adaptive gossip dissemination

* outbound mesh quota, internal tests fixing

* oversub prune score based, finish outbound quota

* finishup with score and ihave budget

* use go daemon 0.3.0

* import fixes

* byScore cleanup score sorting

* remove pointless scaling in `/` Duration operator

* revert using libp2p org for daemon

* interop fixes

* fixes and cleanup

* remove heartbeat assertion, minor debug fixes

* logging improvements and cleaning up

* (to revert) add some traces

* add explicit topic to gossip rpcs

* pubsub merge fixes and type fix in switch

* Revert "(to revert) add some traces"

This reverts commit 4663eaab6cc336c81cee50bc54025cf0b7bcbd99.

* cleanup some now irrelevant todo

* shuffle peers anyway as score might be disabled

* add missing shuffle

* old merge fix

* more merge fixes

* debug improvements

* re-enable gossip internal tests

* add gossip10 fallback (dormant but tested)

* split gossipsub internal tests into 1.0 and 1.1

Co-authored-by: Dmitriy Ryajov <dryajov@gmail.com>
2020-09-21 11:16:29 +02:00
Giovanni Petrantoni 4112e04036
Add build_p2pd script directly in this repo (#274) 2020-07-16 16:22:49 +09:00
Giovanni Petrantoni 503a7ec1c5 disable arm64 builds for now (travis) 2020-07-12 11:14:49 +09:00
Giovanni Petrantoni 7852c6dd0f
Noise and eth2/nbc fixes (#226)
* Remove noise padding payload (spec removed it)

* add log scope in secure

* avoid defect array out of range in switch secure when "na"

* improve identify traces

* wip noise fixes

* noise protobuf adjustments (trying)

* add more debugging messages/traces, improve their actual contents

* re-enable ID check in noise

* bump go daemon tag version

* bump go daemon tag version

* enable noise in daemonapi

* interop testing, (both secio and noise will be tested)

* azure cache bump (p2pd)

* CI changes

- Travis: use Go 1.14
- azure-pipelines.yml: big cleanup
- Azure: bump cache keys
- build 64-bit p2pd on 32-bit Windows
- install both Mingw-w64 architectures

* noise logging fixes

* alternate testing between noise and secio

* increase timeout to avoid VM errors in CI (multistream tests)

* refactor heartbeat management in gossipsub

* remove locking within heartbeat

* refactor heartbeat management in gossipsub

* remove locking within heartbeat

Co-authored-by: Ștefan Talpalaru <stefantalpalaru@yahoo.com>
2020-06-20 19:56:55 +09:00
Giovanni Petrantoni 027e8227ea
Add examples to CI (build only for now) (#143) 2020-04-19 14:04:53 +09:00
Ștefan Talpalaru 7723403b1f
debug prints (#132)
* debug prints

* CI: enable stack traces

* Azure: better NimBinaries cache key

* CI changes

- Azure: remove Linux target
- Travis: add ARM64 target

* uglify the code in order to save 12 bytes per LPStream object
2020-04-14 15:21:16 +02:00
Dmitriy Ryajov 293a219dbe
Cleanup (#55)
* fix: don't allow replacing pubkey

* fix: several small improvements

* removing pubkey setter

* improove error handling

* remove the use of Option[T] if not needed

* don't use optional

* fix-ci: temporarily pin p2pd to a working tag

* fix example to comply with latest changes

* bumping p2pd again to a higher version
2019-12-10 14:50:35 -06:00
Ștefan Talpalaru 6c77f99427
CI: always use the go-libp2p-daemon HEAD 2019-08-26 16:40:25 +02:00
Ștefan Talpalaru ead8b4cc38
CI: use build_p2pd.sh for download retries and caching 2019-08-25 15:55:26 +02:00
Ștefan Talpalaru 0df2f05bfc
CI: update script path 2019-08-24 21:31:11 +02:00
Ștefan Talpalaru a0e677c07a
Travis: use Go 1.12 2019-08-15 01:55:25 +02:00
cheatfate dfd824bd03
Fix #22.
Fix wire.initTAddress(MultiAddress).
Add Windows support to daemonapi.
Add CI tests for daemonapi on Windows.
Fix Linux CI tests to install latest daemon.
2019-08-01 08:56:59 +03:00
Ștefan Talpalaru f546a70563
CI: use build_nim.sh 2019-06-13 13:09:12 +02:00
cheatfate 845cbeb0bd
New go-libp2p-daemon building steps. 2019-03-07 01:30:03 +02:00
cheatfate 908b5539ea Force brew to update itself. 2019-01-10 02:56:18 +02:00
cheatfate c08c187e62 Force Travis to install Go from brew. 2019-01-10 02:51:17 +02:00
cheatfate c3d75f9116 Move CI to xenial. 2019-01-10 02:40:32 +02:00
cheatfate f862981986 Temporarily disable MacOS testing because it missing Go 1.11.x. 2019-01-10 02:33:14 +02:00
cheatfate bcce49958f Attempt to fix MacOS CI 3. 2019-01-10 02:13:34 +02:00
cheatfate 06f9376a59 Attempt to fix MacOS CI 2. 2019-01-10 02:01:53 +02:00
cheatfate 8409c0c7bb Attempt to fix MacOS CI. 2019-01-10 01:37:54 +02:00
cheatfate fb8e6701a9 Last fixes. 2018-11-19 06:03:23 +02:00
cheatfate 65e606649c Fix #15. 2018-11-19 05:58:52 +02:00
cheatfate e8d85bc79a Fix #14. 2018-11-19 05:55:24 +02:00
cheatfate b542f4e14c Fix #12. 2018-11-19 05:49:14 +02:00
cheatfate e70c20f8cb Fix #11. 2018-11-19 05:45:09 +02:00
cheatfate 5f1a5030be Reveal more information. 2018-11-19 05:41:38 +02:00
cheatfate c402b26fd9 Fix #10. 2018-11-19 05:38:17 +02:00
cheatfate a93f96ed32 Fix #9. 2018-11-19 05:33:31 +02:00
cheatfate 112a71a881 Fix #8. 2018-11-19 05:26:20 +02:00
cheatfate e9cfffa5fa Enable nimble test. 2018-11-19 05:24:45 +02:00
cheatfate 5c167b231d Fix #7. 2018-11-19 05:00:59 +02:00
cheatfate 1211ffbb5c Add daemon api sources. 2018-11-19 04:52:11 +02:00
cheatfate e7e87763c3 Remove comments. 2018-11-19 04:39:34 +02:00
cheatfate 44abdb94ff Fix #5. 2018-11-19 04:35:32 +02:00
cheatfate 44f1f0af00 Fix #4. 2018-11-19 04:32:40 +02:00
cheatfate ca57d5835b Fix #3 2018-11-19 04:29:47 +02:00
cheatfate 7a4cc911a2 Reveal GO version. 2018-11-19 04:26:36 +02:00
cheatfate ab32bb1264 Fix #2. 2018-11-19 04:23:37 +02:00
cheatfate f5354f09d7 Update GO version. 2018-11-19 04:19:23 +02:00
cheatfate 8bbcf2d061 temporary fix #1 2018-11-19 04:15:45 +02:00
cheatfate b70c8290bf Initialize travis and licenses. 2018-11-19 04:04:47 +02:00