1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-09-10 09:52:20 +08:00

98 Commits

Author SHA1 Message Date
0e8a6700f9 correct go-log dep
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-30 09:34:10 -08:00
0e312f5caf initial vendoring of libp2p outside of the repo with gx
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-30 09:34:06 -08:00
8fa53f81e6 slight cleanup
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-12 08:22:55 -08:00
1efbc79223 use mfs for adds
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-12 08:22:55 -08:00
d8ee7dffc3 improves memory usage of add
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-12 08:22:55 -08:00
dc3b9ed140 address concerns from PR
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-12 08:21:13 -08:00
b9e5cfaa15 merkledag FetchGraph and EnumerateChildren
This commit improves (fixes) the FetchGraph call for recursively
fetching every descendant node of a given merkledag node. This operation
should be the simplest way of ensuring that you have replicated a dag
locally.

This commit also implements a method in the merkledag package called
EnumerateChildren, this method is used to get a set of the keys of every
descendant node of the given node. All keys found are noted in the
passed in KeySet, which may in the future be implemented on disk to
avoid excessive memory consumption.

License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2016-01-12 08:21:13 -08:00
94bdce63a7 vendor logging lib update
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-11-05 15:57:21 -08:00
c023d187b5 update code to use new logging changes
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-10-27 11:04:56 -07:00
8f0623255d replace imports with absolute path instead of using symlink
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-10-03 14:30:50 -07:00
e5a2896c0e extract logging
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-09-14 17:35:50 -07:00
b3aee2872f move mem-dag construction to its own function, and actually call WriteOutputTo
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-09-05 04:56:55 +02:00
rht
de5c0ceff0 Localize the scope of context.WithCancel for every DAG.Get
Instead put it inside of DAG.Get.
The fix is applied only in the case when the context.WithCancel
before a DAG.Get is also used later on in the scope.

License: MIT
Signed-off-by: rht <rhtbot@gmail.com>
2015-08-23 22:38:04 +07:00
137c0ac4ac use batching transaction interface from datastore
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2015-07-09 16:37:30 -07:00
ef294431d4 move util.Key into its own package under blocks 2015-06-01 16:10:08 -07:00
rht
ac7edddb94 Run 'gofmt -s -w' on these files 2015-05-19 06:11:15 +07:00
0a6b880bee fix for #1008 and other pinning fixes
This commit adds a new set of sharness tests for pinning, and addresses
bugs that were pointed out by said tests.

test/sharness: added more pinning tests

Pinning is currently broken. See issue #1051. This commit introduces
a few more pinning tests. These are by no means exhaustive, but
definitely surface the present problems going on. I believe these
tests are correct, but not sure. Pushing them as failing so that
pinning is fixed in this PR.

make pinning and merkledag.Get take contexts

improve 'add' commands usage of pinning

FIXUP: fix 'pin lists look good'

ipfs-pin-stat simple script to help check pinning

This is a simple shell script to help check pinning.

We ought to strive towards making adding commands this easy.
The http api is great and powerful, but our setup right now
gets in the way. Perhaps we can clean up that area.

updated t0081-repo-pinning

- fixed a couple bugs with the tests
- made it a bit clearer (still a lot going on)
- the remaining tests are correct and highlight a problem with
  pinning. Namely, that recursive pinning is buggy. At least:
  towards the end of the test, $HASH_DIR4 and $HASH_FILE4 should
  be pinned indirectly, but they're not. And thus get gc-ed out.
  There may be other problems too.

cc @whyrusleeping

fix grep params for context deadline check

fix bugs in pin and pin tests

check for block local before checking recursive pin
2015-04-19 23:40:25 -07:00
bf22aeec0a Reorged imports from jbenet/go-ipfs to ipfs/go-ipfs
- Modified Godeps/Godeps.json by hand
- [TEST] Updated welcome docs hash to sharness
- [TEST] Updated contact doc
- [TEST] disabled breaking test (t0080-repo refs local)
2015-03-31 12:52:25 -07:00
13c489eca1 fix context respect through fuse reading 2015-03-24 12:23:01 -07:00
1d5b903611 added cancel func calls previously ignored 2015-03-07 09:31:46 -08:00
92d08db7a5 rewrote import paths of go.net/context to use golang.org/x/context
- updated go-ctxgroup and goprocess
ctxgroup: AddChildGroup was changed to AddChild. Used in two files:
- p2p/net/mock/mock_net.go
- routing/dht/dht.go

- updated context from hg repo to git
prev. commit in hg was ad01a6fcc8a19d3a4478c836895ffe883bd2ceab. (context: make parentCancelCtx iterative)
represents commit 84f8955a887232b6308d79c68b8db44f64df455c in git repo

