Commit Graph

3278 Commits

Author SHA1 Message Date
Steven Allen
cb57105dfa
Merge pull request #5834 from ipfs/feat/urlstore-pin
add pinning support to the urlstore
2018-12-12 10:39:17 -08:00
Steven Allen
e18328b5fe
Merge pull request #5836 from chenminjian/refact/cmd/cat
refact(cmd/cat): remove useless code
2018-12-11 09:38:51 -08:00
Steven Allen
25a0db4f69 add pinning support to the urlstore
fixes #5833

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-12-10 18:30:14 -08:00
Steven Allen
508f307c35
Merge pull request #5827 from ipfs/gx/update-peer-id
gx: update go-libp2p-peer
2018-12-10 11:57:16 -08:00
chenminjian
1c94a62c48 refact(cmd/cat): remove useless code
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-12-10 19:12:22 +08:00
Overbool
740110e72a block: rm extra output
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-12-07 15:58:03 -08:00
Steven Allen
6cec0b1611 fix ed25519 test(s)
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-12-07 15:51:28 -08:00
Steven Allen
9dcec2b3e2 gx: update go-libp2p-peer
Reverts the changes that allowed small keys (ed25519 keys) to be inlined.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-12-07 15:37:23 -08:00
Łukasz Magiera
c0a1e80f36 p2p: report-peer-id option for listen
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-11-29 20:49:17 -08:00
Steven Allen
2d94a3ffc8
Merge pull request #5526 from cboddy/feat/http_proxy_over_p2p
[http_proxy_over_p2p]
2018-11-29 20:15:32 -08:00
Kevin Atkinson
b1ecb82172 coreapi/pin: Use CID's directly in maps instead of converting to strings.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-11-29 17:13:26 -05:00
Dr Ian Preston
8694984992 Add another test case for invalid p2p http proxy path
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
9956630e0c add more p2p http proxy tests
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Hector Sanjuan
3b2ce4a85d Apply suggestions from code review
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>

Co-Authored-By: ianopolous <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Steven Allen
b720d1f0b5 uses the global PeerHost and don't expose the P2P one
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
47d45c7af8 fix tests
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
fd43f473b4 switch to new path format in p2p http proxy
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
13b0483df0 Don't url decode protocol name. It won't work.
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Chris Boddy
3f6b866edc [http_proxy_over_p2p] url-decode the proxy name and fix test
License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
654105a210 fix test
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Hector Sanjuan
42a843d66b Fix request path. Wasn't using proxy correctly
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-11-28 23:17:27 -08:00
Hector Sanjuan
91c919a47e Fix test
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-11-28 23:17:27 -08:00
Hector Sanjuan
2cc1a99566 Let URL's host take precedence
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-11-28 23:17:27 -08:00
Hector Sanjuan
f03efbd200 Use go-libp2p-http
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
d30c41a5e0 Improve p2p stream closing in http proxy
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
6e24fc609a Use request context in p2p stream http proxy
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
c67d2b4186 Remove unnecessary pointer usage.
Make sure the p2p stream is closed eventually

License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:27 -08:00
Dr Ian Preston
f052d18471 fix non empty paths in p2p http proxy
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:26 -08:00
Chris Boddy
90f5bad718 [http_proxy_over_p2p] proxy async.
Simultaneously send request-body while reading response-body when
proxying requests.

License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:26 -08:00
Chris Boddy
5f246e3211 [http_proxy_over_p2p] httputil.ReverseProxy
Reimplement http-request proxying ala httputil.ReverseProxy.

NB: this is proxies the request synchronously (sends all request-body
before reading any response).

License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:26 -08:00
Chris Boddy
335bca2bb7 [http_proxy_over_p2p] remove now superfluous test
License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:26 -08:00
Dr Ian Preston
22f3b11621 change handler mount point to /proxy/http/
License: MIT
Signed-off-by: Ian Preston <ianopolous@protonmail.com>
2018-11-28 23:17:26 -08:00
Chris Boddy
1945e44f7f [http_proxy_over_p2p] Add sharness tests for http-proxy-over-p2p
License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:26 -08:00
Chris Boddy
c862ac1fb4 [http_proxy_over_p2p] more tests, fix build
License: MIT
Signed-off-by: Chris Boddy <chris@boddy.im>
2018-11-28 23:17:26 -08:00
Kevin Atkinson
feb4808975 Gx update go-merkledag and related deps.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-11-28 17:21:36 -05:00
Overbool
a7485994d7 cmds: rm old lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-27 20:43:41 -08:00
Steven Allen
cef645936d gx: update go-ipfs-config
* AutoRelay options for #5785.
* Badger truncate-by-default option for #5275, #5625.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-26 17:42:13 -08:00
Steven Allen
b7a48531b7
Merge pull request #5611 from ipfs/features/streaming-ls-5600
Add --stream option to `ls` command
2018-11-20 23:42:22 -08:00
hannahhoward
f5ab6a3f5e refactor(commands): cleanup makeDagNodeLinkResults
License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-19 16:46:10 -08:00
Jeromy
da4674f0b9 Switch to using request.Context()
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-11-18 16:11:43 -08:00
hannahhoward
b0dc73c45f fix(commands): Use post-run to remove flag
License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 15:06:54 -08:00
hannahhoward
be4c4abcc2 chore(commands): Mark feature as experimental
License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 14:55:08 -08:00
Łukasz Magiera
7391cfd421 fix(commands): reduce complexity w/ typed encoder
uses single flag to support state needed by PostRun
supports encoding=text

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 14:53:08 -08:00
hannahhoward
20b928094c fix(commands): Add sharness tests for streaming
Also fixes issues discovered with sharness tests

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 14:52:29 -08:00
hannahhoward
5672ae6bbb fix(commands): Refactor to use a PostRun
Removes flags on LSOutput

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 14:51:29 -08:00
hannahhoward
ef6e9cf283 feat(commands): --stream option for ls
Convert LS Command to use current cmds lib
Update LS Command to support streaming
Rebase fixes

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-16 14:30:42 -08:00
hannahhoward
0963c9cdcb Update go-ipfs-delay and assoc deps
License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-15 18:53:45 -08:00
Daniel Mack
45b34e2bcb bootstrap: check for presence of bootstrap nodes earlier
Rather than checking for the presence of bootstrap nodes on each iteration
of the deferred function, do the check at initialization time and report an
error immediately.

