Brian Tiger Chow
e9d3c9828c
perform multiaddr conversion in the function
2015-01-24 01:32:27 -08:00
Jeromy
b287422ebd
fix type in findProviders command
2015-01-24 08:59:34 +00:00
Brian Tiger Chow
6fedf259eb
remove prefix logger
2015-01-24 00:30:56 -08:00
Jeromy
20c40c3f10
fix commands interface
2015-01-24 08:06:57 +00:00
Juan Batiz-Benet
4334f6fda3
Merge pull request #613 from jbenet/progress-bars
...
Progress Bars
2015-01-23 22:20:34 -08:00
Juan Batiz-Benet
b279da2918
Merge pull request #626 from jbenet/query-cmd
...
dht query command
2015-01-23 22:01:48 -08:00
Jeromy
d68efad06c
respect verbose option a bit, and show query events for other commands
2015-01-24 05:32:50 +00:00
Jeromy
4607f54254
add findpeer command
2015-01-24 03:56:46 +00:00
Jeromy
56a5e72760
implement dht findprovs and add error output to dht query
2015-01-24 03:56:46 +00:00
Jeromy
528eb5a55a
use a notification type strategy for the query events
2015-01-24 03:56:45 +00:00
Jeromy
ec5276c29c
really ugly impl of 'ipfs dht query' command
2015-01-24 03:56:45 +00:00
Matt Bell
ccaabbc06d
core/commands: Rearranged command list sections
2015-01-23 19:17:09 -08:00
Matt Bell
452f54a48e
core/commands: Enabled stdin arguments for 'bootstrap {add, rm}
2015-01-23 19:11:56 -08:00
Matt Bell
71301d2c63
core/commands: Updated root command helptext
2015-01-23 19:11:56 -08:00
Matt Bell
5706471897
commands: Made PostRun signature match Run
2015-01-23 18:29:31 -08:00
Matt Bell
79741438d9
core/commands: config: Simplified some syntax
2015-01-23 18:29:31 -08:00
Matt Bell
3fc9bedb0b
commands: Made Std{in|out|err} accessible in Request/Response
2015-01-23 18:29:31 -08:00
Matt Bell
b77d1c21b6
core/commands: add: Don't show progress bar when using --quiet option
2015-01-23 18:29:31 -08:00
Matt Bell
121dfb10b4
core/commands: Fixed progress bar line clear race condition in 'add'
2015-01-23 18:29:31 -08:00
Matt Bell
2363cb63e6
core/commands: Fixed 'add' progress bar sometimes not clearing progress bar output line
2015-01-23 18:29:31 -08:00
Matt Bell
c3ea164f64
core/commands: Added progress bars for 'add'
...
squash! core/commands: Added progress bars for 'add'
Use vendored progress bar lib in 'add'
2015-01-23 18:29:30 -08:00
Matt Bell
487ef33e67
core/commands: Added progress bar to 'cat'
...
squash! core/commands: Added progress bar to 'cat'
Vendored progress bar lib
2015-01-23 18:29:30 -08:00
Matt Bell
7b4de230eb
commands: Refactored Command#Run function signature to (req Request, res Response)
2015-01-23 18:29:29 -08:00
Juan Batiz-Benet
c4f9a92e55
Merge pull request #628 from jbenet/feat/more-bootstraps
...
Add Bootstrap Peers: Mercury, Earth, Venus, Jupiter
2015-01-23 17:08:56 -08:00
Juan Batiz-Benet
bb2d81ace2
Merge pull request #622 from jbenet/webui-commands
...
Webui Commands
2015-01-23 16:51:11 -08:00
Brian Tiger Chow
bbc282bfab
more bootstrap nodes
2015-01-23 16:19:50 -08:00
Matt Bell
68b2a3f15c
core/commands: Renamed 'log read' to 'log tail'
2015-01-23 15:08:20 -08:00
Juan Batiz-Benet
95d58b2a4a
core: cleaned up bootstrap process
2015-01-23 05:25:31 -08:00
Juan Batiz-Benet
dd9c1b6243
core/bootstrap: CR comments
2015-01-23 02:08:30 -08:00
Juan Batiz-Benet
d6ce837d72
core/bootstrap: cleaned up bootstrapping
...
Moved it to its own package to isolate scope.
2015-01-23 02:08:29 -08:00
Juan Batiz-Benet
010cedf0a9
ipfs swarm peers: sort output
2015-01-23 02:08:29 -08:00
Juan Batiz-Benet
ec848c486b
core: call dht bootstrap
2015-01-23 02:08:28 -08:00
Juan Batiz-Benet
898b9696ca
diag/net: add timeout param to cmd
2015-01-23 02:08:28 -08:00
Juan Batiz-Benet
82d38a2692
routing/dht: periodic bootstrapping #572
2015-01-23 02:08:28 -08:00
Jeromy
eb6afd3edc
fix interface for coreunix.Cat, now takes a path
2015-01-23 06:39:20 +00:00
Matt Bell
81d17e0843
cmd/ipfs: gatewayHandler: Fixed directory listing getting appended to index.html pages
2015-01-22 16:29:00 -08:00
Matt Bell
926b96463d
core/commands: Added 'log read' command
...
squash! core/commands: Added 'log read' command
core/commands: Use a unidirectional channel for 'log read' output
2015-01-22 16:28:59 -08:00
Matt Bell
8d412e48cf
core/commands: Added an 'ipfs config replace' command
2015-01-22 16:28:59 -08:00
Brian Tiger Chow
fadede6cb2
separate concerns
2015-01-22 01:28:40 -08:00
Brian Tiger Chow
fadedf9e68
refactor(core) extract corehttp package
...
PACKAGE DOCUMENTATION
package corehttp
FUNCTIONS
func GatewayOption(n *core.IpfsNode, mux *http.ServeMux) error
func ListenAndServe(n *core.IpfsNode, addr ma.Multiaddr, options
...ServeOption) error
func WebUIOption(n *core.IpfsNode, mux *http.ServeMux) error
TYPES
type ServeOption func(*core.IpfsNode, *http.ServeMux) error
func DaemonOption(cctx commands.Context) ServeOption
2015-01-22 01:08:59 -08:00
Juan Batiz-Benet
f6111d82fe
Merge pull request #558 from jbenet/feat/gc
...
initial implementation of repo-gc command
2015-01-21 16:48:28 -08:00
Jeromy
8e7d984751
updates from PR, tests tests tests!
2015-01-21 08:55:50 +00:00
Brian Tiger Chow
721ff57263
fix(blockservice) fully async exchange.HasBlock
2015-01-20 23:43:21 -08:00
Jeromy
4de881a185
move GC code into core/repo, and add sharness test
2015-01-21 04:28:02 +00:00
Matt Bell
31ae178078
commands: Support outputting <-chan interface{}
2015-01-21 04:28:02 +00:00
Jeromy
9adcfe7bc2
address concerns from PR
2015-01-21 04:28:02 +00:00
Jeromy
ccb36277dd
fix pinning UX, and add tests to match
2015-01-21 04:28:01 +00:00
Jeromy
b91db68056
update pinning to new semantics, and fix a couple bugs
2015-01-21 04:28:01 +00:00
Jeromy
3601a93d17
fix pin command output
2015-01-21 04:28:01 +00:00
Jeromy
f0781d8119
initial implementation of repo-gc command
2015-01-21 04:28:01 +00:00
Juan Batiz-Benet
56ae2fd0a8
routing: record validation into record/
...
This commit moves the record validation/verification
from dht/ into the new record/ packaage. Validator object
-- which is merely a map of ValidatorFuncs -- with a
VerifyRecord
cc @whyrusleeping
2015-01-19 08:10:37 +00:00
Jeromy
a5233faeae
some comments
2015-01-19 08:06:51 +00:00
Jeromy
feeada0d90
fix fuse mounting issues
...
this time, without loading the private key on every startup
2015-01-19 08:05:52 +00:00
Brian Tiger Chow
797aad9137
refactor(core) extract const
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
b0596cd4ff
rename coreio to coreunix
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
a025fc9adf
refactor(core) switch style to type assertions
...
@jbenet cool with this?
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
c1ff2149f1
doc(core) add TODO
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
15a6237ffc
fix(core) improve documentation and describe behavior of function
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
19c2c6556f
fix(core) don't assume Repo won't be nil
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
de45277883
doc(core, main)
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
1edc5c0a65
refactor(core) Close in teardown
...
This declarative style is simpler to compose than the imperative wiring
up of objects.
+ pass context to StartOnlineServices as parameter. one by one, trying
to remove dependencies on node state so these initialization steps can
be broken down.
2015-01-18 14:41:43 -08:00
Brian Tiger Chow
ffe6f9a949
doc(core_io/Add)
...
@jbenet wasn't sure about the terminology here. I'm certain what I wrote
is not entirely correct. Feel free to edit.
2015-01-18 14:41:42 -08:00
Brian Tiger Chow
3dd68ba5c5
fix(core_io/Add): by default, use pinner
...
@whyrusleeping @jbenet does passing this argument effectively instruct
the dagbuilder to pin recursively?
2015-01-18 14:41:42 -08:00
Brian Tiger Chow
4b5ff960c9
feat(core): use repo.Repo in core constructor
2015-01-18 14:41:42 -08:00
Brian Tiger Chow
884143bf9c
move generic packages to thirdparty (see thirdparty/README.md)
2015-01-18 14:04:45 -08:00
Juan Batiz-Benet
132add2ffd
core/mount: make non-darwin archs see fuseversion
...
See the note:
// this file is only here to prevent go src tools (like godep) from
// thinking fuseversion is not a required package by non-darwin archs.
2015-01-18 12:38:18 -08:00
Juan Batiz-Benet
2963f48f62
Merge pull request #554 from jbenet/feat/reprovide
...
basic reprovider implementation
2015-01-17 03:03:01 -08:00
Juan Batiz-Benet
00b099c71f
core/cmds: fix go-fuse-version path
2015-01-17 02:45:17 -08:00
Jeromy
acfc35212e
add backoff retry to reprovider
2015-01-17 04:31:50 +00:00
Jeromy
a7650b259d
add test for reprovider and slight refactor
2015-01-14 22:14:52 +00:00
Juan Batiz-Benet
01283b92f7
Merge pull request #556 from jbenet/net-diag-viewer
...
diag/net: visualizing in d3 and dot
2015-01-14 10:32:56 -08:00
Brian Tiger Chow
40e41d24f7
feat(fsrepo): protect with a repo lockfile
...
NB: daemon is one spot the repo lock is typically acquired
2015-01-14 03:02:23 -08:00
Juan Batiz-Benet
b8757d18ef
diag/net: visualizing in d3 and dot
...
Try it out:
```
ipfs net diag --vis=d3 | diagnostics/d3/d3view
```
Notes: this is not the best way to do it, because it
breaks `--encoding=json`. Not sure what the best way is, and
right now this provides more utility than the other.
2015-01-13 23:49:35 -08:00
Juan Batiz-Benet
920ddc7fc3
Merge pull request #553 from jbenet/serial-file
...
Serial File Opening
2015-01-13 23:30:08 -08:00
Matt Bell
86bb8ca7a7
core/commands: Enabled stdin for various command arguments
2015-01-13 22:51:11 -08:00
Matt Bell
70adc21d08
core/commands: Enable stdin arguments for 'add' and 'cat', resolves #542
2015-01-13 22:51:10 -08:00
Matt Bell
7a579bbf79
commands: Moved files code into 'commands/files' subpackage
2015-01-13 22:50:53 -08:00
Juan Batiz-Benet
f068c89147
reprovide: move core's reprovider into online services
2015-01-13 22:12:37 -08:00
Jeromy
3269986e42
basic reprovider implementation
...
make vendor
2015-01-13 22:12:37 -08:00
Brian Tiger Chow
3eafb3e5ab
style(repo): repo.Interface -> repo.Repo
...
The pkg.Interface style is modeled after heap.Interface. Generally, I
find it helpful for interfaces that have many implementations. It
provides clear distinction between the generic interface and the |n|
implementations that implement it (which may be interface types
themselves).
For clients who cannot keep the repo name, one can imagine that the most
likely rename is `ipfsrepo`. In that case, `ipfsrepo.Interface` remains
meaningful.
This is low-pri so it doesn't matter than much. But for the record, the
repo.Interface feels appropriate in this use-case.
2015-01-13 03:09:33 -08:00
Brian Tiger Chow
86258face6
refactor(config, repo): use repo.Interface to (Get|Set)ConfigKey
2015-01-13 03:09:32 -08:00
Brian Tiger Chow
1b700864f9
refactor(repo): all config writes must go through repo
2015-01-13 03:09:31 -08:00
Brian Tiger Chow
405afd2a02
refactor(config, repo): all writes go through FSRepo. next: privatize these
2015-01-13 03:09:31 -08:00
Brian Tiger Chow
e28a235f77
it's unclear what this test case is meant to protect, but passing an empty datastore value no longer has bearing on node construction. Datastore setup now occurs in repo.
2015-01-13 03:09:31 -08:00
Brian Tiger Chow
6e730f4c73
bad datastore type won't cause failure
2015-01-13 03:09:31 -08:00
Brian Tiger Chow
20e1610075
nil will no longer be a valid argument
2015-01-13 03:09:31 -08:00
Brian Tiger Chow
5b3164de5c
refactor(repo/config) move config under repo
2015-01-13 03:09:30 -08:00
Juan Batiz-Benet
7aa4a83f2e
addr: proper filter + subtract
2015-01-12 20:49:06 -08:00
Juan Batiz-Benet
ceadfbe791
core: some logging for addresses
2015-01-12 19:15:02 -08:00
Juan Batiz-Benet
0cb0f27b68
bootstrap: print error when failed
2015-01-12 19:15:02 -08:00
Juan Batiz-Benet
7ec1a674e3
p2p/net/swarm: do not usre link local addrs
2015-01-12 19:15:02 -08:00
Jeromy
a768e841bc
update printout for net diag
2015-01-12 02:55:15 -08:00
Juan Batiz-Benet
7867e01c90
ipfs ping wording
2015-01-11 20:52:34 -08:00
Juan Batiz-Benet
f7941e9841
ping: use context
2015-01-11 20:52:34 -08:00
Juan Batiz-Benet
374a75b612
refs: tie the contexts together
2015-01-11 20:52:33 -08:00
Juan Batiz-Benet
92e8a7bcd5
updated datastore for proper query handling
...
Queries now can be cancelled and the resources collected
2015-01-11 20:52:33 -08:00
Juan Batiz-Benet
708e47fcbc
ipfs blocks local command
...
ipfs blocks local returns _all_ local refs. For now this is one
long op. future commits will make it async.
2015-01-11 16:59:22 -08:00
Brian Tiger Chow
63c0d41614
fix(core): perform sophisticated boostrap operation
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
033e33dadf
feat(core): expose IpfsNode.Resolve
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
223ee4df1a
refactor(core): move Add, Cat to core/io
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
ddf14bee78
refactor(core): replace online bool with mode type
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
130532c532
rm errTODO
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
b0f7143250
refactor(core): distinguish repo.Repo components
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
9d438843bd
refactor(core): distinguish Online services
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
ca8190a889
refactor(core): isolate complex DHT initialization
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
eb6c40d5dd
refactor(core): isolate the complex initialization of PeerHost construction
2015-01-11 01:23:27 -08:00
Brian Tiger Chow
8e42e86d87
hack(core): instantiate peerstore at the end if it hasn't already been instantiated
...
this is a dirty hack
2015-01-11 01:23:26 -08:00
Brian Tiger Chow
707874c3a5
refactor(core): init node.Blocks in shared NewIPFSNode constructor
2015-01-11 01:23:26 -08:00
Brian Tiger Chow
34e8f3ee26
refactor(core): init DAG and its dependents in shared constructor
...
fix: remove merkledag import
may need to squash this commit into the merkledag move commit
2015-01-11 01:23:26 -08:00
Brian Tiger Chow
7fa5d81093
refactor(core): rename
2015-01-11 01:23:26 -08:00
Brian Tiger Chow
efb75ee5ba
refactor: move add and cat to the core
2015-01-11 01:23:25 -08:00
Brian Tiger Chow
2c3fb43350
feat: expose IpfsNode.Bootstrap() method
2015-01-11 01:23:25 -08:00
Brian Tiger Chow
4c2eda2123
refactor: remove deprecated function
2015-01-11 01:23:25 -08:00
Brian Tiger Chow
57b3ffa533
feat: new core constructor + config options (Standard, Online, Offline)
2015-01-11 01:23:25 -08:00
Juan Batiz-Benet
456719ede7
Merge pull request #523 from jbenet/feat/ping
...
Implement ipfs ping
2015-01-10 08:11:03 -08:00
Juan Batiz-Benet
1bd69b19ac
core: make sure to call swarm.FilterAddrs
...
also move network setup into its own self-contained func
2015-01-10 08:07:19 -08:00
Juan Batiz-Benet
538550f8f8
fix osx mounting version checks
2015-01-10 01:07:43 -08:00
Jeromy
0f4f91c2f3
restore ability to ping by ID alone
2015-01-10 08:31:17 +00:00
Jeromy
1561291d61
improve UI of ping
2015-01-10 07:27:49 +00:00
Jeromy
9fc0f86a3a
cleanup from PR
2015-01-10 07:27:49 +00:00
Jeromy
50c8561bdd
add peer info after FindPeer RPC
...
fix ping test
2015-01-10 07:27:49 +00:00
Jeromy
566a86f5d4
Address PR comments and add in more user feedback
2015-01-10 07:27:48 +00:00
Jeromy
0794d5b46a
a little cleanup
2015-01-10 07:27:48 +00:00
Brian Tiger Chow
069966d55a
ping WIP
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
Conflicts:
core/commands/root.go
begin ping command, WIP
finish initial ping implementation
2015-01-10 07:27:45 +00:00
Juan Batiz-Benet
d1bff333a5
refs: log writer error
2015-01-07 13:49:13 -08:00
Juan Batiz-Benet
180b9b32d3
refs: added --format option
2015-01-07 13:42:06 -08:00
Juan Batiz-Benet
f46120b194
refs edges + stream fix
2015-01-07 12:56:14 -08:00
Juan Batiz-Benet
8307572777
ipfs block stat bugfix: cast
2015-01-07 06:26:34 -08:00
Juan Batiz-Benet
6b2795338f
ipfs object has learned stat
...
'ipfs object stat' is a plumbing command to print DAG
node statistics. <key> is a base58 encoded multihash.
It outputs to stdout:
NumLinks int number of links in link table
BlockSize int size of the raw, encoded data
LinksSize int size of the links segment
DataSize int size of the data segment
CumulativeSize int cumulative size of object and references
2015-01-07 02:31:29 -08:00
Juan Batiz-Benet
07b923d7a4
ipfs block stat cmd
2015-01-07 00:55:27 -08:00
Matt Bell
6236ef7fdb
core/commands: Made add command output a channel
...
core/commands: Don't use pointers for Type field
2015-01-06 15:55:16 -08:00
Matt Bell
abd390b892
core/commands: Made add command show streamed output
2015-01-06 15:53:48 -08:00
Matt Bell
fd40702f73
commands: Changed Marshaler to return a io.Reader instead of a []byte
...
core/commands: Refactored command marshalers
2015-01-06 15:53:42 -08:00
Juan Batiz-Benet
0395a7af1e
ipfs add output not sorted, cmds files sorted
...
I made the commands lib dir listing sort the contents
so we get the same sequence of files from it repeatably.
2015-01-06 14:02:49 -08:00
Christian Couder
d490a85706
Make sure ipfs add output is sorted by name
...
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2015-01-06 13:12:22 -08:00
Juan Batiz-Benet
64bf493b54
swarm peers print pid.Pretty
2015-01-06 10:13:49 -08:00
Juan Batiz-Benet
fbba7c8f39
bootstrap: only dht bootstrap with live conns
2015-01-06 10:10:20 -08:00
Juan Batiz-Benet
9e67acf51a
bootstrap add --default option
2015-01-06 04:30:06 -08:00
Juan Batiz-Benet
517d3e99b8
bootstrap addrs: moved parsing around
...
this commit:
* moves parsing of bootstrap peers into config
* moves location of bootstrap addrs into core/commands
* refactor `*BootstrapPeer -> BootstrapPeer
2015-01-06 00:25:17 -08:00
Juan Batiz-Benet
6eb32aef35
bootstrap err: info
2015-01-05 09:00:58 -08:00
Juan Batiz-Benet
730793e2f7
cmds/bootstrap: rm --all
2015-01-05 07:59:53 -08:00
Juan Batiz-Benet
dfcea4c6f1
bootstrap: not error to not have enough bootstrap peers
...
use dht bootstrap. there is an edge case where the dht
is tiny (1?) and we have 0 bootstrap peers. we should
probably _inform_ the user, but this may be more a
webui or command thing.
2015-01-05 07:13:51 -08:00
Brian Tiger Chow
30eb8f213f
adjust const
...
to test jenkins
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2015-01-05 06:25:56 -08:00
Brian Tiger Chow
9e4b9714ce
feat(core) dht.Bootstrap
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2015-01-05 06:25:25 -08:00
Juan Batiz-Benet
b599e28b88
core/mock: use mock routing
...
this fixes a failing ipns test which didnt have
a "working" routing system
2015-01-05 00:16:53 -08:00
Juan Batiz-Benet
e21b1f662b
fuse mount lifecycle fixes
...
This commit cleans up how mounting was being done.
It now successfully signals when it is properly mounted
and listen to close signals correctly.
2015-01-04 00:47:27 -08:00
Juan Batiz-Benet
1fa14335b9
core: rearranged initialization a bit
2015-01-04 00:47:27 -08:00
Juan Batiz-Benet
8fb5cf9578
swap net2 -> net
2015-01-02 08:46:46 -08:00
Juan Batiz-Benet
e2698a8733
net -> p2p/net
...
The net package is the next to move. It will be massaged
a bit still to fix the Network / "NetworkBackend" conflict.
2015-01-02 08:46:45 -08:00
Juan Batiz-Benet
cc0d7c9b57
crypto -> p2p/crypto
...
The crypto package moves into p2p. Nothing in it so far is ipfs
specific; everything is p2p-general.
2015-01-02 08:46:45 -08:00
Juan Batiz-Benet
89f5cd4c94
introducing p2p pkg
...
I think it's time to move a lot of the peer-to-peer networking
but-not-ipfs-specific things into its own package: p2p.
This could in the future be split off into its own library.
The first thing to go is the peer.
2015-01-02 08:46:45 -08:00
Juan Batiz-Benet
49cb135ca2
ipfsnet -> swarmnet
...
swarmnet is a better name for the package, because
it's just a Network implemented with a Swarm.
(ipfsnet will be something slightly different).
2015-01-02 08:46:44 -08:00
Juan Batiz-Benet
4807127def
net: move Network implementation to own pkg
...
I needed the network implementation in its own
package, because I'll be writing several services that
will plug into _it_ that shouldn't be part of the core net
package. and then there were dependency conflicts. yay.
mux + identify are good examples of what i mean.
2015-01-02 08:46:43 -08:00
Jeromy
14fc4188be
address comments from PR
2015-01-02 07:42:08 +00:00
Jeromy
07b064010e
rewrite of provides to better select peers to send RPCs to
...
refactor test peer creation to be deterministic and reliable
a bit of cleanup trying to figure out TestGetFailure
add test to verify deterministic peer creation
switch put RPC over to use getClosestPeers
rm 0xDEADC0DE
fix queries not searching peer if its not actually closer
2015-01-02 07:42:07 +00:00
Brian Tiger Chow
07fa9eecbd
hotfix(core/mock) set Network field
2014-12-25 15:20:54 -05:00
Brian Tiger Chow
ca32a83394
wip with DHT
...
@whyrusleeping @jbenet this is a WIP with the DHT.
wip
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
Conflicts:
epictest/addcat_test.go
exchange/bitswap/testnet/peernet.go
exchange/bitswap/testutils.go
routing/mock/centralized_server.go
routing/mock/centralized_test.go
routing/mock/interface.go
fix(routing/mock) fill in function definition
2014-12-24 09:31:19 -05:00
Brian Tiger Chow
27dc9594ba
refactor(bitswap) bitswap.Network now abstracts ipfs.Network + ipfs.Routing
...
@jbenet @whyrusleeping
the next commit will change bitswap.Network.FindProviders to only deal
with IDs
2014-12-23 09:19:21 -08:00
Juan Batiz-Benet
64a4abcd6c
listen addresses: add Interface addresses
...
network.ListenAddresses() are general.
Interface addresses are specific.
2014-12-23 09:01:54 -08:00
Juan Batiz-Benet
7952d95bbf
added bootstrap logging
2014-12-23 08:48:58 -08:00
Juan Batiz-Benet
a10fb7aa4b
core: set local listening addresses
2014-12-23 08:44:59 -08:00
Juan Batiz-Benet
c84a714b16
peer change: peer.Peer -> peer.ID
...
this is a major refactor of the entire codebase
it changes the monolithic peer.Peer into using
a peer.ID and a peer.Peerstore.
Other changes:
- removed handshake3.
- testutil vastly simplified peer
- secio bugfix + debugging logs
- testutil: RandKeyPair
- backpressure bugfix: w.o.w.
- peer: added hex enc/dec
- peer: added a PeerInfo struct
PeerInfo is a small struct used to pass around a peer with
a set of addresses and keys. This is not meant to be a
complete view of the system, but rather to model updates to
the peerstore. It is used by things like the routing system.
- updated peer/queue + peerset
- latency metrics
- testutil: use crand for PeerID gen
RandPeerID generates random "valid" peer IDs. it does not
NEED to generate keys because it is as if we lost the key
right away. fine to read some randomness and hash it. to
generate proper keys and an ID, use:
sk, pk, _ := testutil.RandKeyPair()
id, _ := peer.IDFromPublicKey(pk)
Also added RandPeerIDFatal helper
- removed old spipe
- updated seccat
- core: cleanup initIdentity
- removed old getFromPeerList
2014-12-23 08:33:32 -08:00
Juan Batiz-Benet
41751b4938
Integrated new network into ipfs
2014-12-16 14:47:29 -08:00
Juan Batiz-Benet
b039ebceb6
core: arrangement change in struct
2014-12-16 14:47:29 -08:00
Markus Amalthea Magnuson
dbefedbb2e
Fix typo.
...
”configurationx” -> ”configuration”
2014-12-14 20:55:29 +01:00
Brian Tiger Chow
3ecdec985f
refactor(mockrouting) misc
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-13 05:30:33 -08:00
Brian Tiger Chow
8e0c8a7a7e
refactor(mdag, bserv, bs) mocks, etc.
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-13 05:17:16 -08:00
Brian Tiger Chow
c2c95d1105
start threading context through the system
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-09 07:11:48 -08:00
Juan Batiz-Benet
94f04c7fcc
net: add Connectedness var.
2014-12-08 20:52:45 -08:00
Brian Tiger Chow
f8a449953b
fix(core) bootstrap panic
...
@jbenet @mappum
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 18:04:41 -08:00
Brian Tiger Chow
db700839d4
rm logging statement that isn't that useful
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 16:29:33 -08:00
Brian Tiger Chow
df4b54524c
refactor(bootstrap) reduce interface
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 16:29:29 -08:00
Brian Tiger Chow
7b5eff5cef
feat(bootstrap) consider active cxns and connect to subset
...
* only bootstrap if the number of active connections falls below a given threshold
* when bootstrapping, connect to a subset of peers
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 16:29:25 -08:00
Brian Tiger Chow
175da4f584
feat(core) supervise bootstrap connections
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 16:29:20 -08:00
Brian Tiger Chow
b799ddef58
refactor(dht) remove extraneous return value
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 16:28:22 -08:00
Brian Tiger Chow
6c419e6af4
style(core) signature
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 15:07:33 -08:00
Brian Tiger Chow
74eb03231d
fix(core, peer) helpers to testutil, err handling
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 14:32:52 -08:00
Brian Tiger Chow
d77c4bb5e0
refactor(peer): create peer through peerstore
...
for safety!
use mockpeer.WithID methods to create peers in tests
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 02:10:42 -08:00
Brian Tiger Chow
73a89e161d
refactor(peerstore) s/Get/FindOrCreate
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 02:10:42 -08:00
Brian Tiger Chow
3f63e50c54
fix(peer): use error-checking multiaddr method
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-08 01:10:25 -08:00
Juan Batiz-Benet
59c1ab2fc3
Merge pull request #406 from jbenet/new-msgio
...
updated msgio
2014-12-06 16:20:51 -08:00
Juan Batiz-Benet
5c64ee90e0
cmds: remove info logging
2014-12-06 10:27:12 -05:00
Brian Tiger Chow
9895af2dff
feat(core) using WriteCached, cache Puts for exchange and blockservice
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 23:31:01 -08:00
Brian Tiger Chow
670d0244b4
feat(bitswap) make offline exchange query datastore
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 23:31:01 -08:00
Brian Tiger Chow
697453dfc2
fix(cmd/bootstrap) s/remove/rm
...
@jbenet
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:56:28 -08:00
Matt Bell
c91805d7bd
core/commands: Fixed build on Windows
2014-12-05 20:56:26 -08:00
Brian Tiger Chow
4882904c3e
fix: s/bootstrap rm/boostrap remove
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:56:26 -08:00
Brian Tiger Chow
3bdb36614e
fix(cmd/id) determine offline-ness with !node.OnlineMode()
...
It's better to have one mechanism for determining whether we're offline
and to improve the SnR of this mechanism over time. We presently have
too many arbitrary heuristics for determining whether we're running in
offline mode. TRTTD is to use polymorphism to eliminate these
conditional checks. (instantiate the node with offline versions of
routing, network, etc.) It'll clean up the core constructor, make it
easier to create ephemeral nodes, and eliminate a class of errors.
@whyrusleeping @jbenet
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:56:26 -08:00
Brian Tiger Chow
65c6bd07bf
feat(core/commands): expose commands to allow for the development of high-level interface
...
+ style: sort command list
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:56:26 -08:00
Jeromy
f0a4fdad59
some bitswap cleanup
2014-12-05 20:53:32 +00:00
Jeromy
4cc1780705
fix issues in merkledag
2014-12-05 20:53:31 +00:00
Brian Tiger Chow
d0304def6b
refactor(blockstore, blockservice) use Blockstore and offline.Exchange
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:53:24 +00:00
Brian Tiger Chow
918c8e274e
refactor(blockstore) mv under blocks/
...
@jbenet @whyrusleeping
the pyramids were built one brick at a time
addresses: https://github.com/jbenet/go-ipfs/issues/370
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:53:23 +00:00
Brian Tiger Chow
81a3ba0677
tests(bitswap) share constructor between tests
...
@whyrusleeping i hope this makes it a bit easier to work with tests
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-12-05 20:53:22 +00:00
Juan Batiz-Benet
11508f8f19
Merge pull request #372 from chriscool/add_quiet_flag
...
Implement the -q or --quiet flag to add with minimal output
2014-12-05 15:45:49 -05:00
Jeromy
b0e915be47
cleanup useless debug statement
2014-12-01 17:08:35 +00:00
Jeromy
28a32915b7
fix for #381
2014-12-01 08:34:07 +00:00
Christian Couder
5bfdc2e2b7
Add --quiet option to ipfs add
...
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2014-11-30 14:23:08 +01:00
Brian Tiger Chow
f3b71cfbfd
log(core) Event: bootstrap
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-25 06:16:40 -08:00
Brian Tiger Chow
2497c93897
log(core) bootstrapping error -> critical
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-25 06:12:35 -08:00
Juan Batiz-Benet
1a5cb300cb
config: swarm is list of addrs
2014-11-20 09:14:48 -08:00
Matt Bell
ab16237bc7
core/commands: Added no-op Mount implementation for Windows
2014-11-19 05:29:48 -08:00
Matt Bell
5461d76957
core/commands: Better syntax for 'pin ls' option value handling
2014-11-19 03:23:21 -08:00
Matt Bell
928f20b4bd
core/commands: pin ls: Default type to 'direct'
2014-11-19 01:44:51 -08:00
Matt Bell
9de01007d0
core/commands: pin ls: Accept 'type' option to specify type of pinned keys to list
2014-11-19 00:53:57 -08:00
Matt Bell
4c1a5f6816
core/commands: Restored 'pin'/'refs' option names
2014-11-19 00:36:30 -08:00
Matt Bell
87853f2bde
core/commands: Made 'add' use OptionRecursivePath
2014-11-19 00:36:03 -08:00
Matt Bell
49dc13e5dd
core/commands: Added plaintext marshaler for 'pin ls'
2014-11-18 23:20:38 -08:00
Matt Bell
db53de806c
core/commands: Made 'refs' output u.Keys instead of strings
2014-11-18 23:20:20 -08:00
Matt Bell
477c246c6c
core/commands: Fixed 'refs' option name collision
2014-11-18 23:09:53 -08:00
Matt Bell
edb8eeaecf
core/commands: Created a general key list output type and plaintext marshaler
2014-11-18 23:08:56 -08:00
Matt Bell
961e4504f1
core/commands: Fixed pin flag name (conflicted with global -r/--recursive flag)
2014-11-18 23:03:41 -08:00
Matt Bell
afc7b6f48d
core/commands: Added a 'pin ls' command
2014-11-18 23:02:33 -08:00
Juan Batiz-Benet
5aaa45db9a
transitioned ipfs2 -> ipfs
2014-11-18 06:15:00 -08:00
Juan Batiz-Benet
ad3f3e003f
removed old commands files
...
https://www.youtube.com/watch?v=kyFyAqLtHq8
2014-11-18 06:15:00 -08:00
Matt Bell
7a4491ada3
Added --mount flag to mount when running 'ipfs daemon'
2014-11-18 03:31:32 -08:00
Matt Bell
a0bd29d5be
core/commands2: Fixed swarm command for new arguments API
2014-11-18 02:16:30 -08:00
Matt Bell
0709621a2c
core/commands2: Updated id command for new argument API
2014-11-18 02:13:57 -08:00
Matt Bell
bde015616f
core/commands2: add: Handle 'addDagnode' errors
2014-11-18 02:13:56 -08:00
Matt Bell
bfdf7951b3
core/commands2: Use path.Split for path parsing in 'add'
2014-11-18 02:13:56 -08:00
Matt Bell
d1f1d2f5bf
core/commands2: Fixed commands to use string arguments
2014-11-18 02:13:55 -08:00
Matt Bell
032e9c292f
core/commands2: Updated 'add' command for new file API
2014-11-18 02:13:54 -08:00
Matt Bell
fe6ac42c0e
core/commands2: Updated 'add' command for request file API
2014-11-18 02:13:54 -08:00
Matt Bell
052d387ae5
core/commands2: Fixed 'block' command for req.Files() API
2014-11-18 02:13:53 -08:00
Juan Batiz-Benet
81135f3dc2
added ipfs swarm connect
2014-11-18 01:47:01 -08:00
Juan Batiz-Benet
4d78c2d7ff
cmds: swarm peer
2014-11-18 00:48:03 -08:00
Juan Batiz-Benet
21d2838d4f
cmds/id: fixed args + err checks
2014-11-17 23:46:46 -08:00
Juan Batiz-Benet
f47b4f1799
Merge pull request #255 from jbenet/id-cmd
...
basic ID cmd
2014-11-17 23:23:06 -08:00
Juan Batiz-Benet
6107612fd0
Merge pull request #355 from jbenet/feat/daemon-init
...
feat(daemon) `ipfs daemon --initialized`
2014-11-17 23:22:01 -08:00
Juan Batiz-Benet
d93e49e06e
fix node context (tests pass)
2014-11-17 22:50:01 -08:00
Brian Tiger Chow
24f0fa0fde
delegate teardown
...
this is silly but whatever
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-17 22:36:19 -08:00
Brian Tiger Chow
ef65bb1ce3
revert to debug error
...
@jbenet
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-17 22:36:18 -08:00
Brian Tiger Chow
2bbfe4d56f
debug(core, datastore, daemon) wrap errors
...
@jbenet @whyrusleeping @mappum
very helpful for tracking down errors. the stack traces are only
shown when debug mode is visible. They function best when caught at the
source.
I propose we use this errors package as a drop-in replacement for
fmt.Errorf and errors.New in all of our code, and use errors.Wrap for
external errors as they emerge from others' libraries.
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
Signed-off-by: Brian Tiger Chow <brian.holderchow@gmail.com>
2014-11-17 22:36:18 -08:00
Brian Tiger Chow
bacf3ecc6a
feat(util) add datastore Closer Wrapper
...
@jbenet
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-17 22:36:17 -08:00
Jeromy
7d2f3d810c
fix tabbing
2014-11-17 11:57:57 -08:00
Jeromy
4588732af3
address comments from PR
2014-11-17 10:27:41 -08:00
Brian Tiger Chow
f26388e0e5
fix(core) tear-down leveldb
...
@jbenet @whyrusleeping @mappum
If we permit initialization in `ipfs daemon`, then we must ensure that
the node instantiated in `ipfs init` (to create the welcome file) shuts
down and releases resources.
Kept running into "resource temporarily unavailable". Discovered that it
was our cousins Jeff and Sanjay over at LevelDB Ave.
go-datastore doesn't expose Close() so I extended the TsDs interface and
submitted a patch.
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
Signed-off-by: Brian Tiger Chow <brian.holderchow@gmail.com>
2014-11-17 00:44:18 -08:00
Jeromy
9f4127aefa
fix variable naming
2014-11-16 17:12:35 -08:00
Jeromy
0de12b5d36
implement ipfs id in the new commands library
2014-11-16 16:46:06 -08:00
Christian Couder
46d8acf60f
Add missing 'mount' in mount synopsis
...
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2014-11-16 21:04:53 +01:00
Christian Couder
5098e39203
Suggest use of ipfs daemon in mount help message
...
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
2014-11-16 18:14:27 +01:00
Brian Tiger Chow
a11c59dcac
feat(peer) add Type (Unspecified, Local, Remote)
2014-11-16 07:00:58 -08:00
Brian Tiger Chow
ac84515441
style(core_test) move test variable
2014-11-16 07:00:28 -08:00
Brian Tiger Chow
05346dd927
misc(core/identity) more specific function argument
...
to aid in testing
2014-11-16 07:00:28 -08:00
Brian Tiger Chow
1ed0850ce2
style(core) peer -> self
2014-11-16 07:00:28 -08:00
Jeromy
f45d575a96
address comments from PR
2014-11-16 02:45:20 -08:00
Jeromy
f21ec1923a
verify ipns records
2014-11-16 02:45:19 -08:00
Juan Batiz-Benet
93ad2bd057
mount: if already mounted, unmount before new attempt
...
This is because if the user specifies that they want
to mount multiple times, something must be wrong. try
unmounting to reset things and then proceed.
2014-11-16 02:22:53 -08:00
Juan Batiz-Benet
99f2378bac
mount: fixed mount init + teardown
...
This commit adds a Mount abstraction (which is really just
a wrapped context closer). It makes sure to bind the mount
to the fate of the Node (i.e. close it if the node ends).
This fixes #350
2014-11-16 01:42:42 -08:00
Juan Batiz-Benet
a4488cab4c
cmds: root help inc synopsis
2014-11-15 09:04:49 -08:00
Juan Batiz-Benet
7d448d9dab
cmds mount synopsis
2014-11-15 09:04:49 -08:00
Juan Batiz-Benet
1871d37f12
Merge pull request #333 from zignig/mount_fix
...
windows mount fix
2014-11-15 06:51:55 -08:00
Juan Batiz-Benet
8a284c9848
cmds: fix block output.
2014-11-15 06:43:02 -08:00
Brian Tiger Chow
0b42d77e13
refactor(core, bitswap) split bitswap init into two steps
...
@jbenet
2014-11-15 02:10:53 -08:00
Simon Kirkby
43fb5d5d72
windows fix
2014-11-14 21:03:30 +08:00
Brian Tiger Chow
a0dab3a29a
docs(2/pin)
...
ipfs1 docs read:
```
btc λ. ipfs pin
ipfs pin -
Commands:
add pin an ipfs object to local storage.
rm unpin an ipfs object from local storage.
Use "pin help <command>" for more information about a command.
```
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:24:43 -08:00
Juan Batiz-Benet
f30161b063
cmds: nicer error on no mountpoint
2014-11-14 03:20:46 -08:00
Matt Bell
e4b630289a
block put: Support stdin input on 'block put'
2014-11-14 03:20:11 -08:00
Juan Batiz-Benet
97d2f48b7c
cmds2: change add arg name
2014-11-14 03:20:11 -08:00
Matt Bell
d05661548c
object links: Fixed description
2014-11-14 03:20:11 -08:00
Juan Batiz-Benet
5e598f9a52
cmds2: mount exmplae
2014-11-14 03:20:11 -08:00
Matt Bell
b3da13a4af
object links: Added text marshaling
2014-11-14 03:20:10 -08:00
Matt Bell
7bd7624ccc
object data: Moved some helptext into LongDescription
2014-11-14 03:20:10 -08:00
Matt Bell
9d299636ad
object put: Made output (almost) match original output
...
(The file path is omitted, but since only one object can be added at a time, I think this is ok)
2014-11-14 03:20:10 -08:00
Matt Bell
fceb55ef1e
object put: Added plaintext marshaler
2014-11-14 03:20:10 -08:00
Matt Bell
b4de6cce9a
object put: Fixed putting objects with JSON encoding
2014-11-14 03:20:10 -08:00
Matt Bell
eb696d9ac7
object put: Formatted helptext
2014-11-14 03:20:10 -08:00
Matt Bell
537f94a318
object get: Fixed protobuf marshaling
2014-11-14 03:20:10 -08:00
Matt Bell
4eaf38c6ba
object: Added a synopsis
2014-11-14 03:20:10 -08:00
Brian Tiger Chow
d842c3c98f
fix(2/update) insert line break
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:09 -08:00
Brian Tiger Chow
92c168b03e
fix(2/update) newlines
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:09 -08:00
Juan Batiz-Benet
e0ba14c0eb
cmds2: use cmdDetails on level cmds
2014-11-14 03:20:09 -08:00
Juan Batiz-Benet
1348af01b9
cmd2: version test
2014-11-14 03:20:09 -08:00
Juan Batiz-Benet
aab1a31b1b
cmds2: add fix, was not adding dirs
2014-11-14 03:20:08 -08:00
Juan Batiz-Benet
e00830332f
cmds2: name synopsis.
2014-11-14 03:20:08 -08:00
Brian Tiger Chow
80dcc5d237
fix(2/version)
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:08 -08:00
Juan Batiz-Benet
bb8d4ebd6b
cmds2: cmdDetailsMap
2014-11-14 03:20:07 -08:00
Matt Bell
120ead26f4
resolve: Added a TODO
2014-11-14 03:20:06 -08:00
Matt Bell
e35453c50d
mount: Cleaned up option descriptions
2014-11-14 03:20:06 -08:00
Brian Tiger Chow
a00da7b728
add debug log statement
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:06 -08:00
Juan Batiz-Benet
89ec480ef1
cmds2: bootstrap command fix add
2014-11-14 03:20:06 -08:00
Juan Batiz-Benet
047d2e2d62
cmd2: Marshaller -> Marshaler (see golang/encoding)
...
Also:
- map[cmds.EncodingType]cmds.Marshaller -> MarshalMap
cc @mappum @maybebtc
2014-11-14 03:20:05 -08:00
Juan Batiz-Benet
0f7757c6fa
subcmd2: added synopsis to bootstrap
2014-11-14 03:20:05 -08:00
Matt Bell
2a2ec747d5
core/commands2: Removed unused options from 'config', and fixed synopsis syntax
2014-11-14 03:20:05 -08:00
Matt Bell
e700b16576
Ported remaining command helptext to HelpText struct
2014-11-14 03:20:05 -08:00
Brian Tiger Chow
6597a5f7fe
fix(2/ls) require arg
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:04 -08:00
Brian Tiger Chow
131c15e924
fix(2/log) use 'all' as the specifier to set all log levels
...
fixes #322
cc @mappum
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:04 -08:00
Brian Tiger Chow
fb187e49e3
test(2/diag) test print diagnostics
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:04 -08:00
Matt Bell
7f24a9965f
core/commands: Ported commands to use HelpText struct for helptext fields
2014-11-14 03:20:03 -08:00
Matt Bell
2dd6f24157
core/commands2: Refactored some commands to HelpText struct for helptext fields
2014-11-14 03:20:03 -08:00
Juan Batiz-Benet
1342575d24
cmds2/commands: better sorting
2014-11-14 03:20:03 -08:00
Juan Batiz-Benet
d18902df27
cmds2: changed how the ctx.Node works
2014-11-14 03:20:02 -08:00
Brian Tiger Chow
9eccce1f93
fix(2/diag) match ipfs output
...
License: MIT
Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
2014-11-14 03:20:02 -08:00
Juan Batiz-Benet
3352aeee15
cmds2: fixed show help on root + noncallable
2014-11-14 03:20:02 -08:00
Juan Batiz-Benet
c46d4c8953
cmd2 fixed config panic
...
The way the current marshallers marshal out output requires
a ton of error checking. I wish there was a way to have the
library call our marshaller with the right type (rather
than an interface). Maybe can do this with Reflect someday.
2014-11-14 03:20:02 -08:00
Juan Batiz-Benet
973a8f5cb1
cmds2: commands
2014-11-14 03:20:02 -08:00
Matt Bell
f797d13579
core/commands2: Added function to generate a 'commands' command for a root
2014-11-14 03:20:01 -08:00
Matt Bell
53e875e5fc
core/commands2: Format 'commands' to match original output (re: #317 )
2014-11-14 03:20:01 -08:00
Juan Batiz-Benet
86b08f4e4b
cmds2 config outputs nicely
2014-11-14 03:20:01 -08:00
Juan Batiz-Benet
f2c54f5a4b
cmd2 bootstrapCmd missing type
2014-11-14 03:20:00 -08:00
Juan Batiz-Benet
ef4480fe6d
cmds/config: better help text
2014-11-14 03:20:00 -08:00
Brian Tiger Chow
3c9fb48699
fix(2/bootstrap) catch hidden panic
...
@mappum any idea what might cause the type to not match here?
2014-11-14 03:20:00 -08:00
Brian Tiger Chow
cc37cc18c9
question(mount_unix) add todo regarding mount timeout
...
@whyrusleeping @jbenet
is this non-deterministic?
2014-11-14 03:19:59 -08:00
Brian Tiger Chow
33ba3f6321
refactor(mount_unix) return the errs in select
...
fix(mount_unix) rm extraneous error
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
013d98a35a
fix(2/init, 2/add) fix optionvalue signature
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
3493e33ec9
fix(2/version) option value sig
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
7c75227190
fix(2/refs) optionvalue signature
...
@mappum this one is straightforward, but tagging you here just in case
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
a95dfdcf82
fix(2/pin) optionvalue signature
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
b6f89db1d4
fix(mount_unix) optionvalue signature
...
@mappum can you just sanity check me here with a quick LGTM CR?
2014-11-14 03:19:58 -08:00
Brian Tiger Chow
654fa3fe96
fix(commands/mount_unix, optionvalue) handle found, !found
...
@mappum, could you provide a quick LGTM?
2014-11-14 03:19:57 -08:00
Juan Batiz-Benet
49792b2362
refactored cast errors to use a util
2014-11-14 03:19:56 -08:00
Juan Batiz-Benet
f6c1cefe60
cmds/add fixed add output
2014-11-14 03:17:43 -08:00
Juan Batiz-Benet
0e41e19305
add logging file
2014-11-14 03:17:43 -08:00
Juan Batiz-Benet
6faeee8300
cmds2/add: temp fix for -r. horrible hack
...
This will be removed soon, just gets us past landing cmds2.
2014-11-14 03:17:42 -08:00
Juan Batiz-Benet
e32ed36ee9
cmds2/add: return correct error
2014-11-14 03:17:42 -08:00
Brian Tiger Chow
fcabf22266
feat(ipfs2/config) impl show and edit as options
...
verified that option text hints match ipfs1 - btc
2014-11-14 03:17:42 -08:00
Brian Tiger Chow
45526224e4
todo
...
@mappum, it's okay to make it a read TODO. in fact, it's a really nice
practice since it's standard and we can grep it. When someone who
has an answer for the concern comes across the standard TODO breadcrumb,
he/she can address it. Using the conventional TODO improves
discoverability.
2014-11-14 03:17:42 -08:00
Matt Bell
7a505b44c7
Handle -h and --help differently (short text vs long text)
2014-11-14 03:17:42 -08:00
Matt Bell
e23b537f32
Override root command help text
2014-11-14 03:17:41 -08:00
Matt Bell
6869ca44fa
core/command2: Fixed indentation
2014-11-14 03:17:41 -08:00
Matt Bell
c468a4dbf5
core/commands2: Use Argument constructors in commands
2014-11-14 03:17:39 -08:00
Matt Bell
3e507f7c9f
commands: Changed option accessor API (Request#Option now returns an OptionValue)
2014-11-14 03:17:38 -08:00
Matt Bell
8ee3e996cc
core/commands2: Use Option constructors in commands
2014-11-14 03:17:37 -08:00
Matt Bell
3e30093c2b
core/commands2: Updated commands to new Run function API
2014-11-14 03:17:37 -08:00
Matt Bell
352c29418f
core/commands2: Made 'ls' output match old command
2014-11-14 03:17:36 -08:00
Matt Bell
68693783fe
core/commands2: Made 'resolve' output match old command
2014-11-14 03:17:36 -08:00
Matt Bell
2d756473f6
core/command2: Make help text match old commands
2014-11-14 03:17:36 -08:00
Matt Bell
3406ee0ef4
core/commands2: Added 'refs' command
2014-11-14 03:17:36 -08:00
Matt Bell
a1d34365e4
core/commands2: Restored logging that got removed
2014-11-14 03:17:36 -08:00
Matt Bell
91da11ae66
core/commands2: Replaced NewDagFromReader with BuildDagFromReader
2014-11-14 03:17:36 -08:00
Brian Tiger Chow
f4d0b8baa0
clarity(util) ToReaders -> CastToReaders
2014-11-14 03:17:36 -08:00
Matt Bell
f3733873de
core/commands2: Fixed 'object get' dagnode output format
2014-11-14 03:17:35 -08:00
Matt Bell
652e3d0523
core/commands2: Fixed 'add' output adding an empty object
2014-11-14 03:17:35 -08:00
Matt Bell
c8345bb5c6
core/commands2: 'object' description formatting improvements
2014-11-14 03:17:34 -08:00
Matt Bell
c542cb52aa
core/commands2: Added 'object' command
2014-11-14 03:17:34 -08:00
Matt Bell
92f2e8440a
core/commands2: Updated root help text
2014-11-14 03:17:34 -08:00
Matt Bell
c8696a8d32
core/commands2: Better formatted descriptions for 'mount'
2014-11-14 03:17:33 -08:00
Matt Bell
c2615d3481
core/commands2: Added descriptions for all the existing commands
2014-11-14 03:17:33 -08:00
Matt Bell
bb7d4683f1
core/commands2: Removed test subcommands
2014-11-14 03:17:33 -08:00
Matt Bell
218d52642c
core/commands2: Added descriptions for 'add', 'block'
2014-11-14 03:17:33 -08:00
Brian Tiger Chow
538dac153b
diag doc
2014-11-14 03:17:33 -08:00
Brian Tiger Chow
7046ff0e57
net-diag -> diag net
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
2720c4f1c6
fix(name:resolve, name:publish) docs
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
101601195c
docs(pin) help
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
3dcae0e079
pin/unpin -> add rm
...
addresses
https://github.com/jbenet/go-ipfs/pull/263#issuecomment-62242970
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
852674b167
chore(pin) rm commented code
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
63feb68ce7
refactor(name, pub, resolve) separate files
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
092e346f94
docs(name/publish/resolve) help
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
c69ea0d6e2
add fixmes
2014-11-14 03:17:32 -08:00
Brian Tiger Chow
ff55968b4c
fix(mount) add argument
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
d066f15c37
todo(ls)
...
@jbenet
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
0e8e3cccb6
docs(ls) help
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
229b22f9c4
docs(log) help
...
making docs match command:
name -> subsystem. Is the desired name?
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
48d65c6d95
docs(net-diag) help + name
...
@jbenet @whyrusleeping
Docs read net-diag. It seems the command was previously registered as
diag. Which do you prefer?
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
1c7ef8926d
docs(commands) help
2014-11-14 03:17:31 -08:00
Brian Tiger Chow
a631d745d0
docs(add) help
2014-11-14 03:17:31 -08:00
Matt Bell
36dfb7bc43
core/commands2: Added 'update' command
2014-11-14 03:17:30 -08:00
Brian Tiger Chow
c65b01c55c
fix(add) cast safely
2014-11-14 03:17:30 -08:00
Brian Tiger Chow
440c90be24
extract unpin
...
@mappum
2014-11-14 03:17:30 -08:00
Brian Tiger Chow
92d20e429d
add slice utils
...
ToStrings and ToReaders
2014-11-14 03:17:30 -08:00
Brian Tiger Chow
4c029a8617
extract toStrings method
2014-11-14 03:17:30 -08:00
Brian Tiger Chow
86f0aac88c
refac(commands2/pin) loop
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
353cb39921
refac(commands2/ls) split loop
...
@mappum
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
6d89094d41
rename -> OnlineMode()
...
because this method doesn't check actual network status
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
8b6931cb02
check mode with use func node.OnlineMode() bool
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
772f657fcd
add online method to node
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
e096060b90
refactor(core/commands2/add) split loop
...
@mappum
2014-11-14 03:17:29 -08:00
Brian Tiger Chow
8cc1f67f76
fmt
2014-11-14 03:17:29 -08:00
Matt Bell
18cce63ab6
core/commands2: Added 'block' command
2014-11-14 03:17:29 -08:00
Matt Bell
1c5979e549
core/commands2: Added 'mount' command
2014-11-14 03:17:29 -08:00
Matt Bell
16c584ce93
core/commands2: Added 'bootstrap' command
2014-11-14 03:17:28 -08:00
Matt Bell
7228c8fe48
core/commands2: Added 'config' command
2014-11-14 03:17:28 -08:00
Matt Bell
b6aad53d86
core/commands2: Added 'version' command
2014-11-14 03:17:28 -08:00
Matt Bell
af65eec2fc
core/commands2: Output error when trying to run 'publish' or 'resolve' in offline mode
2014-11-14 03:17:28 -08:00
Brian Tiger Chow
51c6a1c552
refactor(resolve) separate argument marshalling from the operation
...
@mappum see how the unpacking of arguments happens separately from the
resolve loop?
It's a bit more verbose, but much clearer.
However, doing two different things in one loop is less clear than doing
them separately.
It also causes problems for further refactoring as it introduces temps
that get in the way of further refactorings.
Plus, there will be 50+ commands, so it's important that we stay
framework agnostic as much as possible.
So, this is the style we prefer. It'll keep us nimble in the long run.
2014-11-14 03:17:28 -08:00
Matt Bell
a7accecc8e
core/commands2: Moved 'resolve' and 'publish' into subcommands of 'name'
2014-11-14 03:17:28 -08:00
Matt Bell
bbca445298
core/commands2: Added 'resolve' command
2014-11-14 03:17:28 -08:00
Matt Bell
109af01396
core/commands2: Added 'pin' and 'unpin' commands
2014-11-14 03:17:28 -08:00
Matt Bell
61e8ad9990
core/commands2: Added 'diag' command
2014-11-14 03:17:27 -08:00
Matt Bell
79b88ee028
core/commands2: Added argument definitions to 'publish'
2014-11-14 03:17:27 -08:00
Matt Bell
4765a1d660
core/commands2: Made 'cat' require object argument
2014-11-14 03:17:27 -08:00
Brian Tiger Chow
e86e7d875e
extract publish func
2014-11-14 03:17:26 -08:00
Brian Tiger Chow
d2d29a80dc
docs(commands2/cat) help text
2014-11-14 03:17:24 -08:00
Brian Tiger Chow
2a15fe8e1e
refactor(commands2/cat) readability
2014-11-14 03:17:24 -08:00
Juan Batiz-Benet
fd1cd99556
restore add.go from master
2014-11-14 03:17:24 -08:00
Matt Bell
f95476c19a
commands: Allow overriding marshaller for any encoding type
2014-11-14 03:17:24 -08:00
Matt Bell
0afd3391a8
commands: Replaced 'Formatter' with 'Marshaller'
2014-11-14 03:17:23 -08:00
Matt Bell
15cd24a6d1
commands: Renamed Response#Value to Response#Output
2014-11-14 03:17:23 -08:00
Matt Bell
f1209d0912
core/commands2: Added argument definition for 'ls'
2014-11-14 03:17:23 -08:00
Matt Bell
ff987cffae
core/commands2: Added 'log' command
2014-11-14 03:17:23 -08:00
Matt Bell
3c4e7bf9a1
core/commands2: Added a simple 'message' output/formatter
2014-11-14 03:17:23 -08:00
Matt Bell
92e308f32b
core/commands2: Added logging
2014-11-14 03:17:22 -08:00
Matt Bell
38318a6c28
core/commands2: Added output for 'add' command
2014-11-14 03:17:22 -08:00
Matt Bell
77fea8928a
Added argument definition to 'cat' command
2014-11-14 03:17:22 -08:00
Matt Bell
b420ba1e49
core/commands2: Added preliminary 'add' command
2014-11-14 03:17:22 -08:00
Matt Bell
26c2164c35
core/commands2: Removed 'echo' test command
2014-11-14 03:17:22 -08:00
Matt Bell
2915007c4f
commands: Changed Request arguments to a []interface{}
2014-11-14 03:17:22 -08:00
Matt Bell
c70ca4dd51
core/commands2: Added 'publish' command
2014-11-14 03:17:22 -08:00
Matt Bell
cac8844b8d
cmd/ipfs: Reverted back to secondary CLI root command
2014-11-14 03:17:21 -08:00
Matt Bell
24814a411f
core/commands2: Set root subcommands in init to prevent initialization loops
2014-11-14 03:17:21 -08:00
Matt Bell
6ae09b167d
core/commands: Moved commands that were rebased into the wrong directory
2014-11-14 03:17:21 -08:00
Matt Bell
0c205f56cb
core/commands2: Added 'commands' command
2014-11-14 03:17:21 -08:00
Matt Bell
921d3a51ab
commands/http: Pass root command in as field instead of statically depending on core/commands
2014-11-14 03:17:21 -08:00
Matt Bell
9356e1a0a1
cmd/ipfs: Moved private commands to core/commands2
2014-11-14 03:17:21 -08:00
Matt Bell
17c6907e1f
core/command2: Fixed ls output for XML marshalling
2014-11-14 03:17:21 -08:00
Matt Bell
f2271356f5
core/commands2: Added 'ls' command
2014-11-14 03:17:20 -08:00
Brian Tiger Chow
b3e7cbb9a5
refactor(commands) swap argument order to match Http(w, r) idiom
2014-11-14 03:17:20 -08:00
Brian Tiger Chow
1dd0ade3ab
fix(commands2/cat) rm extraneous print in output
2014-11-14 03:17:20 -08:00
Brian Tiger Chow
0aa205f36e
fix(core/commands2) ipfs help message
2014-11-14 03:16:06 -08:00
Brian Tiger Chow
465cce9950
remove duplicate files
...
these weren't actually modified when commands2 was introduced. they're
exact replicas of the ones that presently exist in core/commands.
2014-11-14 03:16:05 -08:00
Brian Tiger Chow
78b5fbffc7
new commands to commands2
2014-11-14 03:16:05 -08:00
Brian Tiger Chow
a5db13f3ae
original commands to original dir
2014-11-14 03:16:05 -08:00
Brian Tiger Chow
e1eb71fce5
new commands to temp dir
2014-11-14 03:16:05 -08:00
Matt Bell
afd8fadba8
core/commands: Added 'cat' command
2014-11-14 03:16:04 -08:00
Matt Bell
7b2f4488b7
core/commands: Added Type to 'beep' command
2014-11-14 03:16:04 -08:00
Matt Bell
edb632a644
core/commands: Added a Format function for the 'beep' command
2014-11-14 03:16:04 -08:00
Matt Bell
be3cb39ed5
core/commands: Added 'echo' command that writes input stream to output stream
2014-11-14 03:16:04 -08:00
Matt Bell
e297e2da41
core/commands: Added a 'args' command to test argument parsing
2014-11-14 03:16:03 -08:00
Matt Bell
4bbd579068
cmd/ipfs: Added 'local' flag to call command locally instead of executing on daemon
2014-11-14 03:16:03 -08:00
Matt Bell
063cb536df
cmd/ipfs: Display help text when help flag is set
2014-11-14 03:16:03 -08:00
Matt Bell
3d0ca14b96
core/commands: Added more advanced test subcommand
2014-11-14 03:16:00 -08:00
Matt Bell
e64ffb9ab3
core/commands: Added root command (with test subcommands)
2014-11-14 03:16:00 -08:00
Juan Batiz-Benet
0135e3ebbe
swarm + net: add explicit listen addresses
2014-11-05 04:00:49 -08:00
Jeromy
ce223eef61
some small cleanup of logging
2014-11-01 16:07:56 -07:00
Jeromy
ae339a0320
remove dagwriter in favor of new importer function
2014-10-31 05:03:42 +00:00
Brian Tiger Chow
cea398b8a7
fix(all) log.Debug -> log.Debugf
2014-10-30 06:35:29 -07:00
Juan Batiz-Benet
b5fc3caea3
cmd/add: output file hash Fixed #239
2014-10-30 06:15:23 -07:00
Juan Batiz-Benet
70e1f9b6bc
make vendor
...
cc @whyrusleeping
2014-10-30 05:43:14 -07:00
Brian Tiger Chow
ff490a6d52
perf(core/datastore) disable snappy compression
2014-10-30 04:58:25 -07:00
Juan Batiz-Benet
f0d823c2db
fix tests (circular import)
2014-10-30 01:17:26 -07:00
Jeromy
71ac117546
Address concerns in PR
2014-10-30 06:23:31 +00:00
Jeromy
18ada93ec3
rewrite add command to use dagwriter, moved a pinner into the dagwriter for inline pinning
2014-10-30 04:40:48 +00:00
Brian Tiger Chow
79866d3378
hotfix(core) assign node.Resolver = path.Resolver
...
discovered by @mappum and applied at 414e20b71e
fixing here to address #233
https://github.com/jbenet/go-ipfs/issues/233
2014-10-29 06:58:35 -07:00
Juan Batiz-Benet
d79ebe68d2
dht ctxcloserify
2014-10-25 21:33:59 -07:00
Juan Batiz-Benet
4584bc8d18
clean up core initialization
...
- less floating variables
2014-10-25 21:33:59 -07:00
Juan Batiz-Benet
8cf22c062f
core is now ctxcloser
2014-10-25 21:33:10 -07:00
Juan Batiz-Benet
f2b8803a57
net/service now uses ctxcloser
2014-10-25 21:33:10 -07:00
Emery Hemingway
056699cebe
convert DAGService to an interface
2014-10-25 22:15:19 -04:00
Jeromy
87407a99b9
add context to blockservice Get
2014-10-25 12:38:32 -07:00
Juan Batiz-Benet
184c25430b
go-vet friendly codebase
...
- distinguish log.Error and log.Errorf functions
- Initialize structs with field names
- A bit of unreachable code (defers)
2014-10-25 03:46:39 -07:00
Henry
4f42a26836
fixed --force flag for shutdown after update
2014-10-22 12:42:13 +02:00
Henry
3e40788188
updateApply: force shutdown check on daemon (TODO: force flag in cli)
2014-10-22 11:25:30 +02:00
Henry
cb73ea7ba4
removed duplicate logic
2014-10-22 11:25:30 +02:00
Henry
7ddf3836d0
implemented manual check and update (with signature verification)
2014-10-22 11:25:30 +02:00
Henry
5fa3053e19
added command stubs
2014-10-22 11:24:34 +02:00
Jeromy
3ee3c44d7c
flush!
2014-10-22 00:28:42 -07:00
Jeromy
31b0ff0307
add testing for pins
2014-10-22 00:28:41 -07:00
Juan Batiz-Benet
8d7850eeb5
updated datastore (keytransform)
2014-10-21 15:18:12 -07:00
Juan Batiz-Benet
f7c1ed39e0
renamed datastore.go -> go-datastore
2014-10-21 15:10:58 -07:00
Juan Batiz-Benet
ac62d13e42
peerstore Put -> Add
...
Changed lots of peer use, and changed the peerstore to ensure
there is only ever one peer in use.
Fixed #174
2014-10-20 06:37:12 -07:00
Juan Batiz-Benet
9ca87fbb93
peer.Peer is now an interface
...

2014-10-20 03:26:46 -07:00
Juan Batiz-Benet
b1d11ccfcb
peerstore constructs peers
...
Now, all peers should be retrieved from the Peerstore, which will
construct the peers accordingly. This ensures there's only one peer
object per peer (opposite would be bad: things get out sync)
cc @whyrusleeping
2014-10-20 00:44:44 -07:00
Juan Batiz-Benet
9e3bfa28bb
Merge pull request #185 from cryptix/cmdObjects
...
object plumbing commands
2014-10-19 16:58:47 -07:00
Henry
468494e5e5
break with ErrObjectTooLarge
2014-10-19 17:07:03 +02:00
Henry
bc38bdf512
limit raw input to 512 kilobytes
2014-10-19 16:57:12 +02:00
Henry
2276b55c57
no links, no error
2014-10-19 16:52:45 +02:00
Jeromy
60cd0f1cf0
some dht cleanup, and make DHTs take a master context
2014-10-18 04:28:26 -07:00
Jeromy
b2bd6848a8
fix core NewNode not setting network field, and added new json serializer for diagnostics
2014-10-18 04:28:25 -07:00
Jeromy
4189d50d77
fix bug in diagnostics, and add more peers to closer peer responses
2014-10-18 04:28:25 -07:00
Henry
e735addbb2
object plumbing commands
2014-10-18 04:35:12 +02:00
Henry
e4da27a2a5
implemented ipfs log command
2014-10-15 13:34:38 +02:00
Henry
3455846b35
add log command
2014-10-15 13:18:00 +02:00
Henry
98d9df544f
remove utils.PErr()
2014-10-15 13:17:04 +02:00
Henry
03e42d8ed4
added TODO about reading from io.Reader arg
2014-10-14 09:57:19 +02:00
Henry
a6630c804f
display key if BlockPut is successful
2014-10-14 00:39:29 +02:00
Henry
073ec11529
fixed BlockGet and cleaned up logging
2014-10-14 00:31:34 +02:00
Henry
08bb6f149f
templates for block commands (updates #138 )
2014-10-13 20:31:14 +02:00
Juan Batiz-Benet
b204c21d10
add plumbing output + logging
...
Fixes #157
Found #158
2014-10-13 02:40:39 -07:00
Juan Batiz-Benet
338b037238
clean up and add inet.Network to bitswap
...
new Service interface
2014-10-10 20:43:04 -07:00
Jeromy
bb84c232e1
make add command use absolute paths and print properly, issue #151
2014-10-10 13:46:51 -07:00
Jeromy
a7b69500b1
address concerns in PR and make log stuff more fun
2014-10-10 13:18:20 -07:00
Jeromy
3732244837
actually start the diagnostics service
2014-10-10 13:18:20 -07:00
Jeromy
96af2a1f81
pretty output
2014-10-10 13:18:20 -07:00
Jeromy
808cf9dfc0
fail with error when running diagnostic in offline mode
2014-10-10 13:18:19 -07:00
Jeromy
d5f0476c1c
implement diagnostics command
2014-10-10 13:18:19 -07:00
Jeromy
280c7e7e06
implement diagnostics service
2014-10-10 13:18:19 -07:00
Juan Batiz-Benet
972c0f7b4b
u.DOut -> log.Debug
...
and other logging switches. I kept the u.PErr and u.POut in cli
commands, as those do need to write raw output directly.
2014-10-09 04:50:22 -07:00
Juan Batiz-Benet
2fa43ce46c
ipfs name cmd improvements
...
- cleaned up cmd help
- ipfs name publish [<name>] <ref>
- ipfs name resolve [<name>]
- publish validates <ref>
- both validate n args
2014-10-09 03:39:47 -07:00
Juan Batiz-Benet
dc6fdd39c5
use encoded (pretty) keys only on fs ds
2014-10-08 14:49:04 -07:00
Jeromy
093c8fb04d
Rework package structure for unixfs and subpackage
...
cc @jbenet
2014-10-08 21:14:18 +00:00
Juan Batiz-Benet
2944360f5c
New NameSystem interface
...
type NameSystem interface {
Resolver
Publisher
}
should say it all.
cc @whyrusleeping
2014-10-08 04:14:52 -07:00
Juan Batiz-Benet
77fccaa2f3
Obviated need for .ID.Pretty() all over the place.
2014-10-06 04:23:55 -07:00
Juan Batiz-Benet
910a76e220
updated multiaddr use across codebase
2014-10-06 04:13:43 -07:00
Jeromy
5592030ed3
working on dag modification structures, factored out the data format into an importer subpackage and added more ipns tests
2014-10-06 03:42:59 +00:00
Jeromy
16e42f82b0
fixed ipns file persistence bug
2014-10-04 22:42:03 +00:00
Jeromy
faaaa2298b
Merge branch 'ipns' of github.com:jbenet/go-ipfs into ipns
2014-10-04 19:26:58 +00:00
Jeromy
25b36d1000
moved mock core node to core package
2014-10-04 19:13:56 +00:00
Juan Batiz-Benet
ee1d1ac078
add: only show added once.
2014-10-04 03:56:12 -07:00
Juan Batiz-Benet
0c8ae7674e
loggers: set level
2014-10-04 03:53:21 -07:00
Juan Batiz-Benet
7e1cd59259
initialize loggers at ERROR
2014-10-04 03:36:30 -07:00
Juan Batiz-Benet
2ce9415c69
+ fs ds + thread safe
2014-10-03 14:45:21 -07:00
Juan Batiz-Benet
88d804e32a
added core logging
2014-10-03 14:45:21 -07:00
Juan Batiz-Benet
f923652d88
remove extra printf
2014-10-02 03:07:52 -07:00
Juan Batiz-Benet
ba510cbd6d
IpnsPublicher -> Publisher interface
2014-10-01 01:36:21 -07:00
Juan Batiz-Benet
b787c705e2
command output nit
2014-10-01 01:28:55 -07:00
Juan Batiz-Benet
1cfb0ffd05
command output nit
2014-10-01 01:28:20 -07:00
Juan Batiz-Benet
14a384d826
pin: add depth arg.
2014-10-01 01:26:48 -07:00
Juan Batiz-Benet
728f17d3c9
cmd/ipfs/pin.go now uses MakeCommand
...
+ added recursive pinning func
2014-10-01 01:17:27 -07:00
Juan Batiz-Benet
7cd9e4db3e
remove merge issue (logger)
2014-10-01 00:45:36 -07:00
Juan Batiz-Benet
f085d594aa
vendoring ipns things
2014-10-01 00:44:22 -07:00
Jeromy
6080944af9
writing files inside ipns works now! also implemented resolve cli command
2014-10-01 00:41:29 -07:00
Jeromy
7f5e13716d
writes to ipns work if the top object is the written file (no directories yet!)
2014-10-01 00:39:57 -07:00
Jeromy
e61c59758b
implement initial ipns filesystem interface as well as plumbing command for publishing
2014-10-01 00:39:57 -07:00
Jeromy
2aa2b8c6c7
add routing resolver test
2014-10-01 00:26:59 -07:00
Jeromy
4c0f18cbbd
implement ipns publisher code
2014-10-01 00:26:59 -07:00
Jeromy
8ddfb57c59
some bugfixes and added logging
2014-10-01 00:26:59 -07:00
Jeromy
b5fd9492d7
fixes to make interface more usable
2014-10-01 00:25:52 -07:00
Jeromy
235a767492
implement namesys resolvers (thanks to bren2010 for dns and proquint)
2014-10-01 00:16:05 -07:00
Juan Batiz-Benet
c7af4a6fa2
Bugfix: !online -> online
...
Caused panic.
2014-09-30 11:34:28 -07:00
Juan Batiz-Benet
c054619827
do init id offline, only dont parse keys
...
(test was failing)
2014-09-30 03:31:24 -07:00
Brian Tiger Chow
508a5b7a94
amendment to core context + cancels
2014-09-30 03:22:30 -07:00
Juan Batiz-Benet
4b5e0291f8
core context + cancels
...
Erroring out in core setup should cancel the context
to ensure subsystems are shut down. This has to happen
all over the place we use contexts.
@perfmode @whyrusleeping
2014-09-30 03:22:30 -07:00
Juan Batiz-Benet
f2db4b77ac
don't load identity in offline mode (temp)
...
**For now**, we don't need to load/parse the private key
(which causes a signficant delay in commands) when doing
things entirely offline. This may change, and in that case
the private key should be loaded on demand.
2014-09-30 03:22:29 -07:00
Jeromy
9c221719f9
switch over to using a lock file for daemon connections
2014-09-30 03:20:15 -07:00
Jeromy
727b6bf9a3
udpated commands and RPC dialing to work with new configuration changes
2014-09-27 16:02:50 -07:00
Juan Batiz-Benet
e6b96b9c75
ammend tests with changes
2014-09-26 02:41:46 -07:00
Juan Batiz-Benet
53f0b117f5
update net with peerstore
2014-09-26 02:41:46 -07:00
Juan Batiz-Benet
303ebd894d
config: changed language from Peers to Bootstrap
2014-09-24 05:31:25 -07:00
Juan Batiz-Benet
193aebc4c0
config: rename addresses
...
WARNING: change breaks old configs.
@whyrusleeping @perfmode
This commit changes the way addresses are stored in config files.
It lumps Identity.Address and RPCAddress into Addresses. This
commit also fixes several golint issues.
2014-09-24 05:28:35 -07:00
Brian Tiger Chow
9d7ae40003
feat(bitswap) expose ability to toggle "niceness"
...
true -> always send to peer
false -> use ledger-based strategy described in IPFS paper draft 3
2014-09-22 04:06:19 -07:00
Brian Tiger Chow
b5ea124a76
style(bitswap) swap argument order
2014-09-22 04:06:18 -07:00
Juan Batiz-Benet
8d29a3255f
core bugfix -- connect ctx
2014-09-22 04:06:18 -07:00
Juan Batiz-Benet
8c35988b8d
add bootstrap peers to peerstore.
2014-09-22 04:06:17 -07:00
Juan Batiz-Benet
b30dd47aa3
Peerstore fix (ptr to iface)
2014-09-22 04:06:17 -07:00
Juan Batiz-Benet
64ba4cd0df
output + linting
2014-09-22 04:06:17 -07:00
Juan Batiz-Benet
da20887e76
ipfs add should output hash to user
...
for now, ipfs add output format:
added <hash> <path>
...
(these commands will adhere to strict formats.)
2014-09-22 04:06:17 -07:00
Juan Batiz-Benet
74a0aa54ad
fixed [%s] bug
2014-09-22 04:06:17 -07:00
Brian Tiger Chow
0c67019447
style(exch:bitswap) rename adapter, session, etc.
...
style(exch:bitswap) rename NetMessage adapter impl
2014-09-22 04:06:14 -07:00
Brian Tiger Chow
e1fe4f6d60
refac(exchange) rename exchange.Interface to match golang conventions
...
examples:
http://golang.org/pkg/container/heap/#Interface
http://golang.org/pkg/net/#Interface
http://golang.org/pkg/sort/#Interface
2014-09-22 04:06:13 -07:00
Brian Tiger Chow
fd086b9c48
refac(exchange) bitswap -> exchange/bitswap
...
Move go-ipfs/bitswap package to go-ipfs/exchange/bitswap
* Delineates the difference between the generic exchange interface and
implementations (eg. BitSwap protocol)
Thus, the bitswap protocol can be refined without having to overthink
how future exchanges will work. Aspects common to BitSwap and other
exchanges can be extracted out to the exchange package in piecemeal.
Future exchange implementations can be placed in sibling packages next
to exchange/bitswap. (eg. exchange/multilateral)
2014-09-22 04:06:13 -07:00
Juan Batiz-Benet
4284e8e960
config: use PeerID in bootstrap config
2014-09-22 04:06:12 -07:00
Brian Tiger Chow
b77a785cd8
fix(dht) remove deprecated Start() call
2014-09-22 04:05:22 -07:00
Brian Tiger Chow
547f9e1cf6
fix(core) patiently convince the core to compile
...
=)
2014-09-22 04:05:21 -07:00
Juan Batiz-Benet
e4e021085b
add Peerstore to dht
2014-09-22 04:05:19 -07:00
Juan Batiz-Benet
70ea4f540c
added peerstore to core
2014-09-22 04:05:19 -07:00
Brian Tiger Chow
fda94d9f34
refactor(bitswap) rm SetStrategy method
...
remove this setter while the interface is under construction
2014-09-22 04:05:18 -07:00
Juan Batiz-Benet
27d0e692ed
core dht setup
2014-09-22 04:05:16 -07:00
Brian Tiger Chow
dde6ad495e
todo(blockservice, core) add notes
...
* to wrap datastore for ease of use
* to pass a non-responsive bitswap mock rather than performing nil
* checks internally
2014-09-22 04:05:16 -07:00
Brian Tiger Chow
ab460ed882
refactor(bs, core) rename bitswap objects
2014-09-22 04:05:15 -07:00
Brian Tiger Chow
0075a47df0
fix(bs) remove concrete refs to swarm and dht
2014-09-22 04:05:15 -07:00
Brian Tiger Chow
6aecb80395
chore(core) add TODOs to use contexts
2014-09-22 04:05:15 -07:00
Juan Batiz-Benet
c14123397a
starting to integrate new net
2014-09-22 04:05:13 -07:00
Juan Batiz-Benet
67e76c0acc
godeps multiaddr + swarm move.
2014-09-22 04:05:12 -07:00
Juan Batiz-Benet
035d600f28
Godeps: use in net + new multiaddr
2014-09-22 04:05:12 -07:00
Jeromy
9e4b8586a9
Add config flag to cmd line interface
2014-09-17 02:49:36 +00:00
Jeromy
0ec9dce19c
Merge branch 'master' of github.com:jbenet/go-ipfs into daemon
...
Conflicts:
core/core.go
2014-09-14 04:22:05 +00:00
Jeromy
b55a5078a8
refactor daemon code, moved commands to core/commands
2014-09-12 21:29:54 +00:00
Brian Tiger Chow
a5c0f67c8c
fix(config) failing test
...
also replace *Datastore with Datastore
2014-09-12 04:20:46 -07:00
Matt Bell
50d318c0be
core: Updated basic initialization tests
2014-09-11 17:52:21 -07:00
Matt Bell
3ae37b29bd
core: Show error when config identity is not set
2014-09-11 17:50:05 -07:00
Matt Bell
b63e10f3b5
core: Don't require address for node initialization
2014-09-11 17:49:10 -07:00
Matt Bell
7b32c11347
core: Refactored node initialization
2014-09-11 17:22:44 -07:00
Jeromy
8dfb119fa6
Merge branch 'master' of github.com:jbenet/go-ipfs
...
Conflicts:
cmd/ipfs/add.go
cmd/ipfs/cat.go
cmd/ipfs/ls.go
cmd/ipfs/mount_unix.go
2014-09-10 06:28:15 +00:00
Brian Tiger Chow
7968b45e58
vendor dependencies with godep
...
dependencies are vendored into Godeps/_workspace and commit versions are
recorded in Godeps.json
update datastore to e89f0511
update go.crypto
2014-09-09 22:39:42 -07:00
Jeromy
b2a218816d
initial hack at turning ipfs into a daemon, just implemented simple rpc at this point
2014-09-09 05:11:56 +00:00
Jeromy
e6498b3733
fix issue with blocks not being trimmed properly and being too large to be sent over the network
2014-09-05 02:58:31 +00:00
Jeromy
eeab5f9bd9
fix issue with blocks not actually being stored via dagservice
2014-09-04 03:37:29 +00:00
Jeromy
4b97f1f270
create new crypto package and make rest of repo use it
2014-09-03 20:15:10 +00:00
Jeromy
aa5a34a6d1
add init command to generate crypto keys
2014-09-02 12:58:35 -07:00
Jeromy
a5d54ea29e
fix up tests that started failing after changing identify code
2014-09-01 21:55:59 -07:00
Jeromy
45fc43c9cf
add pub/priv key code to identify, not complete yet
2014-09-01 16:09:03 -07:00
Jeromy
ddd2a9aee5
fix core package test
2014-08-30 12:54:59 -07:00
Jeromy
c2cc4b1d70
a little cleanup, ipfs 'works' for basic file adds and cats
2014-08-29 17:22:40 -07:00
Jeromy
691d1b36bb
integrate bitswap and blockservice into the core package
2014-08-29 11:34:50 -07:00
Jeromy
cfdf01d58a
bitswap first working commit!
2014-08-26 14:24:51 -07:00
Jeromy
91e4675cbf
basic implementation of bitswap, needs testing/verification that it works
2014-08-24 18:13:05 -07:00
Juan Batiz-Benet
3f97e7e385
goling: PeerId -> ID
2014-07-22 02:28:25 -07:00
Juan Batiz-Benet
f718bd6a92
go lint
...
link errors left:
- protocol buffers output is not lint-friendly
2014-07-22 02:20:08 -07:00
Juan Batiz-Benet
8a07a62643
added path resolution
2014-07-06 00:07:04 -07:00
Juan Batiz-Benet
7b98bf80f4
cleaned up interface to use DAG
2014-07-05 23:47:26 -07:00
Juan Batiz-Benet
9f542f8797
abstracted merkledag service
2014-07-05 23:45:35 -07:00
Juan Batiz-Benet
5abf3c2ae9
added ls + recusrive directory adding
2014-07-05 18:19:38 -07:00
Juan Batiz-Benet
3b241486a9
ipfs cat
2014-07-05 17:29:44 -07:00
Juan Batiz-Benet
cd1d4d4455
core block service
2014-07-05 15:38:41 -07:00
Juan Batiz-Benet
56b3dafbd7
ignore testdb
2014-07-05 15:04:04 -07:00
Juan Batiz-Benet
2d7f2473a5
go fmt
2014-07-05 13:21:30 -07:00
Juan Batiz-Benet
2b9d67df81
core construction
2014-07-05 13:21:15 -07:00
Juan Batiz-Benet
3b570d3f82
skeleton.
2014-06-26 01:14:26 -07:00