- updated context to master (b6fdb7d8a4ccefede406f8fe0f017fb58265054c)

Aaron Jacobs (2):
net/context: Don't accept a context in the DoSomethingSlow example.
context: Be clear that users must cancel the result of WithCancel.

Andrew Gerrand (1):
go.net: use golang.org/x/... import paths

Bryan C. Mills (1):
net/context: Don't leak goroutines in Done example.

Damien Neil (1):
context: fix removal of cancelled timer contexts from parent

David Symonds (2):
context: Fix WithValue example code.
net: add import comments.

Sameer Ajmani (1):
context: fix TestAllocs to account for ints in interfaces
2015-02-25 11:58:19 +01:00
b04b23e675 hotfix: duplicate blocks werent being counted properly, deduped key list before requesting 2015-02-19 08:42:28 +00:00
a29c0fc751 move blocking calls out of single threaded loops, cancel contexts ASAP 2015-02-19 06:04:39 +00:00
58f39687cf logs: removed all log.Errors unhelpful to users
Let's save log.Error for things the user can take action on.
Moved all our diagnostics to log.Debug. We can ideally reduce them
even further.
2015-02-03 01:06:07 -08:00
e959626029 comment NodeGetter 2015-01-27 03:29:10 +00:00
ba4ea139b9 address concerns from PR 2015-01-27 01:33:09 +00:00
0023cb3097 refactor and clean up dagreader 2015-01-27 01:33:09 +00:00
26826bd55e implement seeking in the dagreader 2015-01-27 01:33:09 +00:00
f63d45ca56 merkledag: split off node.go 2015-01-07 02:15:53 -08:00
13e79a05e5 merkledag: add NodeStat object 2015-01-07 02:13:44 -08:00
cd65ec614b merkledag: keep links sorted by name
May not be necessary to sort when adding each link--
doing so would be unnecessarily expensive O(n^2) when
constructing nodes -- though n wont be big.
2015-01-06 13:12:22 -08:00
e3cf893616 implement recursive indirect blocks
improve efficiency of multilayered indirect blocks

clean up tests

panic cleanup

clean up logic, improve readability

add final root node to the dagservice upon creation

importer: simplified dag generation

test: updated hashes using latest code

@whyrusleeping this is why the sharness tests
were failing: the hashes are added manually to
make sure our generation doesn't change.

cleanup after CR

fix merkledag tests

fix small block generation (no subblocks!)
2015-01-06 19:43:56 +00:00
bb8886f3af merkledag: LONG timeout on Get
we shouldn't use an arbitrary timeout here. since Get
doesnt take in a context yet, we give a large upper bound.
think of an http request. we want it to go on as long as
the client requests it.
2015-01-05 00:16:53 -08:00
b19a931d2f remote low SnR debug statement
cc @jbenet @whyrusleeping

License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-23 08:56:07 -08:00
2240272d85 change Provide RPC to not wait for an ACK, improves performance of 'Add' operations 2014-12-17 23:44:41 -08:00
7b0a68031d cleanup from CR 2014-12-15 05:35:53 +00:00
d54c6eb46b fix FindLinks comment 2014-12-15 05:35:53 +00:00
5b0be85b6b change FindLink to FindLinks
cc @maybebtc
2014-12-15 05:35:52 +00:00
930e0cc728 Update merkledag.go 2014-12-15 05:35:52 +00:00
9420200a4e fix(merkle) use defer 2014-12-15 05:35:52 +00:00
e720a6a11c style(merkle): move var dec closer to use 2014-12-15 05:35:52 +00:00
79efd424d1 fix bug where a file containing duplicate blocks would fail to be read properly 2014-12-15 05:35:52 +00:00
3a6b6c6974 cleanup, use a workgroup over channels 2014-12-05 20:53:32 +00:00
f0a4fdad59 some bitswap cleanup 2014-12-05 20:53:32 +00:00
4cc1780705 fix issues in merkledag 2014-12-05 20:53:31 +00:00
9120d107c3 a little more correctness on the new bitswap impl 2014-12-05 20:53:27 +00:00
15d4f82945 some cleanup, and fix minor bug in dagreader from previous commit 2014-12-05 20:53:26 +00:00
d53deebada wire GetBlocks into blockservice 2014-12-05 20:53:26 +00:00
0ce6071fea revamp BatchFetch a bit 2014-12-05 20:53:25 +00:00
b1b42a5609 change BatchFetch to return indices 2014-12-05 20:53:23 +00:00