License: MIT
Signed-off-by: Daniel Mack <daniel@zonque.org>
2018-11-12 22:45:47 +01:00
Steven Allen
a88cd82a70
Merge pull request #5760 from overbool/refactor/cmds/encoder
cmds: use MakeTypedEncoder
2018-11-10 10:11:26 -08:00
Overbool
f4976e6b4e cmds/bitswap: sort wantlist
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-10 12:19:15 +08:00
Overbool
51fa833fda cmds: use MakeTypedEncoder
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-10 12:11:45 +08:00
Overbool
5002d59d8c cmds/update: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-09 11:14:48 -08:00
Overbool
cd108a0f88 cmds/file: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-09 09:26:52 +08:00
Overbool
57b0c0f792 cmds: remove reduntant func
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-08 15:21:50 +08:00
Steven Allen
98f6b2f684
Merge pull request #5679 from overbool/refactor/commands/refs
commands/refs: use new cmds
2018-11-07 13:57:56 -08:00
Steven Allen
5c15857e33 pin: handle progress in post-run, everything else in the encoder
Otherwise, we break the HTTP API (slightly).

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-07 13:19:15 -08:00
Overbool
62ce03ed14 cmds/pin: use PostRun in pin add
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 13:19:15 -08:00
Overbool
52cd246c04 cmds/pin: use EmitOnce for single value
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 13:19:15 -08:00
Overbool
1e7149cd00 commands/pin: fix gofmt and block
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 13:19:15 -08:00
Overbool
6fc049b59f commands/pin: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 13:19:15 -08:00
Steven Allen
901e9fb955
Merge pull request #5678 from overbool/refactor/commands/bootstrap
commands/boostrap: use new cmds
2018-11-07 11:56:09 -08:00
chenminjian
fcea632b3d fix(cmd/add): progressbar output error when input is read from stdin
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-07 07:52:15 -08:00
Overbool
bc4a9ef7c2 cmds/bootstrap: use EmitOnce directly
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 17:14:56 +08:00
Overbool
bde95077c7 commands/boostrap: use new cmds
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 17:03:34 +08:00
Overbool
bb236cf5ad cmds/refs: use emit directly
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 16:58:36 +08:00
Overbool
30c6dd9bc1 cmds/refs: remove redundant func
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 16:49:16 +08:00
Overbool
bd5be7efc8 commands/refs: drop goroutine
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 15:22:49 +08:00
Overbool
204a53247c commands/refs: use new cmds
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-07 15:22:49 +08:00
Overbool
0afbafdeaf cmds: use w.Write directly
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
2c48466630 commands: use EmitOnce for single object
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
46902e98e2 commands: use io.Writer in tabwriter
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
d26f97a902 fix(cmd/diag): inorder output
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
35959d623b refactor(cmds): use new cmds lib in log
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
27bc0ecc2e refactor(cmds): use new cmds lib in mount
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
b1efb997bf refactor(cmds): use new cmds lib in config
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
b2badfbb06 refactor(cmds): use new cmds lib in diag
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 13:06:11 -08:00
Overbool
b4b6fc6906 cmds/filestore: use PostRun in verify
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 12:56:15 -08:00
Overbool
c43658621d commands/filestore: print StatusOtherError error
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 12:56:15 -08:00
Overbool
2462bf913a commands/filestore: use res.Emit directly
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 12:56:15 -08:00
Overbool
013de54d98 commands/filestore: fix gofmt
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 12:56:15 -08:00
Overbool
dfde39151f commands/filestore: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-06 12:56:15 -08:00
Overbool
73fef489f5 commands/bitswap: use cmds.EmitOnce in single value
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-05 15:55:04 -08:00
Overbool
c5b44ded40 commands/bitswap: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-05 15:55:04 -08:00
Steven Allen
254dda2823
Merge pull request #5677 from chenminjian/refact/cmd/repo
refact(cmd/repo): repo's sub cmds uses new cmd lib
2018-11-05 08:42:49 -08:00
chenminjian
ff27f9f112 refact(cmd/repo): normalize fsck cmd name
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-03 17:12:49 +08:00
chenminjian
5afa7ebfdc refact(cmd/repo): repo verify uses new cmd lib
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-03 17:12:32 +08:00
chenminjian
f7b6ee3c87 refact(cmd/repo): repo fsck and repo version uses new cmd lib
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-03 17:04:44 +08:00
Steven Allen
5c5b03ea31 Revert "Merge pull request #5708 from ipfs/fix/log-ndjson"
This reverts commit f0bf99361e, reversing
changes made to d5c8fa50c8.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-02 21:17:22 -07:00
Steven Allen
0d80fc54c3 gx: update go-log and sha256
fixes #5709

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-02 21:17:20 -07:00
chenminjian
17e7892036 enhance(cmd/verify): add goroutine count to improve verify speed
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-02 13:30:12 -07:00
Steven Allen
ec9fac7379 gx: update go-ipld-cbor
(might as well do this at the same time)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-11-02 13:17:44 -07:00
hannahhoward
943a5de974 Update go-mfs and go-unixfs
So we can get go-unixfs v1.2.0

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-11-02 13:16:56 -07:00
Steven Allen
f659eec3d9
Merge pull request #5719 from chenminjian/fix/cmd/version
fix(flag/version): flag `all` should have a higher priority
2018-11-02 13:13:02 -07:00
Overbool
488db7d2f2 commands/p2p: use cmds.EmitOnce in single value
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 12:06:26 -07:00
Overbool
7292c1da23 commands/p2p: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 12:06:26 -07:00
Overbool
4a2c3cb3cf commands/dht: use res.Emit directly
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:14:14 -07:00
Overbool
7e7a04e21f commands/dht: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:14:14 -07:00
Overbool
e1d1f68f08 commands/object: use cmds.EmitOnce in single value
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:06:32 -07:00
Overbool
0fe7bdfce9 commands/object: add comment
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:06:32 -07:00
Overbool
df58a2d617 commands/object: fix object diff option error
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:06:32 -07:00
Overbool
677c953dc4 commands/object: use new cmds
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 11:06:32 -07:00
Overbool
f37553f065 commands/files: use cmds.EmitOnce in single value
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 09:46:14 -07:00
Overbool
546d3bed5a commands/files: can't get flush option
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 09:46:14 -07:00
Overbool
efa280c531 commands/files: use MakeTypedEncoder
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 09:46:14 -07:00
Overbool
b80589f98e commands/files: use new cmds
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 09:46:14 -07:00
chenminjian
6f219e0d8f fix(flag/version): flag all should have a higher priority
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-11-02 19:30:09 +08:00
Overbool
bf15999c02 cmds/env: add a config path helper
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-11-02 10:10:28 +08:00
Steven Allen
0d56a486c0
Merge pull request #5706 from ipfs/fix/4132
fix prometheus concurrent map write bug
2018-10-31 08:00:57 -07:00
Steven Allen
bf69017e25 metrics: we're now recording latency seconds, not microseconds
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-31 05:12:35 -07:00
Steven Allen
16d70eac32 add a todo to remember to remove log reformatting
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-31 04:53:57 -07:00
Steven Allen
68ac5170f1 re-format log output as ndjson
Apparently, js-ipfs-api expects this. Really, I'm not sure why js-ipfs-api even
cares about this endpoint but that's a different issue.

The real fix is to change back to ndjson in go-log but that would force us to
update every package (not good when we're trying to push out a release like
this).

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 17:26:49 -07:00
Steven Allen
4674f19913 fix prometheus concurrent map write bug
fixes #4132

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 15:38:49 -07:00
Steven Allen
d5c8fa50c8
Merge pull request #5705 from ipfs/fix/resolve-non-terminal
error on resolving non-terminal paths
2018-10-30 13:13:34 -07:00
Steven Allen
126d996f60 resolve: restore error message
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 13:02:55 -07:00
Steven Allen
37f33812ae error on resolving non-terminal paths
This isn't the *correct* fix but it (mostly) restores the previous behavior.

Note 1: It *also* fixes resolution of `/ipld` paths by avoiding `path.FromCid`.
Note 2: This does not preserve the error. That was a DagCBOR specific error that
has nothing to do with the issue.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 12:34:32 -07:00
Steven Allen
d98351720a fix expected error message in gateway test
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 10:36:16 -07:00
Steven Allen
af53380e8c gx: update go-path
fixes the changed path cat error causing the js-ipfs-api tests to fail

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 09:27:41 -07:00
Steven Allen
018265940c
Merge pull request #5626 from ipfs/feat/impoter-batching
Explicitally use BufferedDAG after removing Batch from importers
2018-10-30 09:24:57 -07:00
Steven Allen
e37b252c0c coreapi: fix errisdir
JavaScript expects this to be "this dag node is a directory". I'm almost of a
mind to say "don't parse errors" but, well, we don't give any better
alternatives.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 08:48:49 -07:00
Steven Allen
8543e27e0d
Merge pull request #5699 from ipfs/fix/pin-ls-output
Fix pin ls output when hash is specified
2018-10-30 07:52:19 -07:00
Łukasz Magiera
08d6e7844a fix pin ls output when hash is specified
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-30 15:26:18 +01:00
Steven Allen
3d28165c94
Merge pull request #5698 from ipfs/fix/libp2p-ping
ping: switch to the ping service enabled in the libp2p constructor
2018-10-30 07:22:59 -07:00
Steven Allen
cc0d6d7338 ping: switch to the ping service enabled in the libp2p constructor
We now configure the ping service in go-libp2p by default. Instead of creating a
new (duplicate) ping service, we can now just (a) rely on this to handle
incoming pings and (b) use the "Ping" function to ping peers.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 06:57:41 -07:00
Steven Allen
e332af8ed5 commands: fix a bunch of tiny commands-lib issues
* Always check errors returned by emit. Otherwise, we may not notice when the
  client goes away.
* Make sure to use EmitOnce instead of Emit when appropriate. Otherwise, we
  break javascript.

