Jeromy Johnson
ab9b736388
Merge pull request #4169 from ipfs/fix/4062
...
add blocks to the blockstore before returning them from blockservice sessions.
2017-08-25 12:07:23 -07:00
Jeromy Johnson
9c0f936210
Merge pull request #4155 from ipfs/fix/reprovider-trigger
...
reprovide: fix ipfs bitswap reprovide when interval set to 0
2017-08-25 11:32:39 -07:00
Steven Allen
b22d3fbfd9
add blocks to the blockstore before returning them from blockservice sessions.
...
fixes #4062 (yay!)
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-08-23 21:02:47 -07:00
Łukasz Magiera
e34a5e9c0d
gx: update go-reuseport
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-23 16:32:32 +02:00
Łukasz Magiera
ffc9abb8b8
reprovide: fix ipfs bitswap reprovide when interval set to 0
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-20 18:23:09 +02:00
Steven Allen
67c572e750
bitswap_test: make racy test less racy
...
fixes #4108
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-08-16 17:23:05 -07:00
Steven Allen
19c3bd82a3
extract update go-testutil
...
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-08-16 17:23:01 -07:00
Łukasz Magiera
4a5b93a1df
reprovider: apply review suggestions
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-16 00:39:12 +02:00
Łukasz Magiera
a865fde21d
reprovider: make reprovide cmd error if reprovider is active
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
0f692baffa
reprovider: reduce pinned strategy i/o overhead
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
7e5e0cba03
reprovider: Fix sharness tests
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
3917d4dd18
reprovider: Make codeclimate happier
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
17ae331be2
reprovider: Implement 'bitswap reprovide' command
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
bb7aee5729
reprovider: Fix build
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Łukasz Magiera
f20683eb53
Reprovider strategies
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-08-13 00:02:23 +02:00
Steven Allen
38a9be5a0a
gx: update go-libp2p-swarm
...
fixes #4102 (fixed in go-libp2p-swarm)
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-07-31 14:04:40 -07:00
Steven Allen
4ef73ee25d
bitswap: serialize connect/disconnect notifications over one channel.
...
Otherwise, we could end up receiving a disconnect notification before a connect
notification (and think we have a connection that we don't have).
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-07-27 18:48:19 -07:00
Steven Allen
28be1d4c58
gx: update deps
...
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-07-27 18:48:16 -07:00
Jeromy
39e9328e47
ensure testnet peers get evenly connected mesh
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-15 22:37:50 -07:00
Jeromy
a93b44b226
Only open a message sender when we have messages to send
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-15 20:18:17 -07:00
Jeromy
cccc6a94a3
update go-multihash and bubble up changes
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-11 19:27:43 -07:00
Jeromy
8be07cabd0
fix closing and removal of sessions
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-11 09:31:20 -07:00
Jakub Sztandera
dd7589bdaf
bitswap: add few method comments
...
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
2017-07-07 20:54:07 +02:00
Jeromy
3be5c913ee
fix issue with sessions not receiving locally added blocks
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-07 11:40:41 -07:00
Jeromy
124afdbaaa
extract bitswap metrics to separate struct for 64bit alignment
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-06 12:17:25 -07:00
Jeromy
eab2024e43
address CR
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-06 12:06:57 -07:00
Jeromy
579fd46488
track broadcasted wantlist entries
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:51:51 -07:00
Jeromy
b1247d3323
WIP: wire sessions up through into FetchGraph
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:48:28 -07:00
Jeromy
b680f49363
fix wantlist removal accounting, add tests
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:47:23 -07:00
Jeromy
e43d1317bb
rework how refcounted wantlists work
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:47:23 -07:00
Jeromy
bda8c3a687
implement bitswap sessions
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:47:22 -07:00
Jeromy
47479b672a
track wantlists sent to peers individually
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-07-05 10:45:31 -07:00
Łukasz Magiera
8ab93aaeb2
Update go-datastore to 1.2.2, go-cid to 0.7.16
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-07-04 20:18:57 +02:00
Łukasz Magiera
4b8a9a3f9f
Update go-datastore to 1.2.1
...
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2017-07-03 20:17:03 +02:00
Steven Allen
520938a9ec
gx import/update libp2p/go-libp2p-routing
...
For some reason, this was referenced but wasn't listed in packages.json.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-06-29 22:12:14 +02:00
Steven Allen
13636bef50
blocks: gx import go-block-format
...
And updated related dependencies.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-06-29 22:12:14 +02:00
Steven Allen
bccd4d4e8f
blocks: move block format to it's own repo
...
We need to reference it from outside of this repo.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2017-06-29 22:12:14 +02:00
zramsay
096b3232d5
address PR comments; remove commented/dead code
...
License: MIT
Signed-off-by: Zach Ramsay <zach.ramsay@gmail.com>
2017-06-01 12:13:04 -04:00
zramsay
c5df8f0796
apply the megacheck tool to improve code quality
...
License: MIT
Signed-off-by: Zach Ramsay <zach.ramsay@gmail.com>
2017-05-31 16:56:11 -04:00
Lars Gierth
64ced367ac
gx: update go-libp2p-peerstore, go-libp2p, go-libp2p-kbucket
...
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
2017-05-30 02:26:05 +02:00
Jeromy
0418930ca8
update to dht code with provide announce option
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-05-23 13:59:36 -07:00
Jeromy
331e60ba34
test for partner removal
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-05-19 19:05:12 -07:00
Jeromy
f53dc7c8b5
bitswap: clean up ledgers when disconnecting
...
License: MIT
Signed-off-by: Jeromy <why@ipfs.io>
2017-05-19 19:01:58 -07:00
dgrisham
4789a622b2
tests: bitswap ledger tests modified
...
Updated the `TestBitswapLedger*` tests and added assertions to check concrete
values for ledgers (rather than just checking that two peers' ledgers match).
The names for these tests were also changed from the previous commit, according
to 's/BytesSent/Ledger/'.
License: MIT
Signed-off-by: David Grisham <dgrisham@mines.edu>
2017-04-25 20:16:37 -06:00
dgrisham
74e19eae62
tests + data dependency fix: BytesSent bug now completely fixed
...
Tests were added to ensure that the bug fix in commit 000fbd25 was correct.
The tests caught an error where a peer's ledger was not properly locked when
updating it in the `MessageSent()` function. The appropriate calls to lock the
ledger were made, and the tests successfully passed.
License: MIT
Signed-off-by: David Grisham <dgrisham@mines.edu>
2017-04-25 20:16:37 -06:00
dgrisham
0514504d09
bug fix: BytesSent in peers' ledgers now updates
...
When sending data to another user, the number of bytes sent to that user (saved
by the corresponding Bitswap ledger) was not updated (it was always 0). This
also meant that the debt ratio was also always 0.
The function that updates the `BytesSent` value in the ledger, `MessageSent()`,
was already implemented, however it was not called when the peer was sent data.
To fix this, a call to `MessageSent()` was made in the `taskWorker()` function,
which is where both the message in question and the Bitswap engine were
available to make the call. `MessageSent()` requires the peer's ID and
`BitSwapMessage` as its arguments, the latter of which had to be created by
making a new `BitSwapMessage`, then the block being sent was added to the new
message.
Note that, similar to the analagous call to `MessageReceived()`, records *all*
of the bytes sent to a particular user. At some point, both of these should be
updated to only record the numbers of *useful* bytes sent and received between
peers.
License: MIT
Signed-off-by: David Grisham <dgrisham@mines.edu>
2017-04-25 20:16:37 -06:00
Jeromy
b15470d548
bubble up updates from go-multihash changes
...
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2017-04-20 20:28:04 +02:00
Andrew Chin
7ebbe495cb
Fix wanlist typo in prometheus metric name
...
This will be a breaking change for anyone who is currently monitoring
the `ipfs_bitswap_wanlist_total` prometheus stat
License: MIT
Signed-off-by: Andrew Chin <achin@eminence32.net>
2017-03-28 23:36:55 -04:00
Hector Sanjuan
3b6216b239
Make Golint happy in the blocks submodule.
...
This has required changing the order of some parameters and
adding HashOnRead to the Blockstore interface (which I have in turn
added to all the wrapper implementations).
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-03-24 16:46:42 +01:00
Jeromy Johnson
cbf8a0cdb4
Merge pull request #3748 from ipfs/deps/update-dht
...
update go-libp2p-kad-dht with getclosestpeers fix
2017-03-06 11:21:38 -08:00