* Updates go-ipfs-cmds to try to get the tests to pass on travis.
* While we're at it, fix duplicate gx deps.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
Switch _back_ to the 0.4.18 style of peer IDs while we figure things out. See
https://github.com/libp2p/specs/issues/138.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
Primarily, get rid of extractCidString and cidVer. Neither of these functions
did sane things when a path when a path didn't actually include a CID. For
example, "boo" would yield a base32 encoder.
Also:
* Avoid "optional" errors.
* Make it a pure function of the input path.
* Extract the multibase from *any* type of path of the form
/namespace/cid-like-thing/... This is a DWIM function.
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
This does it on ther server side for most commands.
This also adds a global --output-cidv1 option.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
Loading this at the last minute means we need a bunch of special cases
in *every* command that needs routing, namesys, or even the public key.
If we ever have a case where we don't want to do this, we can add an option to
the (eventual) IPFS constructor. Handling this up-front is going to be
significantly less error prone.
Motivation: https://github.com/ipfs/go-ipfs/pull/5825/files#diff-fe35ea64d478c4f3fb767a3f618e5d01R863
License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
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>
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>
* 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>