(thanks Magik6k for finding this before we cut the release...)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-30 06:49:08 -07:00
Steven Allen
f8375ec79c
Merge pull request #5680 from ipfs/fix/cleanup-ping
cleanup the ping command
2018-10-30 06:42:52 -07:00
Hector Sanjuan
8709e55b85 Add batching when Adding.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-10-29 18:49:37 +01:00
Hector Sanjuan
ef7234d269 Bubble deps
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-10-29 18:49:37 +01:00
Steven Allen
5fef0286e0
Merge pull request #5688 from ipfs/gx/update-pubsub
gx: update pubsub
2018-10-29 08:01:48 -07:00
Steven Allen
4227214239 gx: update pubsub
fixes a critical performance issue in the gossipsub pubsub router

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-29 06:34:39 -07:00
chenminjian
78d878e253 fix(cmd/gc): Run func does not return error when Emit func returns error
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-10-29 15:49:14 +08:00
Steven Allen
b8f535567f simplify ping.ParsePeerParam
We now *have* p2p multiaddrs.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-28 05:38:24 -07:00
Steven Allen
b870e8c6d1 cleanup and improve ping
1. Use emit directly.
2. Abort immediately when the context is canceled (no need to wait a second for
the sleep to elapse).
3. Ping once a second instead of once a second +TTL (to be more like ping)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-28 05:38:22 -07:00
Steven Allen
b25c14f2e9
Merge pull request #5675 from overbool/refactor/commands/ping
commands/ping: use new cmds lib
2018-10-27 05:38:25 -07:00
Steven Allen
a0c0355dd5 fix pin-lock in dag put
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-27 05:29:39 -07:00
Steven Allen
b8d7d25569 remove dead code
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-27 05:28:51 -07:00
Steven Allen
64a517afed simplify dag add
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-27 05:28:51 -07:00
Overbool
cec3af28ca commands/ping: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-27 12:37:10 +08:00
Dominic Della Valle
38cae95f30 gx: update go-ipfs-cmds to 2.0.5
License: MIT
Signed-off-by: Dominic Della Valle <ddvpublic@gmail.com>
2018-10-26 19:50:32 -04:00
Steven Allen
96334bb073
Merge pull request #5660 from ipfs/fix/resolve-paths
namesys: properly attach path in name.Resolve
2018-10-26 16:34:54 -07:00
Łukasz Magiera
f4e5625b2f namesys: properly attach path in name.Resolve
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-27 00:10:36 +02:00
Steven Allen
223a0606c1
Merge pull request #5662 from overbool/refactor/commands/dag
cmds/dag: use new cmds lib
2018-10-26 12:53:55 -07:00
Steven Allen
3accb7bebd
Merge pull request #5650 from overbool/refactor/new-cmds-lib
refactor(cmds): use new cmds lib in version, tar and dns
2018-10-26 11:21:22 -07:00
Steven Allen
90d8cff390
Merge pull request #5638 from rcarver/fix/cmds/rm-link
object patch rm-link: change arg from 'link' to 'name'
2018-10-26 11:16:39 -07:00
Overbool
4160eaa637 refactor(cmds): use new cmds lib in tar, dns
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-27 01:48:40 +08:00
Overbool
9611d5f310 refactor(cmds): replace MakeEncoder with MakeTypedEncoder
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-27 01:47:37 +08:00
Overbool
40a1c75759 refactor(cmds): use new cmds lib in version
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-27 01:47:37 +08:00
Overbool
d31e92b446 cmds/dag: use new cmds lib
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-27 01:40:28 +08:00
Steven Allen
37f0fd92c7 gx: update go-ipfs-cmds
(no code changes)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-26 09:26:53 -07:00
Steven Allen
5b26444052 gx: update pubsub (again)
Small patch to mark gossipsub peers as wanted so we don't prune them.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-26 05:57:43 -07:00
Steven Allen
bf1aeaceb9
Merge pull request #5647 from ipfs/feat/pubsub-signing
configurable pubsub signing
2018-10-26 04:13:31 -07:00
Steven Allen
2b0bc7e084 configurable pubsub singing
I'd like to sneak this into the release so we can turn on strict verification
ASAP.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-26 04:00:44 -07:00
Overbool
74e1aaf17c fix(core): ipns config RecordLifetime panic
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-26 07:58:46 +08:00
Steven Allen
00a4b38f61
Merge pull request #5646 from overbool/refactor/commands/id
refactor(commands/id): use new command
2018-10-25 11:26:30 -07:00
Overbool
2fe969a26a refactor(commands/id): use new command
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-26 01:11:11 +08:00
Steven Allen
a561eca7ec remove p2p-circuit addr hack in ipfs swarm peers
We used to have to do this as these addresses had `/ipfs/QmId` appended at
the *transport* layer. However, we were able to remove this with the transport
refactor so we can now remove this check.

fixes https://github.com/libp2p/specs/issues/72

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-25 09:15:52 -07:00
Steven Allen
7ecd6756b4
Merge pull request #5642 from chenminjian/refact/command/root
refact(command): replace option name with const string
2018-10-25 03:45:02 -07:00
chenminjian
2f008d47cd refact(command): replace option name with const string
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-10-25 15:13:18 +08:00
Steven Allen
e35d4ea58b gx: update yamux
(fixes a panic due to a race)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 15:01:31 -07:00
Steven Allen
636bbc7e2b gx update go-libp2p
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 13:39:48 -07:00
Steven Allen
4d956d2ba9 update for changed relay defaults
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 13:39:39 -07:00
Ryan Carver
6aa8525f6e object patch rm-link: change arg from 'link' to 'name'
This improves the semantics of rm-link to be consistent with add-link,
clarifying that you should specify the link name as the thing to remove.

License: MIT
Signed-off-by: Ryan Carver <ryan@ryancarver.com>
2018-10-24 10:09:19 -07:00
Steven Allen
e41ac96207 switch to new raceless routing event interface
fixes #5616

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 10:00:22 -07:00
Steven Allen
c97c3459be gx update
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 09:59:43 -07:00
Steven Allen
efa282d46e update for pubsub rename
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-24 09:42:43 -07:00
chenminjian
64cdabc88f feat: stop apply command exposing private key over HTTP API
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-10-24 05:46:00 -07:00
chenminjian
2e3cbe3e27 feat: add dry-run flag for config profile apply command
License: MIT
Signed-off-by: chenminjian <727180553@qq.com>
2018-10-24 05:46:00 -07:00
Overbool
4e260775b2 docs: add a note for dns command
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-23 13:09:28 +08:00
Steven Allen
caffa59183
Merge pull request #5627 from ipfs/feat/update-webui-2.1.0
update webui to 2.1.0
2018-10-23 00:57:09 +01:00
Łukasz Magiera
519c67a00c coreapi unixfs: gw handler cleanup
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-23 01:14:51 +02:00
Łukasz Magiera
838aeb9b89 coreapi unixfs: docs for getSession, use api.dag
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-23 01:13:35 +02:00
Łukasz Magiera
a4cb06027a coreapi unixfs: use session for resolving too
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-22 23:39:26 +02:00
Łukasz Magiera
faf5230e69 coreapi unixfs: Return seeker from get
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-22 23:38:47 +02:00
Łukasz Magiera
7915d26090 coreapi unixfs: fix Get seeking in gateway
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-22 23:37:45 +02:00
Łukasz Magiera
34b1313d82 coreapi unixfs: remove Cat, use sessions
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-22 23:37:45 +02:00
Steven Allen
c430e53a17 update webui to 2.1.0
This brings us on-par with js-ipfs.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-22 09:22:21 -07:00
Steven Allen
dd4d8bb25e
Merge pull request #5529 from overbool/fix/issue-#5523
fix(p2p): issue #5523
2018-10-18 19:33:44 +01:00
Steven Allen
f6c6327c63
Merge pull request #5612 from overbool/refactor/use-int64
refactor(command): modify int to int64
2018-10-18 19:26:38 +01:00
Steven Allen
def2147c48 update the webui
Because the current one is *so* broken it's not worth waiting for an actual
release.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-18 19:05:11 +01:00
Overbool
ff6f16c939 refactor(command): modify int to int64
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-18 23:44:14 +08:00
Steven Allen
7de79280bb
Merge pull request #5404 from ipfs/feat/namestream
ipfs name resolve --stream
2018-10-18 15:55:16 +01:00
Steven Allen
084c7d1646
Merge pull request #5605 from overbool/feat/add-slash-in-files-ls
fix(files): add slash for dir
2018-10-18 15:53:17 +01:00
Łukasz Magiera
16e6343abe Merge remote-tracking branch 'origin/master' into feat/namestream
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-18 12:26:20 +02:00
Łukasz Magiera
59e5a9c652 gx: update to use extracted go-ipfs-files
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-18 10:16:31 +02:00
Łukasz Magiera
e335fd32f2 namesys: drop prefix args
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-16 16:35:31 +02:00
Overbool
e9d6c060ef fix(files): add slash for dir
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-16 22:15:04 +08:00
Łukasz Magiera
7dbeb27e5b namesys: review fixes
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-16 16:09:55 +02:00
Łukasz Magiera
94bbeffaa9 Merge remote-tracking branch 'origin/master' into feat/namestream
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-15 12:05:03 +02:00
Steven Allen
bf2d7cb2bd fix infinite loop in stats bw
"break" just breaks from the select, this loops infinitely (fast).

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-13 21:22:48 +01:00
Steven Allen
4f53736430 gx: update yamux and refmt
* yamux: fix memory leak.
* refmt: obey the "empty" tag.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-12 16:15:40 +01:00
Steven Allen
8117a2bcee gx: update go-buffer-pool
Turns out that `pool.Put(buf)` had to *allocate* because we needed to turn
`[]byte` into `interface{}`. Apparently, we've never done this correctly we just
never noticed because we never really used buffer pools extensively.

However, since migrating yamux to a buffer-pool backed buffer, this started
showing up in allocation profiles.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-10 14:11:31 +01:00
Łukasz Magiera
0bef4603e8 Merge branch 'master' into feat/namestream
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-10 12:10:12 +02:00
Steven Allen
098933ade4 gx: update stuff
* go-datastore and friends: GetSize
* badger: new release, fewer allocations
* go-mplex: send fewer packets
* go-bitswap: pack multiple blocks in a single message, fewer allocations
* go-buffer-pool: replace the buffer pool from go-msgio
* yamux: fixed data race and uses go-buffer-pool for stream read-buffers to
  reduce memory and allocations.
* go-libp2p-secio: get rid of a hot-spot allocation
* go-libp2p-peerstore: reduced allocations (at the cost of some memory)

More?

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-05 14:48:44 -07:00
Łukasz Magiera
5618fed0d2 coreapi pubsub: better ctx for connectToPubSubPeers
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:51:36 -07:00
Łukasz Magiera
18d5999ebc coreapi pubsub: fix review nits
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:51:36 -07:00
Łukasz Magiera
d6aa9527f2 pubsub cmd: switch to coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:51:36 -07:00
Łukasz Magiera
d3f3afa5de coreapi pubsub: add tests
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:49:36 -07:00
Łukasz Magiera
51bb9d6843 coreapi: implement pubsub api
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:49:36 -07:00
Łukasz Magiera
3d3bedcf41 coreapi: pubsub interface
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:49:36 -07:00
Steven Allen
0fb2020574
Merge pull request #5564 from ipfs/fix/5369
don't use the domain name as a filename in /ipns/a.com
2018-10-05 11:24:51 -07:00
Steven Allen
f498459ad2 gateway_test: comment on platform dependence
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-05 11:24:36 -07:00
Steven Allen
6ff0fe0976
Merge pull request #5562 from kjzz/zkj/offline-test
add offline id test #4978 and refactor command code
2018-10-05 11:20:29 -07:00
Łukasz Magiera
676403be19 Merge remote-tracking branch 'origin/master' into feat/coreapi/unixfs
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-05 11:45:37 +02:00
Overbool
717c0c83a1 fix(p2p): add test for issue #5523
;wq
Signed-off-by: Overbool <overbool.xu@gmail.com>

License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-05 13:30:31 +08:00
Overbool
03ad3b87ff fix(p2p): issue #5523
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-05 13:30:31 +08:00
Steven Allen
afd81fd5dd gateway test: document why .man
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-04 21:42:07 -07:00
Steven Allen
35e8d6fba1 update unixfs inline option comment to give us room to change things
(addressing CR)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-04 21:12:53 -07:00
Kejie Zhang
371bf9310e uodate json option name
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-05 11:23:32 +08:00
Kejie Zhang
3dc0ce7fa1 refactor all command code
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-05 11:21:54 +08:00
Kejie Zhang
51fa159e4a add dns support in p2p forward connect
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-04 18:14:55 -07:00
Kejie Zhang
43d93cb01b refactor p2p command code
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-04 18:13:24 -07:00
Steven Allen
05b3b81743
Merge pull request #5555 from overbool/feat/add-force-flag-for-files-rm
feat(command): add force flag for files rm
2018-10-04 17:52:01 -07:00
Steven Allen
47e7f693eb don't use the domain name as a filename in /ipns/a.com
fixes #5369

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-04 17:12:08 -07:00
Kevin Atkinson
d127f1be98 gx update libp2p/go-buffer-pool
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-04 20:05:26 -04:00
Kevin Atkinson
2e975add22 gx update go-libp2p-peerstore
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-04 20:04:22 -04:00
Lars Gierth
fc2575740e gx: update go-ipfs-config, iptb
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
2018-10-04 20:02:42 -04:00
Kevin Atkinson
686dcdd9a4 Build fixes.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-04 20:02:29 -04:00
Lars Gierth
2c3ed7efb0 gx: update go-datastore, go-libp2p-swarm
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
2018-10-04 19:52:42 -04:00
Łukasz Magiera
58c9de9e63 coreapi name: switch publish/resolve to coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 22:13:51 +02:00
Łukasz Magiera
e8b137f885 coreapi name: add some missing options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 22:11:17 +02:00
Łukasz Magiera
7807f575f1 coreapi key: error on self if ident not loaded
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 22:10:09 +02:00
Łukasz Magiera
4b1f733864 coreapi unixfs: fix inline doc
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 20:39:43 +02:00
Overbool
bd23e7d2ed feat(command): add force flag for files rm
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-10-04 22:41:07 +08:00
Łukasz Magiera
051c33087b coreapi unixfile: simplify RawNode case
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 04:07:22 +02:00
Łukasz Magiera
69eb015b9f ipfs add uses CoreAPI
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 01:57:25 +02:00
Łukasz Magiera
d51ce96f55 coreapi unixfs: filestore opts
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 01:24:57 +02:00
Łukasz Magiera
a81ec29baa coreapi unixfs: progress events
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-04 01:00:26 +02:00
Łukasz Magiera
f9cf84965d coreapi unixfs: stdin-name option
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 23:17:18 +02:00
Łukasz Magiera
3e754d64fb coreapi unixfs: hidden opiton
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 22:49:42 +02:00
Łukasz Magiera
18fec6eb5f coreapi unixfs: wrap option
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 22:30:45 +02:00
Łukasz Magiera
c6f8e7e2a6 coreapi unixfs: test recursive adding
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 22:06:35 +02:00
Łukasz Magiera
8dda69575a coreapi unixfs: unixfs.Get
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 17:24:15 +02:00
Łukasz Magiera
e6bc923425 coreapi unixfs: multi file support in unixfs coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 15:15:28 +02:00
Łukasz Magiera
675106d759 coreapi unixfs: rebase fixes for fileAdder.AddAllAndPin
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
374fb00cc3 coreapi unixfs: separate option to enable inlining
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
9887a05e43 coreapi unixfs: docs on options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
679d60993d coreapi unixfs: cleanup options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
49946c69c4 coreapi unixfs: pin/local/hash-only options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
c056e5a8de coreapi unixfs: Simpler output handling
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
6337e69ff7 coreapi unixfs: layout/chunker options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
041e55d706 coreapi unixfs: options for RawLeaves / Inline
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
06a4218a03 coreapi unixfs: better add tests
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
c68ab5620a coreapi unixfs: cid prefix options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
795d1ea540 coreapi unixfs: use fileAdder directly
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 14:08:15 +02:00
Łukasz Magiera
7b478209b9 coreapi swarm: unify type with other apis
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-03 01:49:55 +02:00
Steven Allen
4f9bde807b
Merge pull request #4803 from ipfs/feat/coreapi/swarm
coreapi: Swarm API
2018-10-02 16:25:45 -07:00
Steven Allen
080b0e1754
Merge pull request #5509 from ipfs/chores/add-sessions-to-ls-command-4908
Add sessions when fetching MerkleDAG in LS
2018-10-02 16:06:41 -07:00
Steven Allen
d8ed9aba7d
Merge pull request #5550 from ipfs/fix/coreapi-pin-lock
take the pinlock when updating pins
2018-10-02 16:05:45 -07:00
Steven Allen
021fc9fb97
Merge pull request #5385 from ipfs/kevina/cid-cmd
Provide new "cid" sub-command.
2018-10-02 15:54:55 -07:00
Steven Allen
bf654ea4f8 defer the pinlock till we actually need it
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-02 15:39:32 -07:00
Steven Allen
ab69f0fb4d take the pinlock when updating pins
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-02 14:36:12 -07:00
Kejie Zhang
dde11416f6 delete useless hash param in adder
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-02 11:33:12 -07:00
Kejie Zhang
1379ee76f3 add pin lock in AddallPin function
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-10-02 11:33:12 -07:00
Łukasz Magiera
1ed555b87f Cleanup instances of manual resolver construction
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-02 18:35:14 +02:00
Łukasz Magiera
b2f6c3e3ed coreapi swarm: missing docs, review
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-10-02 12:31:50 +02:00
Kevin Atkinson
54904a7691 Rename streamResults to streamResult.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:07:32 -04:00
Kevin Atkinson
7edc7de288 Eliminate emit closure, so something with errors on call to emit.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:07:16 -04:00
Kevin Atkinson
c0a873c27f Address code review.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:07:01 -04:00
Kevin Atkinson
f3ea21c821 Reenable Stdin argument reading.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:06:36 -04:00
Kevin Atkinson
599bb7302e Right align numbers in "ipfs cid bases|codecs|hashes" output.
This also avoid using TabWriter as it doesn't support right aligning a
single column and also because its an overkill for this case.

License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:06:20 -04:00
Kevin Atkinson
e5622f628a Stream results for "ipfs cid format".
Note reading input from Stdin is broken.  Only the first result is accepted.

License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:06:02 -04:00
Kevin Atkinson
98e5999761 Factor out boiler plate code for PostRun in "ipfs filestore ls".
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:05:47 -04:00
Kevin Atkinson
30b861bc5a Remove "prefix" format string. Use WithDefault("%s') for `-f- option.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:05:29 -04:00
Kevin Atkinson
57f96019f7 Provide new "cid" sub-command.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-10-01 14:05:27 -04:00
Łukasz Magiera
ea352f62d0 update routing-helpers
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-29 12:43:30 +02:00
Łukasz Magiera
8e4ce426a4 namesys: use routing.SearchValue
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-27 21:31:42 +02:00
Łukasz Magiera
f69cf07444 ipfs name resolve --stream
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-27 21:31:42 +02:00
Łukasz Magiera
6adb15f4fb namesys: async: go vet fixes
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-27 21:31:42 +02:00
Łukasz Magiera
7ff9f09b07 namesys: Implement async methods
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-27 21:31:42 +02:00
Steven Allen
86559e9e04
Merge pull request #5527 from ipfs/feat/pprof-lock
pprof: create HTTP endpoint for setting MutexProfileFraction
2018-09-27 18:49:46 +00:00
Łukasz Magiera
6fa2ab0d41 coreapi swarm: rewire address listing cmds
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:17:23 +02:00
Łukasz Magiera
df9f101892 coreapi swarm: rewire connect/disconnect
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:13:17 +02:00
Łukasz Magiera
30d42f4550 swarm cmd: port to new cmd lib
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:09:14 +02:00
Łukasz Magiera
44bab585a5 coreapi swarm: swarm refactor fixes
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:01:28 +02:00
Łukasz Magiera
e7f493b569 fix infinite loop in connInfo.ID
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:01:28 +02:00
Łukasz Magiera
8358c8d041 coreapi: implement swarm api
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:01:28 +02:00
Łukasz Magiera
1373218519 coreapi: swarm interface
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-26 22:01:28 +02:00
Jakub Sztandera
50fffa2973 pprof: create HTTP endpoint for setting MutexProfileFraction
Allows to dynamically change the MutexProfileFraction to enable and
disable mutex profiling. It should be very useful for detecting
deadlocks, lock contention and general concurrency problems.

How to use:
To enable run: curl -X POST -v 'localhost:5001/debug/pprof-mutex/?fraction=10
To disable: curl -X POST -v 'localhost:5001/debug/pprof-mutex/?fraction=0'

Fraction defines which fraction of events will be profiled. Higher it is
the lower performance impact but less reliable the result.

To fetch the result use:
go tool pprof $PATH_TO_IPFS_BIN http://localhost:5001/debug/pprof/mutex

License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
2018-09-26 21:24:49 +02:00
Overbool
5d173bf365 fix(unixfs): issue #5055
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-26 18:51:00 +08:00
Steven Allen
dac058f8be gx: update go-log go-ipld-cbor
(and friends)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-24 05:36:29 -07:00
Steven Allen
074a1ab48e update for interface changes
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-24 05:24:30 -07:00
Łukasz Magiera
91833e288f gx: update go-libp2p-routing
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-24 14:03:57 +02:00
Steven Allen
ac53d3aaa4
Merge pull request #5494 from rob-deutsch/feat/publishquieter
add quieter option to name publish
2018-09-24 10:11:18 +00:00
rob-deutsch
286d935036 add quieter option to name publish
Added a quieter/Q option to 'name publish' that, consistent with 'add', only outputs the value that was published.

License: MIT
Signed-off-by: Rob Deutsch <rdeutschob@gmail.com>
2018-09-22 09:49:40 +10:00
hannahhoward
47f3c4048d Add sessions to LS command
Uses sessions when fetching MerkleDAG

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2018-09-21 16:12:40 -07:00
Overbool
48c3effac8 fix(unixfs): issue #5217
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-21 15:44:38 +08:00
Steven Allen
d556ee23ef fix resolve command for the new cmds refactor
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-19 14:43:15 -07:00
Steven Allen
b7484c1bca gx: update go-ipfs-cmds to the final release
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-19 14:36:08 -07:00
keks
aa7494b0b7 repo gc: use cmds2
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
caf855b4ec fixes
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
74ec1a9aef address stebalien's comments
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
f4b32e36f4 update cmds to 2.0.0-rc1
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
d14021da98 remove debug output
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
ef21c3bfab update go-ipfs-cmds to 2.0.0-beta2
License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
keks
908ffddc1b big squash commit
excerpt of commit messages:
- update postrun functions in core/commands
- sharness: allow setting -i with TEST_IMMEDIATE=1
- cmds Run func returns error now
- gx update cmdkit to 1.1.2 and cmds to 2.0.0-beta1

License: MIT
Signed-off-by: keks <keks@cryptoscope.co>
2018-09-19 14:35:54 -07:00
Steven Allen
370bd22372
Merge pull request #5484 from ipfs/fix/resolve-hamt
resolve: use unixfs ResolveOnce
2018-09-19 18:41:44 +00:00
Steven Allen
23b44ba3c7
Merge pull request #5485 from schomatis/fix/commands/files-cp-wrap-flush-error
files cp: wrap flush error
2018-09-19 18:39:19 +00:00
Steven Allen
ce8eb134b5
Merge pull request #5466 from ipfs/fix/less-noisy-boostrap-warning
make warnings on no bootstrap peers less noisy
2018-09-19 18:37:41 +00:00
Łukasz Magiera
0fd87de1a4 coreapi name: accept namesys options
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-19 11:51:42 +02:00
Steven Allen
b5bba2ce80
Merge pull request #5486 from kjzz/fix/id
fix offline id bug
2018-09-19 03:01:02 +00:00
Steven Allen
e633eccee4
Merge pull request #5477 from kjzz/fix/publish
error when publishing ipns records without a running daemon
2018-09-19 02:19:31 +00:00
Steven Allen
5676eb530b cmds: improve help/errors for allow-offline
Better explain what's happening and why.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-18 17:27:05 -07:00
Kejie Zhang
53d1251f74 fix offline id bug
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-18 17:57:59 +08:00
Kejie Zhang
9a53494440 update test about publish offline mode
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-18 14:04:56 +08:00
Łukasz Magiera
f915730e68 resolve cmd: use coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-18 05:05:28 +02:00
Łukasz Magiera
1e31aba77b resolve cmd: port to new cmd lib
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-18 02:17:30 +02:00
Lucas Molas
7994689516 files cp: wrap flush error
License: MIT
Signed-off-by: Lucas Molas <schomatis@gmail.com>
2018-09-17 21:14:42 -03:00
Łukasz Magiera
ec96a21db3 resolve: use unixfs ResolveOnce
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-18 01:08:04 +02:00
Łukasz Magiera
53575ddef3 coreapi name: Increase test swarm size
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-17 16:35:39 +02:00
Kejie Zhang
264a9fee64 add allow-offline to judge publish in offline mode
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-17 16:10:18 +08:00
Kejie Zhang
e71ca7c5ad refactor ipns command option name
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-17 15:09:55 +08:00
Steven Allen
224bc0d97f make warnings on no bootstrap peers less noisy
We only need to warn the user if we *can't* connect to the network.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-14 12:10:05 -07:00
Overbool
cbe86a91b4 fix(object): print object diff error
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-14 23:08:22 +08:00
rob-deutsch
b06a0b0e32 fix behaviour of key rename to same name
Renaming a key to the same name always succeeds regardless of force flag. Fixed bug whereby renaming to same name (with --force) would delete the key by accident

fixed #5450

License: MIT
Signed-off-by: Rob Deutsch <rdeutschob@gmail.com>
2018-09-14 15:02:47 +10:00
Steven Allen
cbc6e69ed2
Merge pull request #5457 from overbool/feat/command/add-connection-direction
feat(command): add connection direction
2018-09-14 02:22:16 +00:00
Overbool
daf6fbd347 feat(command): add direction flag for swarm peers command
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-14 08:49:07 +08:00
Steven Allen
2de616300b
Merge pull request #4929 from ipfs/misc/cleanup-p2p
Refactor `ipfs p2p`
2018-09-13 23:57:43 +00:00
Steven Allen
72133283fb
Merge pull request #5399 from kjzz/zkj/feat
add --name new flag when ipfs adding from stdin
2018-09-13 21:44:41 +00:00
Steven Allen
17635c8ee8
Merge pull request #5451 from ipfs/doc/cors
api: fix outdated HTTPHeaders config documentation
2018-09-13 21:34:15 +00:00
Steven Allen
cb589a3446
Merge pull request #5459 from ipfs/fix/5458
fix output of object command
2018-09-13 21:13:27 +00:00
Lars Gierth
9b374c0041 api: fix outdated HTTPHeaders config documentation
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
2018-09-13 23:00:01 +02:00
Steven Allen
93a7b7f756 don't append tabs to object links output
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-13 11:10:29 -07:00
Steven Allen
2a0af78f9d fix output of object command
We're expecting a pointer, not a value. This works in daemon mode but not in
offline mode.

fixes #5458

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-13 10:58:09 -07:00
Overbool
428b82f228 feat(command): add connection direction
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-13 23:22:54 +08:00
Steven Allen
cf963724a7
Merge pull request #5433 from ipfs/test/gateway-options
improve gateway options test
2018-09-12 22:04:03 +00:00
Łukasz Magiera
b53936a706 p2p: Close on Listeners
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-12 23:27:15 +02:00
Steven Allen
54e2cc629a gx: fix hashes
(some extra files got committed)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-11 20:53:24 -07:00
Kevin Atkinson
d3174f4bd9 gx update and fix code to use new Cid type
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-09-11 22:21:04 -04:00
Kejie Zhang
b7ea4bfc2a modify command name and update the test
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-12 05:58:47 +08:00
Kejie Zhang
7de83f25b2 add type assertion checked
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-12 05:54:54 +08:00
Steven Allen
a2ceb1f070
Merge pull request #5445 from kjzz/fix/bootstrap
add warning when no bootstrap in config
2018-09-11 19:14:58 +00:00
Łukasz Magiera
0b575bc0c5 p2p: rebase import updates
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:58:39 +02:00
Łukasz Magiera
228a71aef2 p2p: deduplicate some listeners logic
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
c5090508a8 p2p: fix connmgr use
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
dd48b8237a p2p: separate listener types
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
35eaa1664c p2p: rebase updates
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
4badcdc340 p2p: tag connections in connection manager
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
8849193de0 p2p: more locks
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
3c6a168d16 p2p: fix imports after rebase
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
5e8725dbde p2p: test to ensure closing right linsters
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
a3c84e20ef p2p: refactor review
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
f5ab137fc0 p2p: split forward into 2 commands
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
eb45436512 p2p: allow-custom-protocol option
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
c19102816f p2p: change the required prefix to /x/
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
df6decd31c p2p: don't automatically prefix proto with /p2p
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
830ed48703 p2p: refactor first review
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
3e0184bdad p2p: fix codeclimate warnings
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
0465079f35 p2p: fix ci
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
e8ba4fc01a p2p: fix sharness tests after refactor
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
df6540e014 p2p: rework stream/listener registration
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
067154f22f p2p: p2p ls
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
2487c99a7f p2p: refactor local/remote
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
48d83be052 p2p: implement forward cmd
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
132d6fae4a p2p: Only use reset on streams
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
8b7bf26664 p2p: add peer address to peerstore if specified
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
a0ad8cfd5c p2p: Optimize registry, move stream stuff around
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:40 +02:00
Łukasz Magiera
a037ae6c93 p2p: cleanup listening logic, make dial act like ssh -L
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-11 04:57:29 +02:00
Kejie Zhang
2280d6692c modify log level and update note
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-11 10:00:24 +08:00
Łukasz Magiera
86f9eb73c3 coreapi: dht: remove option prefix
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:40:07 -07:00
Steven Allen
7139b83666 switch to StreamingSet in cidutil
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-10 17:40:07 -07:00
Łukasz Magiera
db646d044d coreapi: dht: make tests less falky
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:38:56 -07:00
Łukasz Magiera
4b252a200f coreapi: dht: use shared set in provideKeysRec
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:38:56 -07:00
Łukasz Magiera
e1bdf6cd28 move streaming set to thirdparty
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:38:56 -07:00
Łukasz Magiera
9fe843f156 coreapi dht: add a note on name change
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:37:31 -07:00
Łukasz Magiera
77ceb7546b coreapi: dht: refactor options after rebase
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:37:30 -07:00
Łukasz Magiera
906c747064 coreapi: dht: simplify the implementation
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:37:30 -07:00
Łukasz Magiera
bda76a1874 coreapi: update dht imports after rebase
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:36:00 -07:00
Łukasz Magiera
6cc86c11e8 coreapi: dht tests
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:36:00 -07:00
Łukasz Magiera
d2e6a61d1e coreapi: test using mock swarm
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:36:00 -07:00
Łukasz Magiera
36168542c9 coreapi: implement dht api
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:33:55 -07:00
Łukasz Magiera
a63e224e24 coreapi: dht interface
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-09-10 17:33:55 -07:00
Steven Allen
82204d1de3
Merge pull request #5331 from ipfs/refactor/coreapi/block
block cmd: Use coreapi
2018-09-11 00:29:55 +00:00
Kejie Zhang
c2bb1ad796 add warning when no bootstrap in config
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-10 20:20:21 +08:00
Overbool
a26228a73f fix(commands): goroutine leaks in ping.go
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-09 19:08:42 +08:00
Steven Allen
a1419a4961 fix peerstore constructor calls
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-07 23:48:49 -07:00
Steven Allen
a6e617f55c gx: update peerstore
Also:

* Updates go-floodsub to fix a data race.
* Updates golang-lru

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-07 23:40:08 -07:00
Overbool
725eefaeb0 fix(commands): fix filestore.go goroutine leak
License: MIT
Signed-off-by: Overbool <overbool.xu@gmail.com>
2018-09-07 23:12:50 +08:00
Steven Allen
573bada803
Merge pull request #5427 from kjzz/fix-goroutine
fix goroutine leaks in filestore.go
2018-09-07 00:54:51 +00:00
Steven Allen
eabd6a0ad4 improve gateway options test
Unfortunately, this doesn't really test the *actual* gateway config as it uses
the options specified by the test. However, it's a step in the right direction.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-09-06 11:00:17 -07:00
Kejie Zhang
7a9c7b4dd3 fix goroutine leaks in filestore.go
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-05 21:57:45 +08:00
Kejie Zhang
0f4e84def4 use fileinfo.abs to judge the file stdin
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-05 21:55:39 +08:00
Kejie Zhang
dad9bdd6f4 remove ErrObejctTooLarge error
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-05 17:50:28 +08:00
Kejie Zhang
b61dae36f3 use file fullpath to judge file name
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-05 14:54:03 +08:00
Kejie Zhang
47c4dcb2b0 object:refactor data encode error
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-05 14:16:35 +08:00
Kejie Zhang
19e3c127ee drop wrap check and modify parameter name
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-09-03 11:02:27 +08:00
Steven Allen
7b835e908d
Merge pull request #5417 from ipfs/fix/transports
fix two transport related bugs
2018-09-01 18:24:57 +00:00
Steven Allen
3bc47d36fc disable the default listen addrs
We explicitly setup listeners but we do this *after* constructing the node.

fixes #5387

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-31 14:55:22 -07:00
Steven Allen
4294a5fb11 explicitly enable the default transports
Otherwise, enabling the QUIC transport will disable the default ones

fixes #5416

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-31 14:54:56 -07:00
Steven Allen
59805f03c3
Merge pull request #5414 from ipfs/nit/no-caching-nil-repo
don't bother caching if we're using a nil repo
2018-08-31 21:06:43 +00:00
Steven Allen
5bc843e5c8 don't bother caching if we're using a nil repo
(it'll be wrong anyways)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-31 12:21:30 -07:00
Steven Allen
46a1d9d39b gx update deps
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-31 10:29:26 -07:00
Kejie Zhang
514891d54a add --name new flag when ipfs adding from stdin
License: MIT
Signed-off-by: Kejie Zhang <601172892@qq.com>
2018-08-31 20:03:00 +08:00
Marten Seemann
481d19e303 add QUIC support
License: MIT
Signed-off-by: Marten Seemann <martenseemann@gmail.com>
2018-08-29 08:58:40 +07:00
Marten Seemann
1c57b1d287 update go-ipfs-config to version 0.2.5
License: MIT
Signed-off-by: Marten Seemann <martenseemann@gmail.com>
2018-08-29 08:58:40 +07:00
Steven Allen
2362c6d3d8
Merge pull request #5166 from schomatis/fix/commands/ls-error-unixfs
core/commands/ls: wrap `NewDirectoryFromNode` error
2018-08-28 20:46:07 +00:00
Steven Allen
db45c4d0d9 remove bitswap unwant
This command messes with internal state and doesn't even work at the moment. If
you don't want a block, you should cancel the request that's trying to fetch it.

fixes #5295

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-28 10:21:10 -07:00
Łukasz Magiera
1f98f4b99c coreapi: block: move option logic to options package
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-27 16:42:37 -07:00
Łukasz Magiera
9b925e0e65 coreapi: block: don't allow creation of invalid cidv0s
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-27 16:41:24 -07:00
Łukasz Magiera
c3e69073e5 block cmd: go-path update
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-27 16:41:24 -07:00
Łukasz Magiera
daae93ad89 block cmd: use coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-27 16:41:24 -07:00
Hector Sanjuan
ceb37a346d Feat: depth limited refs -r
This adds --max-depth to the "refs" commands and allows limiting
the fetching of refs per depth. Other than that, it works as before.

Note that clever branch pruning is only made when the --unique flag
is passed. Otherwise, we re-explore branches to the given depth.

This means that --unique costs memory, but may save time when
the DAGs contain the same sub-DAGs in several places (specially if
they are big). On the other side, not using --unique saves
memory but may involve re-exploring large sub-DAGs.

License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-08-27 20:34:52 +02:00
Steven Allen
93c4f19169
Merge pull request #5281 from ipfs/kevina/inline-cids
Add support for inlinling via the id-hash
2018-08-24 22:09:49 +00:00
Kevin Atkinson
7e3265a16d Change "--inline-limit" default to 32.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-24 16:06:54 -04:00
Steven Allen
0be1f5f755
Merge pull request #5359 from achingbrain/allow-files-write-to-create-parent-directories
Allow mfs files.write command to create parent directories
2018-08-23 03:34:22 +00:00
Kevin Atkinson
b0f90e3e84 Address code review.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-22 21:41:25 -04:00
Steven Allen
faf7aac940 cmds: go fmt and minor cleanup
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-22 09:49:18 -07:00
Łukasz Magiera
b0c480acf5 name cmd: move subcommands to subdirectory
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-22 10:34:44 +02:00
Kevin Atkinson
08c96ba073 Add support for inlining via the id-hash to the add command.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-21 21:56:49 -04:00
Steven Allen
656d7cc1a6 gx: update go-cid, go-libp2p-peer, go-ipfs-cmds, go-ipfs-cmdkit
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-21 17:39:56 -07:00
Steven Allen
fcc96a3ae7
Merge pull request #4177 from Voker57/feat/gw-filename-option
Set filename in Content-Disposition if filename=x is passed in URI query
2018-08-21 16:49:53 +00:00
Hector Sanjuan
39a87a0fb0 Extract /mfs
The /mfs module has been extracted to github.com/ipfs/go-mfs

All history has been retained in the new repository. README, LICENSE,
Makefiles and CI integration have been added to the new location.

License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-08-20 15:28:14 +02:00
Steven Allen
3d1802fe64
Merge pull request #5345 from ipfs/fix/5335
return a json object from config show
2018-08-15 18:47:12 +00:00
vyzo
8a7a26169d instantiate pubsub router based on configuration
in particular, this enabls gossipsub when configured so.

License: MIT
Signed-off-by: vyzo <vyzo@hackzen.org>
2018-08-15 10:02:32 -07:00
vyzo
e002de9571 update go-ipfs-config
License: MIT
Signed-off-by: vyzo <vyzo@hackzen.org>
2018-08-15 10:02:32 -07:00
Steven Allen
2450ddde81 gx: update go-cid
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-15 08:30:22 -07:00
Hector Sanjuan
de72087df3 Fix some weird code in core/coreunix/add.go
Code was just weird. I think it looks better now.

License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-08-14 13:15:53 +02:00
achingbrain
c97c44e8a4 Allow mfs files.write command to create parent directories
Adds support for a `-p/--parents` flag to the `files.write` command
similar to the one supported by the `files.mkdir` command. If this
is true and the directory for the file is not `"/"`, try to create
the containing directory before writing to the file.

License: MIT
Signed-off-by: Alex Potsides <alex@achingbrain.net>
2018-08-14 07:59:36 +01:00
Steven Allen
79e7d5e542 update go-datastore to use []byte values instead of {}interface values
* Most of our datastores barf on non []byte values.
* We have to have a bunch of "is this a []byte" checks.
* Saves some allocations.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-13 14:42:55 -07:00
Kevin Atkinson
fda3d88245 Rename prefix to CidBuilder in names when a cid.Builder is used.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-12 20:49:49 -04:00
Kevin Atkinson
075ecb09d0 Gx updates and fixes to use new cid.Builder interface.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-12 19:15:07 -04:00
Steven Allen
f0769366f1 update cmdkit to fix the progress bar
The progressbar should now correctly calculate the size of a directory (by
ignoring the directory sizes).

fixes #5288

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-10 17:21:28 -07:00
Łukasz Magiera
838a30cd22 gx: Update config
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-09 12:39:55 +02:00
Łukasz Magiera
ffc74391d5 move version.go to top level package
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-09 11:01:10 +02:00
Łukasz Magiera
d52091fa55 Update iptb
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-09 10:57:31 +02:00
Łukasz Magiera
b65cf84a34 repo: move version.go back here
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-09 10:51:15 +02:00
Łukasz Magiera
6fcd205e20 Update imports to point to go-ipfs-config
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-09 10:37:07 +02:00
Steven Allen
594d95af5d update gogo-protobuf
fixes #3214

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-08 18:56:13 -07:00
Steven Allen
92099a2ed1
Merge pull request #5348 from ipfs/feat/update-blockstore-path
gx: update blockstore and path
2018-08-08 17:11:05 +00:00
Whyrusleeping
324615da58
Merge pull request #5285 from ipfs/kevina/cidv0v1
Add ability to retrieve blocks even if given using a different CID version
2018-08-07 21:19:30 -07:00
Whyrusleeping
8aef43d572
Merge pull request #5339 from ipfs/refactor/coreapi/key
key cmd: Refactor to use coreapi
2018-08-07 16:03:35 -07:00
Steven Allen
88a38e667a modifications for ResolveToLastNode changes
see: https://github.com/ipfs/go-path/pull/1

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-07 10:03:03 -07:00
Steven Allen
3e13277dd4 gx: update deps
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-07 10:02:59 -07:00
Łukasz Magiera
640be715dc key cmd: fix codeclimate warnings
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-07 15:12:41 +02:00
Łukasz Magiera
9c6959cf2c key cmd: fix force option handling in rename
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-07 14:00:07 +02:00
Whyrusleeping
b0d9dfc48a
Merge pull request #5340 from ipfs/feat/coreapi/dagbatch
coreapi: dag: Batching interface
2018-08-06 19:14:40 -07:00
Kevin Atkinson
e7ca9554d0 Add ability to retrieve blocks even if given using a different CID version.
This is done via a wrapper blockstore.

License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-08-06 22:12:40 -04:00
Łukasz Magiera
3a68d6395a key cmd: refactor to use coreapi
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-06 22:41:23 +02:00
Łukasz Magiera
c616b7ce20 coreapi: key: some changes to match command functionality
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-06 22:41:06 +02:00
Steven Allen
6d67f89232 return a json object from config show
This doesn't change there CLI output, it just means that the server responds
with a JSON output by default.

fixes #5335

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-08-06 13:32:26 -07:00
Jeromy
042a9729a2 Update bitswap deps
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-08-05 13:22:51 -07:00
Whyrusleeping
ba3f8fc6e9
Merge pull request #5329 from grokcoder/fix/dht_findprovs_error
fix: dht findprovs unable to handle /ipfs/hash #5311
2018-08-05 10:56:55 -07:00
Łukasz Magiera
d6ee9555d0 coreapi: dag: Missing batch docs
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-03 18:34:30 +02:00
Łukasz Magiera
9f22058d95 coreapi: dag: Batching interface tests
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-03 18:12:47 +02:00
Łukasz Magiera
dfd4f94bf6 coreapi: dag: Batching interface
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-03 18:06:57 +02:00
Steven Allen
00c422f676
Merge pull request #5322 from ipfs/fix/shutdown-error
wait for all connections to close before exiting on shutdown.
2018-08-02 21:43:20 +00:00
Xiaoyi Wang
664d881b89 fix: dht findprovs unable to handle /ipfs/hash
License: MIT
Signed-off-by: Xiaoyi Wang <wangxiaoyi@hyperchain.cn>
2018-08-02 11:24:15 +08:00
Łukasz Magiera
60039f27ba object coreapi: Address review
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-01 13:37:05 +02:00
Łukasz Magiera
36c6fb3530 commands: switch object commands to CoreAPI
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-01 13:37:05 +02:00
Łukasz Magiera
432ab62127 coreapi: implement Object.Diff
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-01 13:36:11 +02:00
Łukasz Magiera
7ac229e286 coreapi: Pin option for Object.Put
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-08-01 13:36:11 +02:00
Steven Allen
00158c4b92 wait for all connections to close before exiting on shutdown.
Using httpServer.Shutdown will:

1. Close the listener (preventing new connections).
2. Close each connection as outstanding requests finish.

This prevent us from shutting down before outstanding requests get a chance to
respond.

fixes #4055

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-31 13:07:19 -07:00
Steven Allen
8bcf6f48d9 upgrade shutdown command to the new commands lib
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-31 13:03:36 -07:00
Jeromy
b96a7a0579 extract go-unixfs (importers and unixfs)
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-30 14:54:26 -07:00
Steven Allen
5ca0302bbe flush pins in the pin update command
fixes #5264

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-30 00:13:05 -07:00
Steven Allen
82e006ead1 correctly handle the output of pin update
fixes #4999

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-30 00:13:05 -07:00
Jeromy
ede2caba46 Extract path and resolver
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-28 23:57:42 -07:00
Jeromy
28fdee7fce Extract dagservice, move dagutils to top level
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-28 14:22:20 -07:00
Jeromy
e78911ce94 move dagutils package to top level in preparation for merkledag extraction
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-28 00:50:17 -07:00
Jeromy
0a3a3c9ba7 Extract blockservice and verifcid
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-27 18:21:06 -07:00
Jeromy
39c5c47c94 Extract bitswap to go-bitswap
License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
2018-07-27 14:52:56 -07:00
Steven Allen
53235242a1 gx update deps
Updates:

* go-net
* go-text
* dns
* prometheus
* protobuf (golang, not gogo)

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-23 11:49:43 -07:00
Kevin Atkinson
c8613b4300 Add initial support for identity hashes.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-19 18:09:52 -04:00
Whyrusleeping
1dede1b1d7
Merge pull request #5219 from schomatis/fix/mfs/remove-sort
mfs: remove `sort` from `ListNames()`
2018-07-19 14:29:11 -05:00
Whyrusleeping
256ad27099
Merge pull request #5218 from schomatis/fix/cmds-files-cp/err-msg
commands/files: add error messages for `cp` paths
2018-07-18 12:19:06 -05:00
Whyrusleeping
454a170032
Merge pull request #5245 from ipfs/fix/5241
add trickle-dag support to the urlstore
2018-07-18 10:39:10 -05:00
Łukasz Magiera
4d5a96b0d6 coreapi: path rebase
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 09:00:50 +02:00
Łukasz Magiera
7adf1cb40d coreapi: move path utils to interface
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:44:54 +02:00
Łukasz Magiera
082498de6d coreapi: more docs for ResolvedPath
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
0adb69a773 coreapi: fix TestGatewayGet after rebase
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
0f6bd2d173 coreapi: fix resolved path root for some paths
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
e227fc3865 coreapi: fix ipns path resolving
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
d5b5e0d7ac coreapi: add more docs for path
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
1d23bbeb0f coreapi: path review
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
9b288560a4 coreapi: path remainders
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
7ee6194352 coreapi: path.Mutable
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
f5f44ab246 coreapi: remove ctx from ParsePath, split ParseCid
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
15f8fc60c0 coreapi: separate path into two types
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:43:48 +02:00
Łukasz Magiera
4f6c0666ea coreapi: move path impl to path.go
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:42:06 +02:00
Łukasz Magiera
338e90e9c8 coreapi: expand public path api
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
2018-07-17 08:40:48 +02:00
Steven Allen
9a9979b193 update go-cid
alternative to #5243 that updates go-cid and all packages that depend on it

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-16 15:16:49 -07:00
Steven Allen
19caad2301 add trickle-dag support to the urlstore
fixes #5241

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-16 15:04:23 -07:00
Steven Allen
89e1d9fd49 switch urlstore to the new commands lib
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-16 12:47:15 -07:00
Whyrusleeping
bda81cd2d4
Merge pull request #5045 from schomatis/fix/cmd/files-ls-file-long
cmd: fix `files ls` to report hash and size for files
2018-07-16 16:52:13 +02:00
Whyrusleeping
07feeec9c4
Merge pull request #5010 from ipfs/feat/diskusage2
Efficient "repo stat" (DiskUsage) and "--size-only" flag
2018-07-16 16:50:41 +02:00
Whyrusleeping
4f1391f477
Merge pull request #5139 from achingbrain/feat/specify-object-data-encoding
feat: Allow specifing how object data is encoded
2018-07-16 16:49:31 +02:00
Whyrusleeping
51607243c2
Merge pull request #5170 from schomatis/feat/mfs/root-val-as-dir
mfs: make `Root` value a `Directory`
2018-07-16 16:48:06 +02:00
Lucas Molas
dfb81abf80 commands: files ls: sort output
Imitate Unix `ls` command, sort by default; disable with `-U` flag.

License: MIT
Signed-off-by: Lucas Molas <schomatis@gmail.com>
2018-07-16 09:58:55 -03:00
Kevin Atkinson
1f29699d90 Address c.r. and additional tweaks.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:52 -04:00
Kevin Atkinson
8dd970b73a filestore: Return consistent err msg. when file/urlstore is not enabled.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:52 -04:00
Kevin Atkinson
6a4b1262a5 Make sure you can't add URL's unless the url store is enabled.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:52 -04:00
Kevin Atkinson
ed2bb81b8d Code cleanups to make code climate happy.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:52 -04:00
Kevin Atkinson
0e24444280 Add some documentation to ipfs urlstore add command.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:52 -04:00
Kevin Atkinson
b53a1b3022 Add config option to enable urlstore.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:51 -04:00
Kevin Atkinson
696a0f039e Simplify code: use prefix instead of flag to determine if a url
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:07:51 -04:00
Kevin Atkinson
d59a6e99a6 Fix "ipfs urlstore add" output.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
2018-07-13 09:04:22 -04:00
Jakub Sztandera
1a835202b2 filestore: add URLStore
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
2018-07-13 09:04:22 -04:00
Lucas Molas
4334ddeb35 commands/files: add error messages for cp paths
License: MIT
Signed-off-by: Lucas Molas <schomatis@gmail.com>
2018-07-12 10:55:48 -03:00
Lucas Molas
ec61606378 core/commands/ls: wrap NewDirectoryFromNode error
License: MIT
Signed-off-by: Lucas Molas <schomatis@gmail.com>
2018-07-09 12:37:42 -03:00
Steven Allen
8a9aa41542
Merge pull request #5202 from ipfs/fix/dnslink-recursion-alt
correctly handle multi-hop dnslink resolution
2018-07-09 09:01:32 +00:00
Steven Allen
7df7d11199 fix dht commands when pubsub routing is enabled
Instead of checking if Routing is a DHT (because it can now be a tiered
router and still contain a DHT), stash the DHT in a separate field in the IPFS
node (same as we do with the PSRouter).

fixes #5197

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-07-09 09:58:44 +02:00
Hector Sanjuan
9c8d994c76 remove debug print statement
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2018-07-08 13:01:54 +02:00