Skip to content

Latest commit

 

History

History
4057 lines (3501 loc) · 284 KB

v0.4.md

File metadata and controls

4057 lines (3501 loc) · 284 KB

go-ipfs changelog v0.4

v0.4.23 2020-01-29

Given the large number of fixes merged since 0.4.22, we've decided to cut another patch release.

This release contains critical fixes. Please upgrade ASAP. Importantly, we're strongly considering switching to TLS by default in go-ipfs 0.5.0 and dropping SECIO support. However, the current TLS transport in go-ipfs 0.4.22 has a bug that can cause connections to spontaneously disconnect during the handshake.

This release fixes that bug, among many other issues. Users that don't upgrade may experience connectivity issues when the network upgrades to go-ipfs 0.5.0.

Highlights

  • Fixes build on go 1.13
  • Fixes an issue where we may not connect to providers in bitswap.
  • Fixes an issue on the TLS transport where we may abort a handshake unintentionally.
  • Fixes a common panic in the websocket transport.
  • Adds support for recursively resolving dnsaddrs (makes go-ipfs compatible with the new bootstrappers).
  • Fixes several potential panics/crashes.
  • Switches to using pre-defined autorelays instead of trying to find them in the DHT:
    • Avoids selecting random, potentially poor, relays.
    • Avoids spamming the DHT with requests trying to find relays.
    • Reduces the impact of accidentally enabling AutoRelay + RelayHop. I.e., the network won't try to DoS you.
  • Modifies the connection manager to not count connections in the grace period towards the connection limit.
    • Pro: New connections don't cause us to close useful, existing connections.
    • Con: Libp2p will keep more connections. Consider reducing your HighWater after applying this patch.
  • Improved peer usefulness tracking in bitswap. Frequently used peers will be marked as "important" and the connection manager will avoid closing connections to these peers.
  • Includes a new version of the WebUI to fix some issues with the peers map.

Changelog

Other:

Update bloom filter libraries to remove unsound usage of the unsafe package.

Contributors

Contributor Commits Lines ± Files Changed
Steven Allen 52 +1866/-578 102
vyzo 12 +167/-90 22
whyrusleeping 5 +136/-52 7
Roman Proskuryakov 7 +94/-7 10
Jakub Sztandera 3 +58/-13 7
hcg1314 2 +31/-11 2
Raúl Kripalani 2 +7/-33 6
Marten Seemann 3 +27/-10 5
Marcin Rataj 2 +26/-0 5
b5 1 +2/-22 1
Hector Sanjuan 1 +11/-0 1
Yusef Napora 1 +4/-0 1

v0.4.22 2019-08-06

We're releasing a PATCH release of go-ipfs based on 0.4.21 containing some critical fixes.

The IPFS network has scaled to the point where small changes can have a wide-reaching impact on the entire network. To keep this situation from escalating, we've put a hold on releasing new features until we can improve our release process (which we've trialed in this release) and testing procedures.

This release includes fixes for the following regressions:

  1. A major bitswap throughput regression introduced in 0.4.21 (ipfs/go-ipfs#6442).
  2. High bitswap CPU usage when connected to many (e.g. 10,000) peers. See ipfs/go-bitswap#154.
  3. The local network discovery service sometimes initializes before the networking module, causing it to announce the wrong addresses and sometimes complain about not being able to determine the IP address (ipfs/go-ipfs#6415).

It also includes fixes for:

  1. Pins not being persisted after ipfs block add --pin (ipfs/go-ipfs#6441).
  2. Panic due to concurrent map access when adding and listing pins at the same time (ipfs/go-ipfs#6419).
  3. Potential pin-set corruption given a concurrent ipfs repo gc and ipfs pin rm (ipfs/go-ipfs#6444).
  4. Build failure due to a deleted git tag in one of our dependencies (ipfs/go-ds-badger#64).

Thanks to:

v0.4.21 2019-05-30

We're happy to announce go-ipfs 0.4.21. This release has some critical bug fixes and a handful of new features so every user should upgrade.

Key bug fixes:

  • Too many open file descriptors/too many peers (#6237).
  • Adding multiple files at the same time doesn't work (#6254).
  • CPU utilization spikes and then holds at 100% (#5613).

Key features:

  • Experimental TLS1.3 support (to eventually replace secio).
  • OpenSSL support for SECIO handshakes (performance improvement).

IMPORTANT: This release fixes a bug in our security transport that could potentially drop data from the channel. Note: This issue affects neither the privacy nor the integrity of the data with respect to a third-party attacker. Only the peer sending us data could trigger this bug.

ALL USERS MUST UPGRADE. We intended to introduce a feature this release that, unfortunately, reliably triggered this bug. To avoid partitioning the network, we've decided to postpone this feature for a release or two.

Specifically, we're going to provide a minimum one month upgrade period. After that, we'll start testing the impact of deploying the proposed changes.

If you're running the mainline go-ipfs, please upgrade ASAP. If you're building a separate app or working on a forked go-ipfs, make sure to upgrade github.com/libp2p/go-libp2p-secio to at least v0.0.3.

Contributors

First off, we'd like to give a shout-out to all contributors that participated in this release (including contributions to ipld, libp2p, and multiformats):

Contributor Commits Lines ± Files Changed
Steven Allen 220 +6078/-4211 520
Łukasz Magiera 53 +5039/-4557 274
vyzo 179 +2929/-1704 238
Raúl Kripalani 44 +757/-1895 134
hannahhoward 11 +755/-1005 49
Marten Seemann 16 +862/-203 44
keks 10 +359/-110 12
Jan Winkelmann 8 +368/-26 16
Jakub Sztandera 4 +361/-8 7
Adrian Lanzafame 1 +287/-18 5
Erik Ingenito 4 +247/-28 8
Reid 'arrdem' McKenzie 1 +220/-20 3
Yusef Napora 26 +98/-130 26
Michael Avila 3 +116/-59 8
Raghav Gulati 13 +145/-26 13
tg 1 +41/-33 1
Matt Joiner 6 +41/-30 7
Cole Brown 1 +37/-25 1
Dominic Della Valle 2 +12/-40 4
Overbool 1 +50/-0 2
Christopher Buesser 3 +29/-16 10
myself659 1 +38/-5 2
Alex Browne 3 +30/-8 3
jmank88 1 +27/-4 2
Vikram 1 +25/-1 2
MollyM 7 +17/-9 7
Marcin Rataj 1 +17/-1 1
requilence 1 +11/-4 1
Teran McKinney 1 +8/-2 1
Oli Evans 1 +5/-5 1
Masashi Salvador Mitsuzawa 1 +5/-1 1
chenminjian 1 +4/-0 1
Edgar Lee 1 +3/-1 1
Dirk McCormick 1 +2/-2 2
ia 1 +1/-1 1
Alan Shaw 1 +1/-1 1

Bug Fixes And Enhancements

This release includes quite a number of critical bug fixes and performance/reliability enhancements.

Error when adding multiple files

The last release broke the simple command ipfs add file1 file2. It turns out we simply lacked a test case for this. Both of these issues (the bug and the lack of a test case) have now been fixed.

SECIO

As noted above, we've fixed a bug that could cause data to be dropped from a SECIO connection on read. Specifically, this happens when:

  1. The capacity of the read buffer is greater than the length.
  2. The remote peer sent more than the length but less than the capacity in a single secio "frame".

In this case, we'd fill the read buffer to it's capacity instead of its length.

Too many open files, too many peers, etc.

Go-ipfs automatically closes the least useful connections when it accumulates too many connections. Unfortunately, some relayed connections were blocking in Close(), halting the entire process.

Out of control CPU usage

Many users noted out of control CPU usage this release. This turned out to be a long-standing issue with how the DHT handled provider records (records recording which peers have what content):

  1. It wasn't removing provider records for content until the set of providers completely emptied.
  2. It was loading every provider record into memory whenever we updated the set of providers.

Combined, these two issues were trashing the provider record cache, forcing the DHT to repeatedly load and discard provider records.

More Reliable Connection Management

Go-ipfs has a subsystem called the "connection manager" to close the least-useful connections when go-ipfs runs low on resources.

Unfortunately, other IPFS subsystems may learn about connections before the connection manager. Previously, if some IPFS subsystem tried to mark a connection as useful before the connection manager learned about it, the connection manager would discard this information. We believe this was causing #6271. It no longer does that.

Improved Bitswap Connection Management

Bitswap now uses the connection manager to mark all peers downloading blocks as important (while downloading). Previously, it only marked peers from which it was downloading blocks.

Reduced Memory Usage

The most noticeable memory reduction in this release comes from fixing connection closing. However, we've made a few additional improvements:

  • Bitswap's "work queue" no longer remembers every peer it has seen indefinitely.
  • The peerstore now interns protocol names.
  • The per-peer goroutine count has been reduced.
  • The DHT now wastes less memory on idle peers by pooling buffered writers and returning them to the pool when not actively using them.

Increased File Descriptor Limit

The default file descriptor limit has been raised to 8192 (from 2048). Unfortunately, go-ipfs behaves poorly when it runs out of file descriptors and it uses a lot of file descriptors.

Luckily, most modern kernels can handle thousands of file descriptors without any difficulty.

Decreased Connection Handshake Latency

Libp2p now shaves off a couple of round trips when initiating connections by beginning the protocol negotiation before the remote peer responds to the initial handshake message.

In the optimal case (when the target peer speaks our preferred protocol), this reduces the number of handshake round-trips from 6 to 4 (including the TCP handshake).

Commands

This release brings no new commands but does introduce a few changes, bugfixes, and enhancements. This section is hardly complete but it lists the most noticeable changes.

Take note: this release also introduces a few breaking changes.

[DEPRECATION] The URLStore Command Deprecated

The experimental ipfs urlstore command is now deprecated. Please use ipfs add --nocopy URL instead.

[BREAKING] The DHT Command Base64 Encodes Values

When responding to an ipfs dht get command, the daemon now encodes the returned value using base64. The ipfs command will automatically decode this value before returning it to the user so this change should only affect those using the HTTP API directly.

Unfortunately, this change was necessary as DHT records are arbitrary binary blobs which can't be directly stored in JSON strings.

[BREAKING] Base32 Encoded v1 CIDs By Default

Both js-ipfs and go-ipfs now encode CIDv1 CIDs using base32 by default, instead of base58. Unfortunately, base58 is case-sensitive and doesn't play well with browsers (see #4143.

Human Readable Numbers

The ipfs bitswap stat and and ipfs object stat commands now support a --humanize flag that formats numbers with human-readable units (GiB, MiB, etc.).

Improved Errors

This release improves two types of errors:

  1. Commands that take paths/multiaddrs now include the path/multiaddr in the error message when it fails to parse.
  2. ipfs swarm connect now returns a detailed error describing which addresses were tried and why the dial failed.

Ping Improvements

The ping command has received some small improvements and fixes:

  1. It now exits with a non-zero exit status on failure.
  2. It no longer succeeds with zero successful pings if we have a zombie but non-functional connection to the peer being pinged (#6298).
  3. It now prints out the average latency when canceled with ^C (like the unix ping command).

Improved Help Text

Go-ipfs now intelligently wraps help text for easier reading. On an 80 character wide terminal,

Before

USAGE
  ipfs add <path>... - Add a file or directory to ipfs.

SYNOPSIS
  ipfs add [--recursive | -r] [--dereference-args] [--stdin-name=<stdin-name>] [
--hidden | -H] [--quiet | -q] [--quieter | -Q] [--silent] [--progress | -p] [--t
rickle | -t] [--only-hash | -n] [--wrap-with-directory | -w] [--chunker=<chunker
> | -s] [--pin=false] [--raw-leaves] [--nocopy] [--fscache] [--cid-version=<cid-
version>] [--hash=<hash>] [--inline] [--inline-limit=<inline-limit>] [--] <path>
...

ARGUMENTS

  <path>... - The path to a file to be added to ipfs.

OPTIONS

  -r,               --recursive           bool   - Add directory paths recursive
ly.
  --dereference-args                      bool   - Symlinks supplied in argument
s are dereferenced.
  --stdin-name                            string - Assign a name if the file sou
rce is stdin.
  -H,               --hidden              bool   - Include files that are hidden
. Only takes effect on recursive add.
  -q,               --quiet               bool   - Write minimal output.
  -Q,               --quieter             bool   - Write only final hash.
  --silent                                bool   - Write no output.
  -p,               --progress            bool   - Stream progress data.
  -t,               --trickle             bool   - Use trickle-dag format for da
g generation.
  -n,               --only-hash           bool   - Only chunk and hash - do not
write to disk.
  -w,               --wrap-with-directory bool   - Wrap files with a directory o
bject.
  -s,               --chunker             string - Chunking algorithm, size-[byt
es] or rabin-[min]-[avg]-[max]. Default: size-262144.
  --pin                                   bool   - Pin this object when adding.
Default: true.
  --raw-leaves                            bool   - Use raw blocks for leaf nodes
. (experimental).
  --nocopy                                bool   - Add the file using filestore.
 Implies raw-leaves. (experimental).
  --fscache                               bool   - Check the filestore for pre-e
xisting blocks. (experimental).
  --cid-version                           int    - CID version. Defaults to 0 un
less an option that depends on CIDv1 is passed. (experimental).
  --hash                                  string - Hash function to use. Implies
 CIDv1 if not sha2-256. (experimental). Default: sha2-256.
  --inline                                bool   - Inline small blocks into CIDs
. (experimental).
  --inline-limit                          int    - Maximum block size to inline.
 (experimental). Default: 32.

After

USAGE
  ipfs add <path>... - Add a file or directory to ipfs.

SYNOPSIS
  ipfs add [--recursive | -r] [--dereference-args] [--stdin-name=<stdin-name>]
           [--hidden | -H] [--quiet | -q] [--quieter | -Q] [--silent]
           [--progress | -p] [--trickle | -t] [--only-hash | -n]
           [--wrap-with-directory | -w] [--chunker=<chunker> | -s] [--pin=false]
           [--raw-leaves] [--nocopy] [--fscache] [--cid-version=<cid-version>]
           [--hash=<hash>] [--inline] [--inline-limit=<inline-limit>] [--]
           <path>...

ARGUMENTS

  <path>... - The path to a file to be added to ipfs.

OPTIONS

  -r, --recursive            bool   - Add directory paths recursively.
  --dereference-args         bool   - Symlinks supplied in arguments are
                                      dereferenced.
  --stdin-name               string - Assign a name if the file source is stdin.
  -H, --hidden               bool   - Include files that are hidden. Only takes
                                      effect on recursive add.
  -q, --quiet                bool   - Write minimal output.
  -Q, --quieter              bool   - Write only final hash.
  --silent                   bool   - Write no output.
  -p, --progress             bool   - Stream progress data.
  -t, --trickle              bool   - Use trickle-dag format for dag generation.
  -n, --only-hash            bool   - Only chunk and hash - do not write to
                                      disk.
  -w, --wrap-with-directory  bool   - Wrap files with a directory object.
  -s, --chunker              string - Chunking algorithm, size-[bytes] or
                                      rabin-[min]-[avg]-[max]. Default:
                                      size-262144.
  --pin                      bool   - Pin this object when adding. Default:
                                      true.
  --raw-leaves               bool   - Use raw blocks for leaf nodes.
                                      (experimental).
  --nocopy                   bool   - Add the file using filestore. Implies
                                      raw-leaves. (experimental).
  --fscache                  bool   - Check the filestore for pre-existing
                                      blocks. (experimental).
  --cid-version              int    - CID version. Defaults to 0 unless an
                                      option that depends on CIDv1 is passed.
                                      (experimental).
  --hash                     string - Hash function to use. Implies CIDv1 if
                                      not sha2-256. (experimental). Default:
                                      sha2-256.
  --inline                   bool   - Inline small blocks into CIDs.
                                      (experimental).
  --inline-limit             int    - Maximum block size to inline.
                                      (experimental). Default: 32.

Features

This release is primarily a bug fix release but it still includes two nice features from libp2p.

Experimental TLS1.3 support

Go-ipfs now has experimental TLS1.3 support. Currently, libp2p (IPFS's networking library) uses a custom TLS-like protocol we call SECIO. However, the conventional wisdom concerning custom security transports is "just don't" so we are working on replacing it with TLS1.3

To choose this protocol by default, set the Experimental.PreferTLS config variable:

> ipfs config --bool Experimental.PreferTLS true

Why TLS1.3 and not X (noise, etc.)?

  1. Libp2p allows negotiating transports so there's no reason not to add noise support to libp2p as well.
  2. TLS has wide language support which should make implementing libp2p for new languages significantly simpler.

OpenSSL Support

Go-ipfs can now (optionally) be built with OpenSSL support for improved performance when establishing connections. This is primarily useful for nodes receiving multiple inbound connections per second.

To enable openssl support, rebuild go-ipfs with:

> make build GOTAGS=openssl

CoreAPI

The CoreAPI refactor is still underway and we've made significant progress towards a usable ipfs-as-a-library constructor. Specifically, we've integrated the fx dependency injection system and are now working on cleaning up our initialization logic. This should make it easier to inject new services into a go-ipfs process without messing with the core internals.

Build: GOCC Environment Variable

Build system now uses GOCC environment variable allowing for use of specific go versions during builds.

Changelog

v0.4.20 2019-04-16

We're happy to release go-ipfs 0.4.20. This release includes some critical performance and stability fixes so all users should upgrade ASAP.

This is also the first release to use go modules instead of GX. While GX has been a great way to dogfood an IPFS-based package manager, building and maintaining a custom package manager is a lot of work and we haven't been able to dedicate enough time to bring the user experience of gx to an acceptable level. You can read #5850 for some discussion on this matter.

Docker

As of this release, it's now much easier to run arbitrary IPFS commands within the docker container:

> docker run --name my-ipfs ipfs/go-ipfs:v0.4.20 config profile apply server # apply the server profile
> docker start my-ipfs # start the daemon

This release also reverts a change that caused some significant trouble in 0.4.19. If you've been running into Docker permission errors in 0.4.19, please upgrade.

WebUI

This release contains a major WebUI release with some significant improvements to the file browser and new opt-in, privately hosted, anonymous usage analytics.

Commands

As usual, we've made several changes and improvements to our commands. The most notable changes are listed in this section.

New: ipfs version deps

This release includes a new command, ipfs version deps, to list all dependencies (with versions) of the current go-ipfs build. This should make it easy to tell exactly how go-ipfs was built when tracking down issues.

New: ipfs add URL

The ipfs add command has gained support for URLs. This means you can:

  1. Add files with ipfs add URL instead of downloading the file first.
  2. Replace all uses of the ipfs urlstore command with a call to ipfs add --nocopy. The ipfs urlstore command will be deprecated in a future release.

Changed: ipfs swarm connect

The ipfs swarm connect command has a few new features:

It now marks the newly created connection as "important". This should ensure that the connection manager won't come along later and close the connection if it doesn't think it's being used.

It can now resolve /dnsaddr addresses that don't end in a peer ID. For example, you can now run ipfs swarm connect /dnsaddr/bootstrap.libp2p.io to connect to one of the bootstrap peers at random. NOTE: This could connect you to an arbitrary peer as DNS is not secure (by default). Please do not rely on this except for testing or unless you know what you're doing.

Finally, ipfs swarm connect now returns all errors on failure. This should make it much easier to debug connectivity issues. For example, one might see an error like:

Error: connect QmYou failure: dial attempt failed: 6 errors occurred:
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip4/127.0.0.1/tcp/4001) dial attempt failed: dial tcp4 127.0.0.1:4001: connect: connection refused
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip6/::1/tcp/4001) dial attempt failed: dial tcp6 [::1]:4001: connect: connection refused
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip6/2604::1/tcp/4001) dial attempt failed: dial tcp6 [2604::1]:4001: connect: network is unreachable
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip6/2602::1/tcp/4001) dial attempt failed: dial tcp6 [2602::1]:4001: connect: network is unreachable
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip4/150.0.1.2/tcp/4001) dial attempt failed: dial tcp4 0.0.0.0:4001->150.0.1.2:4001: i/o timeout
	* <peer.ID Qm*Me> --> <peer.ID Qm*You> (/ip4/200.0.1.2/tcp/4001) dial attempt failed: dial tcp4 0.0.0.0:4001->200.0.1.2:4001: i/o timeout

Changed: ipfs bitswap stat

ipfs bitswap stat no longer lists bitswap partners unless the -v flag is passed. That is, it will now return:

> ipfs bitswap stat
bitswap status
	provides buffer: 0 / 256
	blocks received: 0
	blocks sent: 79
	data received: 0
	data sent: 672706
	dup blocks received: 0
	dup data received: 0 B
	wantlist [0 keys]
	partners [197]

Instead of:

> ipfs bitswap stat -v
bitswap status
	provides buffer: 0 / 256
	blocks received: 0
	blocks sent: 79
	data received: 0
	data sent: 672706
	dup blocks received: 0
	dup data received: 0 B
	wantlist [0 keys]
	partners [203]
		QmNQTTTRCDpCYCiiu6TYWCqEa7ShAUo9jrZJvWngfSu1mL
		QmNWaxbqERvdcgoWpqAhDMrbK2gKi3SMGk3LUEvfcqZcf4
		QmNgSVpgZVEd41pBX6DyCaHRof8UmUJLqQ3XH2qNL9xLvN
        ... omitting 200 lines ...

Changed: ipfs repo stat --human

The --human flag in the ipfs repo stat command now intelligently picks a size unit instead of always using MiB.

Changed: ipfs resolve (ipfs dns, ipfs name resolve)

All of the resolve commands now:

  1. Resolve recursively (up to 32 steps) by default to better match user expectations (these commands used to be non-recursive by default). To turn recursion off, pass -r false.
  2. When resolving non-recursively, these commands no longer fail when partially resolving a name. Instead, they simply return the intermediate result.

Changed: ipfs files flush

The ipfs files flush command now returns the CID of the flushed file.

Performance And Reliability

This release has the usual collection of performance and reliability improvements.

Badger Memory Usage

Those of you using the badger datastore should notice reduced memory usage in this release due to some upstream changes. Badger still uses significantly more memory than the default datastore configuration but this will hopefully continue to improve.

Bitswap

We fixed some critical CPU utilization regressions in bitswap for this release. If you've been noticing CPU regressions in go-ipfs 0.4.19, especially when running a public gateway, upgrading to 0.4.20 will likely fix them.

Relays

After AutoRelay was introduced in go-ipfs 0.4.19, the number of peers connecting through relays skyrocketed to over 120K concurrent peers. This highlighted some performance issues that we've now fixed in this release. Specifically:

  • We've significantly reduced the amount of memory allocated per-peer.
  • We've fixed a bug where relays might, in rare cases, try to actively dial a peer to relay traffic. By default, relays only forward traffic between peers already connected to the relay.
  • We've fixed quite a number of performance issues that only show up when rapidly forming new connections. This will actually help all nodes but will especially help relays.

If you've enabled relay hop (Swarm.EnableRelayHop) in go-ipfs 0.4.19 and it hasn't burned down your machine yet, this release should improve things significantly. However, relays are still under heavy load so running an open relay will continue to be resource intensive.

We're continuing to investigate this issue and have a few more patches on the way that, unfortunately, won't make it into this release.

Panics

We've fixed two notable panics in this release:

  • We've fixed a frequent panic in the DHT.
  • We've fixed an occasional panic in the experimental QUIC transport.

Content Routing

IPFS announces and finds content by sending and retrieving content routing ("provider") records to and from the DHT. Unfortunately, sending out these records can be quite resource intensive.

This release has two changes to alleviate this: a reduced number of initial provide workers and a persistent provider queue.

We've reduced the number of parallel initial provide workers (workers that send out provider records when content is initially added to go-ipfs) from 512 to 6. Each provide request (currently, due to some issues in our DHT) tries to establish hundreds of connections, significantly impacting the performance of go-ipfs and crashing some routers.

We've introduced a new persistent provider queue for files added via ipfs add and ipfs pin add. When new directory trees are added to go-ipfs, go-ipfs will add the root/final CID to this queue. Then, in the background, go-ipfs will walk the queue, sequentially sending out provider records for each CID.

This ensures that root CIDs are sent out as soon as possible and are sent even when files are added when the go-ipfs daemon isn't running.

By example, let's add a directory tree to go-ipfs:

> # We're going to do this in "online" mode first so let's start the daemon.
> ipfs daemon &
...
Daemon is ready
> # Now, we're going to create a directory to add.
> mkdir foo
> for i in {0..1000}; do echo do echo $i > foo/$i; done
> # finally, we're going to add it.
> ipfs add -r foo
added QmUQcSjQx2bg4cSe2rUZyQi6F8QtJFJb74fWL7D784UWf9 foo/0
...
added QmQac2chFyJ24yfG2Dfuqg1P5gipLcgUDuiuYkQ5ExwGap foo/990
added QmQWwz9haeQ5T2QmQeXzqspKdowzYELShBCLzLJjVa2DuV foo/991
added QmQ5D4MtHUN4LTS4n7mgyHyaUukieMMyCfvnzXQAAbgTJm foo/992
added QmZq4n4KRNq3k1ovzxJ4qdQXZSrarfJjnoLYPR3ztHd7EY foo/993
added QmdtrsuVf8Nf1s1MaSjLAd54iNqrn1KN9VoFNgKGnLgjbt foo/994
added QmbstvU9mnW2hsE94WFmw5WbrXdLTu2Sf9kWWSozrSDscL foo/995
added QmXFd7f35gAnmisjfFmfYKkjA3F3TSpvUYB9SXr6tLsdg8 foo/996
added QmV5BxS1YQ9V227Np2Cq124cRrFDAyBXNMqHHa6kpJ9cr6 foo/997
added QmcXsccUtwKeQ1SuYC3YgyFUeYmAR9CXwGGnT3LPeCg5Tx foo/998
added Qmc4mcQcpaNzyDQxQj5SyxwFg9ZYz5XBEeEZAuH4cQirj9 foo/999
added QmXpXzUhcS9edmFBuVafV5wFXKjfXkCQcjAUZsTs7qFf3G foo

In 0.4.19, we would have sent out provider records for files foo/{0..1000} before sending out a provider record for foo. If you were ask a friend to download /ipfs/QmUQcSjQx2bg4cSe2rUZyQi6F8QtJFJb74fWL7D784UWf9, they would (baring other issues) be able to find it pretty quickly as this is the first CID you'll have announced to the network. However, if you ask your friend to download /ipfs/QmXpXzUhcS9edmFBuVafV5wFXKjfXkCQcjAUZsTs7qFf3G/0, they'll have to wait for you to finish telling the network about every file in foo first.

In 0.4.20, we immediately tell the network about QmXpXzUhcS9edmFBuVafV5wFXKjfXkCQcjAUZsTs7qFf3G (the foo directory) as soon as we finish adding the directory to go-ipfs without waiting to finish announcing foo/{0..1000}. This is especially important in this release because we've drastically reduced the number of provide workers.

The second benefit is that this queue is persistent. That means go-ipfs won't forget to send out this record, even if it was offline when the content was initially added. NOTE: go-ipfs does continuously re-send provider records in the background twice a day, it just might be a while before it gets around to sending one out any specific one.

Bitswap

Bitswap now periodically re-sends its wantlist to connected peers. This should help work around some race conditions we've seen in bitswap where one node wants a block but the other doesn't know for some reason.

You can track this issue here: ipfs#5183.

Improved NAT Traversal

While NATs are still p2p enemy #1, this release includes slightly improved support for traversing them.

Specifically, this release now:

  1. Better detects the "gateway" NAT, even when multiple devices on the network claim to be NATs.
  2. Better guesses the external IP address when port mapping, even when the gateway lies.

Reduced AutoRelay Boot Time

The experimental AutoRelay feature can now detect NATs much faster as we've reduced initial NAT detection delay to 15 seconds. There's still room for improvement but this should make nodes that have enabled this feature dialable earlier on start.

Changelogs

v0.4.19 2019-03-01

We're happy to announce go 0.4.19. This release contains a bunch of important fixes and a slew of new and improved features. Get pumped and upgrade ASAP to benefit from all the new goodies! 🎁

Features

🔌 Initializing With Random Ports

Go-ipfs can now be configured to listen on a random but stable port (across restarts) using the new randomports configuration profile. This should be helpful when testing and/or running multiple go-ipfs instances on a single machine.

To initialize a go-ipfs instance with a randomly chosen port, run:

> ipfs init --profile=randomports

👂 Gateway Directory Listing

IPNS (and/or DNSLink) directory listings on the gateway, e.g. https://ipfs.io/ipns/dist.ipfs.tech/go-ipfs/, will now display the ipfs hash of the current directory. This way users can more easily create permanent links to otherwise mutable data.

📡 AutoRelay and AutoNAT

This release introduces two new experimental features (courtesy of libp2p): AutoRelay and AutoNAT.

AutoRelay is a new service that automatically chooses a public relay when it detects that the go-ipfs node is behind a NAT. While relaying connections through a third-party node isn't the most efficient way to route around NATs, it's a reliable fallback.

To enable AutoRelay, set the Swarm.EnableAutoRelay option in the config.

AutoNAT is the service AutoRelay uses to detect if the node is behind a NAT. You don't have to set any special config flags to enable it.

In this same config section, you may also notice options like EnableRelayHop, EnableAutoNATService, etc. You do not need to enable these:

  • EnableRelayHop -- Allow other nodes to use your node as a relay (disabled by default).
  • EnableAutoNATService -- Help other nodes detect if they're behind a NAT (disabled by default).

📵 Offline Operation

There are two new "offline" features in this release: a global --offline flag and an option to configure the gateway to not fetch files.

Most go-ipfs commands now support the --offline flag. This causes IPFS to avoid network operations when performing the requested operation. If you've ever used the --local flag, the --offline flag is the (almost) universally supported replacement.

For example:

  • If the daemon is started with ipfs daemon --offline, it won't even connect to the network. (note: this feature isn't new, just an example).
  • ipfs add --offline some_file won't send out provider records.
  • ipfs cat --offline Qm... won't fetch any blocks from the network.
  • ipfs block stat --offline Qm... is a great way to tell if a block is locally available.

Note: It doesn't yet work with the refs, urlstore, or tar commands (#6002).

On to the gateway, there's a new Gateway.NoFetch option to configure the gateway to only serve locally present files. This makes it possible to run an IPFS node as a gateway to serve content of your choosing without acting like a public proxy. 🤫

📍 Adding And Pinning Content

There's a new --pin flag for both ipfs block put and ipfs urlstore add to match the --pin flag in ipfs add. This allows one to atomically add and pin content with these APIs.

NOTE 1: For ipfs urlstore add, --pin has been enabled by default to match the behavior in ipfs add. However, ipfs block put does not pin by default to match the current behavior.

NOTE 2: If you had previously used the urlstore and weren't explicitly pinning content after adding it, it isn't pinned and running the garbage collector will delete it. While technically documented in the ipfs urlstore add helptext, this behavior was non-obvious and bears mentioning.

🗂 File Listing

The ipfs ls command has two significant changes this release: it reports file sizes instead of dag sizes and has gained a new --stream flag.

First up, ipfs ls now reports file sizes instead of dag sizes. Previously, for historical reasons, ipfs ls would report the size of a file/directory as seen by IPFS including all the filesystem datastructures and metadata. However, this meant that ls -l and ipfs ls would print different sizes:

> ipfs ls /ipfs/QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv

QmZTR5bcpQD7cFgTorqxZDYaew1Wqgfbd2ud9QqGPAkK2V 1688 about
QmYCvbfNbCwFR45HiNP45rwJgvatpiW38D961L5qAhUM5Y 200  contact
QmY5heUM5qgRubMDD1og9fhCPA6QdkMp3QCwd4s7gJsyE7 322  help
QmejvEPop4D7YUadeGqYWmZxHhLc4JBUCzJJHWMzdcMe2y 12   ping
QmXgqKTbzdh83pQtKFb19SpMCpDDcKR2ujqk3pKph9aCNF 1692 quick-start
QmPZ9gcCEpqKTo6aq61g2nXGUhM4iCL3ewB6LDXZCtioEB 1102 readme
QmQ5vhrL7uv6tuoN9KeVBwd4PwfQkXdVVmDLUZuTNxqgvm 1173 security-notes

> ipfs get /ipfs/QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv
Saving file(s) to QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv
 6.39 KiB / 6.39 KiB [================================] 100.00% 0s

> ls -l QmS4ustL54uo8FzR9455qaxZwuMiUhyvMcX9Ba8nUH4uVv
total 28
-rw------- 1 user group 1677 Feb 14 17:03 about
-rw------- 1 user group  189 Feb 14 17:03 contact
-rw------- 1 user group  311 Feb 14 17:03 help
-rw------- 1 user group    4 Feb 14 17:03 ping
-rw------- 1 user group 1681 Feb 14 17:03 quick-start
-rw------- 1 user group 1091 Feb 14 17:03 readme
-rw------- 1 user group 1162 Feb 14 17:03 security-notes

This is now no longer the case. ipfs ls and ls -l now return the same sizes. 🙌

Second up, ipfs ls now has a new --stream flag. In IPFS, very large directories (e.g., Wikipedia) are split up into multiple chunks (shards) as there are too many entries to fit in a single block. Unfortunately, ipfs ls buffers the entire file list in memory and then sorts it. This means that ipfs ls /ipfs/QmXoypizjW3WknFiJnKLwHCnL72vedxjQkDDP1mXWo6uco/wiki (wikipedia) will take a very long time to return anything (it'll also use quite a bit of memory).

However, the new --stream flag makes it possible to stream a directory listing as new chunks are fetched from the network. To test this, you can run ipfs ls --stream --size=false --resolve-type=false /ipfs/QmXoypizjW3WknFiJnKLwHCnL72vedxjQkDDP1mXWo6uco/wiki. You probably won't want to wait for that command to finish, Wikipedia has a lot of entries. 😉

🔁 HTTP Proxy

This release sees a new (experimental) feature contributed by our friends at Peergos: HTTP proxy over libp2p. When enabled, the local gateway can act as an HTTP proxy and forward HTTP requests to libp2p peers. When combined with the ipfs p2p command, users can use this to expose HTTP services to other go-ipfs nodes via their gateways. For details, check out the documentation.

Performance And Reliability

This release introduces quite a few performance/reliability improvements and, as usual, fixes several memory leaks. Below is a non-exhaustive list of noticeable changes.

📞 DHT

This release includes an important DHT fix that should significantly:

  1. Reduce dialing.
  2. Speed up DHT queries.
  3. Improve performance of the gateways.

Basically, in the worst case, a DHT query would turn into a random walk of the entire IPFS network. Yikes!

Relevant PR: libp2p/go-libp2p-kad-dht#237

🕸 Bitswap

Bitswap sessions have improved and are now used for all requests. Sessions allow us to group related content and ask peers most likely to have the content instead of broadcasting the request to all connected peers. This gives us two significant benefits:

  1. Less wasted upload bandwidth. Instead of broadcasting which blocks we want to everyone, we can ask fewer peers thus reducing the number of requests we send out.
  2. Less wasted download bandwidth. Because we know which peers likely have content, we can ask an individual peer for a block and expect to get an answer. In the past, we'd ask every peer at the same time to optimize for latency at the expense of bandwidth (getting the same block from multiple peers). We had to do this because we had to assume that most peers didn't have the requested block.

‼️ Pubsub

This release includes some significant reliability improvements in pubsub subscription handling. If you've previously had issues with connected pubsub peers not seeing each-other's messages, please upgrade ASAP.

♻️ Reuseport

In this release, we've rewritten our previously error-prone go-reuseport library to not duplicate a significant portion of Go's low-level networking code. This was made possible by Go's new Control net.Dialer option.

In the past, our first suggestion to anyone experiencing weird resource or connectivity issues was to disable REUSEPORT (set IPFS_REUSEPORT to false). This should no longer be necessary.

🐺 Badger Datastore

Badger has reached 1.0. This release brings an audit and numerous reliability fixes. We are now reasonably confident that badger will become the default datastore in a future release. 👍

This release also adds a new Truncate configuration option for the badger datastore (enabled by default for new IPFS nodes). When enabled, badger will delete any un-synced data on start instead of simply refusing to start. This should be safe on all filesystems where the sync operation is safe and removes the need for manual intervention when restarting an IPFS node after a crash.

Assuming you initialized your badger repo with ipfs init --profile=badgerds, you can enable truncate on an existing repo by running: ipfs config --json "Datastore.Spec.child.truncate" true.

Refactors and Endeavors

🕹 Commands Library

The legacy commands library shim has now been completely removed. This won't mean much for many users but the go-ipfs team is happy to have this behind them.

🌐 Base32 CIDs

This release can now encode CIDs in responses in bases other than base58. This is primarily useful for web-browser integration as it allows us to (a) encode CIDs in a lower-case base (e.g., base32) and then use them in the origin part of URLs. The take away is: this release brings us a step closer to better browser integration.

Specifically, this release adds two flags:

  1. --cid-base: When specified, the IPFS CLI will encode all CIDv1 CIDs using the requested base.
  2. --upgrade-cidv0-in-output: When specified, the IPFS CLI will upgrade CIDv0 CIDs to CIDv1 CIDs when returning them to the user. This upgrade is necessary because CIDv0 doesn't support multibase however, it's off by default as it changes the binary representation of the CIDs (which could have unintended consequences).

🎛 CoreAPI

The work on the CoreAPI refactor (ipfs/go-ipfs#4498) has progressed leaps and bounds this release. The CoreAPI is a comprehensive programmatic interface designed to allow go-ipfs be used as a daemon or a library interchangeably.

As of this release, go-ipfs now has:

  • External interface definitions in ipfs/interface-go-ipfs-core.
  • A work-in-progress implementation (ipfs/go-ipfs-http-client) of these interfaces that uses the IPFS HTTP API. This will replace the (ipfs/go-ipfs-api) library.
  • A new plugin type "Daemon". Daemon plugins are started and stopped along with the go-ipfs daemon and are instantiated with a copy of the CoreAPI. This allows them to control and extend the go-ipfs daemon from within the daemon itself.

The next steps are:

  1. Finishing the remaining API surface area. At the moment, the two key missing parts are:
  2. Config manipulation.
  3. The ipfs files API.
  4. Finalizing the ipfs/go-ipfs-http-client implementation.
  5. Creating a simple way to construct and initialize a go-ipfs node when using go-ipfs as a library.

Changelogs

v0.4.18 2018-10-26

This is probably one of the largest go-ipfs releases in recent history, 3 months in the making.

Features

The headline features this release are experimental QUIC support, the gossipsub pubsub routing algorithm, pubsub message signing, and a refactored ipfs p2p command. However, that's just scratching the surface.

QUIC

First up, on the networking front, this release has also introduced experimental support for the QUIC protocol. QUIC is a new UDP-based network transport that solves many of the long standing issues with TCP.

For us, this means (eventually):

  • Fewer local resources. TCP requires a file-descriptor per connection while QUIC (and most UDP based transports) can share a single file descriptor between all connections. This should allow us to dial faster and keep more connections open.
  • Faster connection establishment. When client authentication is included, QUIC has a three-way handshake like TCP. However, unlike TCP, this handshake brings us from all the way from 0 to a fully encrypted, authenticated, and multiplexed connection. In theory (not yet in practice), this should significantly reduce the latency of DHT queries.
  • Behaves better on lossy networks. When multiplexing multiple requests over a single TCP connection, a single dropped packet will bring the entire connection to a halt while the packet is re-transmitted. However, because QUIC handles multiplexing internally, dropping a single packets affects only the related stream.
  • Better NAT traversal. TL;DR: NAT hole-punching is significantly easier and, in many cases, more reliable with UDP than with TCP.

However, we still have a long way to go. While we encourage users to test this, the IETF QUIC protocol is still being actively developed and will change. You can find instructions for enabling it here.

Pubsub

In terms of pubsub, go-ipfs now supports the gossipsub routing algorithm and message signing.

The gossipsub routing algorithm is significantly more efficient than the current floodsub routing algorithm. Even better, it's fully backwards compatible so you can enable it and still talk to nodes using the floodsub algorithm. You can find instructions to enable gossipsub in go-ipfs here.

Messages are now signed by their authors. While signing has now been enabled by default, strict signature verification has not been and will not be for at least one release (probably multiple) to avoid breaking existing applications. You can read about how to configure this feature here.

Commands

In terms of new toys, this release introduces a new ipfs cid subcommand for working with CIDs, a completely refactored ipfs p2p command, streaming name resolution, and complete inline block support.

The new ipfs cid command allows users to both inspect CIDs and convert them between various formats and versions. For example:

# Print out the CID metadata (prefix)
> ipfs cid format -f %P QmT78zSuBmuS4z925WZfrqQ1qHaJ56DQaTfyMUF7F8ff5o
cidv0-protobuf-sha2-256-32

# Get the hex sha256 hash from the CID.
> ipfs cid format -b base16 -f '0x%D' QmT78zSuBmuS4z925WZfrqQ1qHaJ56DQaTfyMUF7F8ff5o
0x46d44814b9c5af141c3aaab7c05dc5e844ead5f91f12858b021eba45768b4c0e

# Convert a base58 v0 CID to a base32 v1 CID.
> ipfs cid base32 QmT78zSuBmuS4z925WZfrqQ1qHaJ56DQaTfyMUF7F8ff5o
bafybeicg2rebjoofv4kbyovkw7af3rpiitvnl6i7ckcywaq6xjcxnc2mby

The refactored ipfs p2p command allows forwarding TCP streams through two IPFS nodes from one host to another. It's ssh -L but for IPFS. You can find documentation here. It's still experimental but we don't expect too many breaking changes at this point (it will very likely be stabilized in the next release). Quick summary of breaking changes:

  • We don't stop listening for local (forwarded) connections after accepting a single connection.
  • ipfs p2p stream ls output now returns more useful output, first address is always the initiator address.
  • ipfs p2p listener ls is renamed to ipfs p2p ls
  • ipfs p2p listener close is renamed to ipfs p2p close
  • Protocol names have to be prefixed with /x/ and are now just passed to libp2p as handler name. Previous version did this 'under the hood' and with /p2p/ prefix. There is a --allow-custom-protocol flag which allows you to use any libp2p handler name.
  • ipfs p2p listener open and ipfs p2p stream dial got renamed:
    • ipfs p2p listener open p2p-test /ip4/127.0.0.1/tcp/10101 new becomes ipfs p2p listen /x/p2p-test /ip4/127.0.0.1/tcp/10101
    • ipfs p2p stream dial $NODE_A_PEERID p2p-test /ip4/127.0.0.1/tcp/10102 is now ipfs p2p forward /x/p2p-test /ip4/127.0.0.1/tcp/10102 /ipfs/$NODE_A_PEERID

There is now a new flag for ipfs name resolve - --stream. When the command is invoked with the flag set, it will start returning results as soon as they are discovered in the DHT and other routing mechanisms. This enables certain applications to start prefetching/displaying data while the discovery is still running. Note that this command will likely return many outdated records before it finding and returning the latest. However, it will always return valid records (even if a bit stale).

Finally, in the previous release, we added support for extracting blocks inlined into CIDs. In this release, we've added support for creating these CIDs. You can now run ipfs add with the --inline flag to inline blocks less than or equal to 32 bytes in length into a CID, instead of writing an actual block. This should significantly reduce the size of filesystem trees with many empty directories and tiny files.

IPNS

You can now publish and resolve paths with namespaces other than /ipns and /ipfs through IPNS. Critically, IPNS can now be used with IPLD paths (paths starting with /ipld).

WebUI

Finally, this release includes the shiny updated webui. You can view it by installing go-ipfs and visiting http://localhost:5001/webui.

Performance

This release includes some significant performance improvements, both in terms of resource utilization and speed. This section will go into some technical details so feel free to skip it if you're just looking for shiny new features.

Resource Utilization

In this release, we've (a) fixed a slow memory leak in libp2p and (b) significantly reduced the allocation load. Together, these should improve both memory and CPU usage.

Datastructures

We've changed two of our most frequently used datastructures, CIDs and Multiaddrs, to reduce allocation load.

First, we now store CIDs encode as strings, instead of decoded in structs (behind pointers). In addition to being more compact, our Cid type is now a valid map key so we no longer have to encode CIDs every time we want to use them in a map/set. Allocations when inserting CIDs into maps/sets was showing up as a significant source of allocations under heavy load so this change should improve memory usage.

Second, we've changed many of our multiaddr parsing/processing/formatting functions to allocate less. Much of our DHT related-work includes processing multiaddrs so this should reduce CPU utilization when heavily using the DHT.

Streams and Yamux

Streams have always plagued us in terms of memory utilization. This was partially solved by introducing the connection manager, keeping our maximum connection count to a reasonable number but they're still a major memory sink.

This release sees two improvements on this front:

  1. A memory leak in identify has been fixed. This was slowly causing us to leak connections (locking up the memory used by the connections' streams).
  2. Yamux streams now use a buffer-pool backed, auto shrinking read buffer. Before, this read buffer would grow to its maximum size (a few megabytes) and never shrink but these buffers now shrink as they're emptied.

Bitswap Performance

Bitswap will now pack multiple small blocks into a single message thanks ipfs/go-bitswap#5. While this won't help when transferring large files (with large blocks), this should help when transferring many tiny files.

Refactors and Endeavors

This release saw yet another commands-library refactor, work towards the CoreAPI, and the first step towards reliable base32 CID support.

Commands Lib

We've completely refactored our commands library (again). While it still needs quite a bit of work, it now requires significantly less boilerplate and should be significantly more robust. The refactor immediately found two broken tests and probably fixed quite a few bugs around properly returning and handling errors.

CoreAPI

CoreAPI is a new way to interact with IPFS from Go. While it's still not final, most things you can do via the CLI or HTTP interfaces, can now be done through the new API.

Currently there is only one implementation, backed by go-ipfs node, and there are plans to start http-api backed one soon. We are also looking into creating RPC interface using this API, which could help performance in some use cases.

You can track progress in ipfs#4498

IPLD paths

We introduced new path type which introduces distinction between IPLD and IPFS (unixfs) paths. From now on paths prefixed with /ipld/ will always use IPLD link traversal and /ipfs/ will use unixfs path resolver, which takes things like shardnig into account.

Note that this is only initial support and there likely are some bugs in how the paths are handled internally, so consider this feature experimental for now.

CIDv1/Base32 Migration

Currently, IPFS is usually used in browsers by browsing to https://SOME_GATEWAY/ipfs/CID/.... There are two significant drawbacks to this approach:

  1. From a browser security standpoint, all IPFS "sites" will live under the same origin (SOME_GATEWAY).
  2. From a UX standpoint, this doesn't feel very "native" (even if the gateway is a local IPFS node).

To fix the security issue, we intend to switch IPFS gateway links https://ipfs.io/ipfs/CID to to https://CID.ipfs.dweb.link. This way, the CID will be a part of the "origin" so each IPFS website will get a separate security origin.

To fix the UX issue, we've been working on adding support for ipfs://CID/... to web browsers through our ipfs-companion add-on and some new, experimental extension APIs from Mozilla. This has the same effect of putting the CID in the URL origin but has the added benefit of looking "native".

Unfortunately, origins must be case insensitive. Currently, most CIDs users see are CIDv0 CIDs (those starting with Qm) which are always base58 encoded and are therefore case-sensitive.

Fortunately, CIDv1 (the latest CID format) supports arbitrary bases using the multibase standard. Unfortunately, IPFS has always treated equivalent CIDv0 and CIDv1 CIDs as distinct. This means that files added with CIDv0 CIDs (the default) can't be looked up using the equivalent CIDv1.

This release makes some significant progress towards solving this issue by introducing two features:

(1) The previous mentioned ipfs cid base32 command for converting CID to a case intensive encoding required by domain names. This command converts a CID to version 1 and encodes it using base32.

(2) A hack to allow locally looking up blocks associated with a CIDv0 CID using the equivalent CIDv1 CID (or the reverse). This hack will eventually be replaced with a multihash indexed blockstore, which is agnostic to both the CID version and multicodec content type.

go-ipfs changelog

Features (i.e., users take heed):

Fixes (i.e., users take note):

Regressions Fixes (fixes for bugs introduced since the last release):

Extractions:

Documentation:

Testing:

Internal:

Cleanup:

related changelogs

Changes to sub-packages go-ipfs depends on. This does not include libp2p or multiformats.

github.com/ipfs/go-log

github.com/ipfs/go-datastore

github.com/ipfs/go-cid

github.com/ipfs/go-ds-flatfs

github.com/ipfs/go-ds-measure

github.com/ipfs/go-ds-leveldb

github.com/ipfs/go-metrics-prometheus

github.com/ipfs/go-metrics-interface

github.com/ipfs/go-ipld-format

github.com/ipfs/go-ipld-cbor

github.com/ipfs/go-ipfs-cmds

github.com/ipfs/go-ipfs-cmdkit

github.com/ipfs/go-ds-badger

github.com/ipfs/go-ipfs-addr

github.com/ipfs/go-ipfs-chunker

github.com/ipfs/go-ipfs-routing

github.com/ipfs/go-ipfs-blockstore

github.com/ipfs/go-ipns

github.com/ipfs/go-bitswap

github.com/ipfs/go-cidutil

github.com/ipfs/go-ipfs-config

github.com/ipfs/go-merkledag

github.com/ipfs/go-mfs

github.com/ipfs/go-path

  • fix: don't dag.Get in ResolveToLastNode when not needed (ipfs/go-path#1)

github.com/ipfs/go-unixfs

v0.4.17 2018-07-27

Ipfs 0.4.17 is a quick release to fix a major performance regression in bitswap (mostly affecting go-ipfs -> js-ipfs transfers). However, while motivated by this fix, this release contains a few other goodies that will excite some users.

The headline feature in this release is urlstore support. Urlstore is a generalization of the filestore backend that can fetch file blocks from remote URLs on-demand instead of storing them in the local datastore.

Additionally, we've added support for extracting inline blocks from CIDs (blocks inlined into CIDs using the identity hash function). However, go-ipfs won't yet create such CIDs so you're unlikely to see any in the wild.

Features:

Changes/Fixes:

Documentation:

General refactorings and internal bug fixes:

v0.4.16 2018-07-13

Ipfs 0.4.16 is a fairly small release in terms of changes to the ipfs codebase, but it contains a huge amount of changes and improvements from the libraries we depend on, notably libp2p.

This release includes small a repo migration to account for some changes to the DHT. It should only take a second to run but, depending on your configuration, you may need to run it manually.

You can run a migration by either:

  1. Selecting "Yes" when the daemon prompts you to migrate.
  2. Running the daemon with the --migrate=true flag.
  3. Manually running the migration.

Libp2p

This version of ipfs contains the changes made in libp2p from v5.0.14 through v6.0.5. In that time, we have made significant changes to the codebase to allow for easier integration of future transports and modules along with the usual performance and reliability improvements. You can find many of these improvements in the libp2p 6.0 release blog post.

The primary motivation for this refactor was adding support for network transports like QUIC that have built-in support for encryption, authentication, and stream multiplexing. It will also allow us to plug-in new security transports (like TLS) without hard-coding them.

For example, our QUIC transport currently works, and can be plugged into libp2p manually (though note that it is still experimental, as the upstream spec is still in flux). Further work is needed to make enabling this inside ipfs easy and not require recompilation.

On the user-visible side of things, we've improved our dialing logic and timeouts. We now abort dials to local subnets after 5 seconds and abort all dials if the TCP handshake takes longer than 5 seconds. This should significantly improve performance in some cases as we limit the number of concurrent dials and slow dials to non-responsive peers have been known to clog the dialer, blocking dials to reachable peers. Importantly, this should improve DHT performance as it tends to spend a disproportional amount of time connecting to peers.

We have also made a few noticeable changes to the DHT: we've significantly improved the chances of finding a value on the DHT, tightened up some of our validation logic, and fixed some issues that should reduce traffic to nodes running in dhtclient mode over time.

Of these, the first one will likely see the most impact. In the past, when putting a value (e.g., an IPNS entry) into the DHT, we'd try to put the value to K peers (where K for us is 20). However, we'd often fail to connect to many of these peers so we'd end up putting the value to significantly fewer than K peers. We now try to put the value to the K peers we can actually connect to.

Finally, we've fixed JavaScript interoperability in go-multiplex, the one stream muxer that both go-libp2p and js-libp2p implement. This should significantly improve go-libp2p and js-libp2p interoperability.

Multiformats

We are also changing the way that people write 'ipfs' multiaddrs. Currently, ipfs multiaddrs look something like /ip4/104.131.131.82/tcp/4001/ipfs/QmaCpDMGvV2BGHeYERUEnRQAwe3N8SzbUtfsmvsqQLuvuJ. However, calling them 'ipfs' multiaddrs is a bit misleading, as this is actually the multiaddr of a libp2p peer that happens to run ipfs. Other protocols built on libp2p right now still have to use multiaddrs that say 'ipfs', even if they have nothing to do with ipfs. Therefore, we are renaming them to 'p2p' multiaddrs. Moving forward, these addresses will be written as: /ip4/104.131.131.82/tcp/4001/p2p/QmaCpDMGvV2BGHeYERUEnRQAwe3N8SzbUtfsmvsqQLuvuJ.

This release adds support for parsing both types of addresses (.../ipfs/... and .../p2p/...) into the same network format, and the network format is remaining exactly the same. A future release will have the ipfs daemon switch to printing out addresses this way once a large enough portion of the network has upgraded.

N.B., these addresses are not related to IPFS file names (/ipfs/Qm...). Disambiguating the two was yet another motivation to switch the protocol name to /p2p/.

IPFS

On the ipfs side of things, we've started embedding public keys inside IPNS records and have enabled the Git plugin by default.

Embedding public keys inside IPNS records allows lookups to be faster as we only need to fetch the record itself (and not the public key separately). It also fixes an issue where DHT peers wouldn't store a record for a peer if they didn't have their public key already. Combined with some of the DHT and dialing fixes, this should improve the performance of IPNS (once a majority of the network updates).

Second, our public builds now include the Git plugin (in past builds, you could add it yourself, but doing so was not easy). With this, ipfs can ingest and operate over Git repositories and commit graphs directly. For more information on this, see the go-ipld-git repo.

Finally, we've included many smaller bugfixes, refactorings, improved documentation, and a good bit more. For the full details, see the changelog below.

v0.4.16-rc3 2018-07-09

v0.4.16-rc2 2018-07-05

v0.4.16-rc1 2018-06-27

v0.4.15 2018-05-09

This release is significantly smaller than the last as much of the work on improving our datastores, and other libraries libp2p has yet to be merged. However, it still includes many welcome improvements.

As with 0.4.12 and 0.4.14 (0.4.13 was a patch), this release has a negative diff-stat. Unfortunately, much of this code isn't actually going away but at least it's being moved out into separate repositories.

Much of the work that made it into this release is under the hood. We've cleaned up some code, extracted several packages into their own repositories, and made some long neglected optimizations (e.g., handling of sharded directories). Additionally, this release includes a bunch of tests for our CLI commands that should help us avoid some of the issues we've seen in the past few releases.

More visibly, thanks to @djdv's efforts, this release includes some significant Windows improvements (with more on the way). Specifically, this release includes better handling of repo lockfiles (no more ipfs repo fsck), stdin command-line support, and, last but not least, IPFS no longer writes random files with scary garbage in the drive root. To read more about future windows improvements, take a look at this blog post.

To better support low-power devices, we've added a low-power config profile. This can be enabled when initializing a repo by running ipfs init with the --profile=lowpower flag or later by running ipfs config profile apply lowpower.

Finally, with this release we have begun distributing self-contained source archives of go-ipfs and its dependencies. This should be a welcome improvement for both packagers and those living in countries with harmonized internet access.

v0.4.14 2018-03-22

Ipfs 0.4.14 is a big release with a large number of improvements and bugfixes. It is also the first release of 2018, and our first release in over three months. The release took longer than expected due to our refactoring and extracting of our commands library. This refactor had two stages. The first round of the refactor disentangled the commands code from core ipfs code, allowing us to move it out into a separate repository. The code was previously very entangled with the go-ipfs codebase and not usable for other projects. The second round of the refactor had the goal of fixing several major issues around streaming outputs, progress bars, and error handling. It also paved the way for us to more easily provide an API over other transports, such as websockets and unix domain sockets. It took a while to flush out all the kinks on such a massive change. We're pretty sure we've got most of them, but if you notice anything weird, please let us know.

Beyond that, we've added a new experimental way to use IPNS. With the new pubsub IPNS resolver and publisher, you can subscribe to updates of an IPNS entry, and the owner can publish out changes in real time. With this, IPNS can become nearly instantaneous. To make use of this, simply start your ipfs daemon with the --enable-namesys-pubsub option, and all IPNS resolution and publishing will use pubsub. Note that resolving an IPNS name via pubsub without someone publishing it via pubsub will result in a fallback to using the DHT. Please give this a try and let us know how it goes!

Memory and CPU usage should see a noticeable improvement in this release. We have spent considerable time fixing excess memory usage throughout the codebase and down into libp2p. Fixes in peer tracking, bitswap allocation, pinning, and many other places have brought down both peak and average memory usage. An upgraded hashing library, base58 encoding library, and improved allocation patterns all contribute to overall lower CPU usage across the board. See the full changelist below for more memory and CPU usage improvements.

This release also brings the beginning of the ipfs 'Core API'. Once finished, the Core API will be the primary way to interact with go-ipfs using go. Both embedded nodes and nodes accessed over the http API will have the same interface. Stay tuned for future updates and documentation.

These are only a sampling of the changes that made it into this release, the full list (almost 100 PRs!) is below.

Finally, I'd like to thank everyone who contributed to this release, whether you're just contributing a typo fix or driving new features. We are really grateful to everyone who has spent their their time pushing ipfs forward.

SECURITY NOTE:

This release of ipfs disallows the usage of insecure hash functions and lengths. Ipfs does not create these insecure objects for any purpose, but it did allow manually creating them and fetching them from other peers. If you currently have objects using insecure hashes in your local ipfs repo, please remove them before updating.

Changes from rc2 to rc3

Changes from rc1 to rc2

v0.4.13 2017-11-16

Ipfs 0.4.13 is a patch release that fixes two high priority issues that were discovered in the 0.4.12 release.

Bugfixes:

v0.4.12 2017-11-09

Ipfs 0.4.12 brings with it many important fixes for the huge spike in network size we've seen this past month. These changes include the Connection Manager, faster batching in ipfs add, libp2p fixes that reduce CPU usage, and a bunch of new documentation.

The most critical change is the 'Connection Manager': it allows an ipfs node to maintain a limited set of connections to other peers in the network. By default (and with no config changes required by the user), ipfs nodes will now try to maintain between 600 and 900 open connections. These limits are still likely higher than needed, and future releases may lower the default recommendation, but for now we want to make changes gradually. The rationale for this selection of numbers is as follows:

  • The DHT routing table for a large network may rise to around 400 peers
  • Bitswap connections tend to be separate from the DHT
  • PubSub connections also generally are another distinct set of peers (including js-ipfs nodes)

Because of this, we selected 600 as a 'LowWater' number, and 900 as a 'HighWater' number to avoid having to clear out connections too frequently. You can configure different numbers as you see fit via the Swarm.ConnMgr field in your ipfs config file. See here for more details.

Disk utilization during ipfs add has been optimized for large files by doing batch writes in parallel. Previously, when adding a large file, users might have noticed that the add progressed by about 8MB at a time, with brief pauses in between. This was caused by quickly filling up the batch, then blocking while it was writing to disk. We now write to disk in the background while continuing to add the remainder of the file.

Other changes in this release have noticeably reduced memory consumption and CPU usage. This was done by optimising some frequently called functions in libp2p that were expensive in terms of both CPU usage and memory allocations. We also lowered the yamux accept buffer sizes which were raised over a year ago to combat a separate bug that has since been fixed.

And finally, thank you to everyone who filed bugs, tested out the release candidates, filed pull requests, and contributed in any other way to this release!

v0.4.11 2017-09-14

Ipfs 0.4.11 is a larger release that brings many long-awaited features and performance improvements. These include new datastore options, more efficient bitswap transfers, greatly improved resource consumption, circuit relay support, ipld plugins, and more! Take a look at the full changelog below for a detailed list of every change.

The ipfs datastore has, until now, been a combination of leveldb and a custom git-like storage backend called 'flatfs'. This works well enough for the average user, but different ipfs usecases demand different backend configurations. To address this, we have changed the configuration file format for datastores to be a modular way of specifying exactly how you want the datastore to be structured. You will now be able to configure ipfs to use flatfs, leveldb, badger, an in-memory datastore, and more to suit your needs. See the new datastore documentation for more information.

Bitswap received some much needed attention during this release cycle. The concept of 'Bitswap Sessions' allows bitswap to associate requests for different blocks to the same underlying session, and from that infer better ways of requesting that data. In more concrete terms, parts of the ipfs codebase that take advantage of sessions (currently, only ipfs pin add) will cause much less extra traffic than before. This is done by making optimistic guesses about which nodes might be providing given blocks and not sending wantlist updates to every connected bitswap partner, as well as searching the DHT for providers less frequently. In future releases we will migrate over more ipfs commands to take advantage of bitswap sessions. As nodes update to this and future versions, expect to see idle bandwidth usage on the ipfs network go down noticeably.

The never ending effort to reduce resource consumption had a few important updates this release. First, the bitswap sessions changes discussed above will help with improving bandwidth usage. Aside from that there are two important libp2p updates that improved things significantly. The first was a fix to a bug in the dial limiter code that was causing it to not limit outgoing dials correctly. This resulted in ipfs running out of file descriptors very frequently (as well as incurring a decent amount of excess outgoing bandwidth), this has now been fixed. Users who previously received "too many open files" errors should see this much less often in 0.4.11. The second change was a memory leak in the DHT that was identified and fixed. Streams being tracked in a map in the DHT weren't being cleaned up after the peer disconnected leading to the multiplexer session not being cleaned up properly. This issue has been resolved, and now memory usage appears to be stable over time. There is still a lot of work to be done improving memory usage, but we feel this is a solid victory.

It is often said that NAT traversal is the hardest problem in peer to peer technology, we tend to agree with this. In an effort to provide a more ubiquitous p2p mesh, we have implemented a relay mechanism that allows willing peers to relay traffic for other peers who might not otherwise be able to communicate with each other. This feature is still pretty early, and currently users have to manually connect through a relay. The next step in this endeavour is automatic relaying, and research for this is currently in progress. We expect that when it lands, it will improve the perceived performance of ipfs by spending less time attempting connections to hard to reach nodes. A short guide on using the circuit relay feature can be found here.

The last feature we want to highlight (but by no means the last feature in this release) is our new plugin system. There are many different workflows and usecases that ipfs should be able to support, but not everyone wants to be able to use every feature. We could simply merge in all these features, but that causes problems for several reasons: first off, the size of the ipfs binary starts to get very large very quickly. Second, each of these different pieces needs to be maintained and updated independently, which would cause significant churn in the codebase. To address this, we have come up with a system that allows users to install plugins to the vanilla ipfs daemon that augment its capabilities. The first of these plugins are a git plugin that allows ipfs to natively address git objects and an ethereum plugin that lets ipfs ingest and operate on all ethereum blockchain data. Soon to come are plugins for the bitcoin and zcash data formats. In the future, we will be adding plugins for other things like datastore backends and specialized libp2p network transports. You can read more on this topic in Plugin docs

In order to simplify its integration with fs-repo-migrations, we've switched the ipfs/go-ipfs docker image from a musl base to a glibc base. For most users this will not be noticeable, but if you've been building your own images based off this image, you'll have to update your dockerfile. We recommend a multi-stage dockerfile, where the build stage is based off of a regular Debian or other glibc-based image, and the assembly stage is based off of the ipfs/go-ipfs image, and you copy build artifacts from the build stage to the assembly stage. Note, if you are using the docker image and see a deprecation message, please update your usage. We will stop supporting the old method of starting the dockerfile in the next release.

Finally, I would like to thank all of our contributors, users, supporters, and friends for helping us along the way. Ipfs would not be where it is without you.

v0.4.10 - 2017-06-27

Ipfs 0.4.10 is a patch release that contains several exciting new features, bugfixes and general improvements. Including new commands, easier corruption recovery, and a generally cleaner codebase.

The ipfs pin command has two new subcommands, verify and update. ipfs pin verify is used to scan the repo for pinned object graphs and check their integrity. Any issues are reported back with helpful error text to make error recovery simpler. This subcommand was added to help recover from datastore corruptions, particularly if using the experimental filestore and accidentally deleting tracked files. ipfs pin update was added to make the task of keeping a large, frequently changing object graph pinned. Previously users had to call ipfs pin rm on the old pin, and ipfs pin add on the new one. The 'new' ipfs pin add call would be very expensive as it would need to verify the entirety of the graph again. The ipfs pin update command takes shortcuts, portions of the graph that were covered under the old pin are assumed to be fine, and the command skips checking them.

Next up, we have finally implemented an ipfs shutdown command so users can shut down their ipfs daemons via the API. This is especially useful on platforms that make it difficult to control processes (Android, for example), and is also useful when needing to shut down a node remotely and you do not have access to the machine itself.

ipfs add has gained a new flag; the --hash flag allows you to select which hash function to use and we have given it the ability to select blake2b-256. This pushes us one step closer to shifting over to using blake2b as the default. Blake2b is significantly faster than sha2-256, and also is conjectured to provide superior security.

We have also finally implemented a very early (and experimental) ipfs p2p. This command and its subcommands will allow you to open up arbitrary streams to other ipfs peers through libp2p. The interfaces are a little bit clunky right now, but shouldn't get in the way of anyone wanting to try building a fully peer to peer application on top of ipfs and libp2p. For more info on this command, to ask questions, or to provide feedback, head over to the feedback issue for the command.

A few other subcommands and flags were added around the API, as well as many other requested improvements. See below for the full list of changes.

v0.4.9 - 2017-04-30

Ipfs 0.4.9 is a maintenance release that contains several useful bugfixes and improvements. Notably, ipfs add has gained the ability to select which CID version will be output. The common ipfs hash that looks like this: QmRjNgF2mRLDT8AzCPsQbw1EYF2hDTFgfUmJokJPhCApYP is a multihash. Multihashes allow us to specify the hashing algorithm that was used to verify the data, but it doesn't give us any indication of what format that data might be. To address that issue, we are adding another couple of bytes to the prefix that will allow us to indicate the format of the data referenced by the hash. This new format is called a Content ID, or CID for short. The previous bare multihashes will still be fully supported throughout the entire application as CID version 0. The new format with the type information will be CID version 1. To give an example, the content referenced by the hash above is "Hello Ipfs!". That same content, in the same format (dag-protobuf) using CIDv1 is zb2rhkgXZVkT2xvDiuUsJENPSbWJy7fdYnsboLBzzEjjZMRoG.

CIDv1 hashes are supported in ipfs versions back to 0.4.5. Nodes running 0.4.4 and older will not be able to load content via CIDv1 and we recommend that they update to a newer version.

There are many other use cases for CIDs. Plugins can be written to allow ipfs to natively address content from any other merkletree based system, such as git, bitcoin, zcash and ethereum -- a few systems we've already started work on.

Aside from the CID flag, there were many other changes as noted below:

v0.4.8 - 2017-03-29

Ipfs 0.4.8 brings with it several improvements, bugfixes, documentation improvements, and the long awaited directory sharding code.

Currently, when too many items are added into a unixfs directory, the object gets too large and you may experience issues. To pervent this problem, and generally make working really large directories more efficient, we have implemented a HAMT structure for unixfs. To enable this feature, run:

ipfs config --json Experimental.ShardingEnabled true

And restart your daemon if it was running.

Note: With this setting enabled, the hashes of any newly added directories will be different than they previously were, as the new code will use the sharded HAMT structure for all directories. Also, nodes running ipfs 0.4.7 and earlier will not be able to access directories created with this option.

That said, please do give it a try, let us know how it goes, and then take a look at all the other cool things added in 0.4.8 below.

v0.4.7 - 2017-03-15

Ipfs 0.4.7 contains several exciting new features! First off, The long awaited filestore feature has been merged, allowing users the option to not have ipfs store chunked copies of added files in the blockstore, pushing to burden of ensuring those files are not changed to the user. The filestore feature is currently still experimental, and must be enabled in your config with:

ipfs config --json Experimental.FilestoreEnabled true

before it can be used. Please see this issue for more details.

Next up, We have merged initial support for ipfs 'Private Networks'. This feature allows users to run ipfs in a mode that will only connect to other peers in the private network. This feature, like the filestore is being released experimentally, but if you're interested please try it out. Instructions for setting it up can be found here.

This release also enables support for the 'mplex' stream muxer by default. This stream multiplexing protocol was available previously via the --enable-mplex-experiment daemon flag, but has now graduated to being 'less experimental' and no longer requires the flag to use it.

Aside from those, we have a good number of bugfixes, perf improvements and new tests. Heres a list of highlights:

v0.4.6 - 2017-02-21

Ipfs 0.4.6 contains several bugfixes related to migrations and also contains a few other improvements to other parts of the codebase. Notably:

v0.4.5 - 2017-02-11

Changes from rc3 to rc4

Changes from rc2 to rc3

Changes from rc1 to rc2

Changes since 0.4.4

v0.4.4 - 2016-10-11

This release contains an important hotfix for a bug we discovered in how pinning works. If you had a large number of pins, new pins would overwrite existing pins. Apart from the hotfix, this release is equal to the previous release 0.4.3.

  • Fix bug in pinsets fanout, and add stress test. (@whyrusleeping, ipfs/go-ipfs#3273)

We published a detailed account of the bug and fix in a blog post.

v0.4.3 - 2016-09-20

There have been no changes since the last release candidate 0.4.3-rc4. \o/

v0.4.3-rc4 - 2016-09-09

This release candidate fixes issues in Bitswap and the ipfs add command, and improves testing. We plan for this to be the last release candidate before the release of go-ipfs v0.4.3.

With this release candidate, we're also moving go-ipfs to Go 1.7, which we expect will yield improvements in runtime performance, memory usage, build time and size of the release binaries.

  • Require Go 1.7. (@whyrusleeping, @Kubuxu, @lgierth, ipfs/go-ipfs#3163)
    • For this purpose, switch Docker image from Alpine 3.4 to Alpine Edge.
  • Fix cancellation of Bitswap wantlist entries. (@whyrusleeping, ipfs/go-ipfs#3182)
  • Fix clearing of active state of Bitswap provider queries. (@whyrusleeping, ipfs/go-ipfs#3169)
  • Fix a panic in the DHT code. (@Kubuxu, ipfs/go-ipfs#3200)
  • Improve handling of Identity field in ipfs config command. (@Kubuxu, @whyrusleeping, ipfs/go-ipfs#3141)
  • Fix explicit adding of symlinked files and directories. (@kevina, ipfs/go-ipfs#3135)
  • Fix bash auto-completion of ipfs daemon --unrestricted-api option. (@lgierth, ipfs/go-ipfs#3159)
  • Introduce a new timeout tool for tests to avoid licensing issues. (@Kubuxu, ipfs/go-ipfs#3152)
  • Improve output for migrations of fs-repo. (@lgierth, ipfs/go-ipfs#3158)
  • Fix info notice of commands taking input from stdin. (@Kubuxu, ipfs/go-ipfs#3134)
  • Bring back a few tests for stdin handling of ipfs cat and ipfs add. (@Kubuxu, ipfs/go-ipfs#3144)
  • Improve sharness tests for ipfs repo verify command. (@whyrusleeping, ipfs/go-ipfs#3148)
  • Improve sharness tests for CORS headers on the gateway. (@Kubuxu, ipfs/go-ipfs#3142)
  • Improve tests for pinning within ipfs files. (@kevina, ipfs/go-ipfs#3151)
  • Improve tests for the automatic raising of file descriptor limits. (@whyrusleeping, ipfs/go-ipfs#3149)

v0.4.3-rc3 - 2016-08-11

This release candidate fixes a panic that occurs when input from stdin was expected, but none was given: ipfs/go-ipfs#3050

v0.4.3-rc2 - 2016-08-04

This release includes bugfixes and fixes for regressions that were introduced between 0.4.2 and 0.4.3-rc1.

  • Regressions
    • Fix daemon panic when there is no multipart input provided over the HTTP API. (@whyrusleeping, ipfs/go-ipfs#2989)
    • Fix ipfs refs --edges not printing edges. (@Kubuxu, ipfs/go-ipfs#3007)
    • Fix progress option for ipfs add defaulting to true on the HTTP API. (@whyrusleeping, ipfs/go-ipfs#3025)
    • Fix erroneous printing of stdin reading message. (@whyrusleeping, ipfs/go-ipfs#3033)
    • Fix panic caused by passing --mount and --offline flags to ipfs daemon. (@Kubuxu, ipfs/go-ipfs#3022)
    • Fix symlink path resolution on windows. (@Kubuxu, ipfs/go-ipfs#3023)
    • Add in code to prevent issue 3032 from crashing the daemon. (@whyrusleeping, ipfs/go-ipfs#3037)

v0.4.3-rc1 - 2016-07-23

This is a maintenance release which comes with a couple of nice enhancements, and improves the performance of Storage, Bitswap, as well as Content and Peer Routing. It also introduces a handful of new commands and options, and fixes a good bunch of bugs.

This is the first Release Candidate. Unless there are vulnerabilities or regressions discovered, the final 0.4.3 release will happen about one week from now.

v0.4.2 - 2016-05-17

This is a patch release which fixes performance and networking bugs in go-libp2p, You should see improvements in CPU and RAM usage, as well as speed of object lookups. There are also a few other nice improvements.

  • Notable Fixes

    • Set a deadline for dialing attempts. This prevents a node from accumulating failed connections. (@whyrusleeping)
    • Avoid unnecessary string/byte conversions in go-multihash. (@whyrusleeping)
    • Fix a deadlock around the yamux stream muxer. (@whyrusleeping)
    • Fix a bug that left channels open, causing hangs. (@whyrusleeping)
    • Fix a bug around yamux which caused connection hangs. (@whyrusleeping)
    • Fix a crash caused by nil multiaddrs. (@whyrusleeping)
  • Enhancements

    • Add NetBSD support. (@erde74)
    • Set Cache-Control: immutable on /ipfs responses. (@kpcyrd)
    • Have ipfs init optionally accept a default configuration from stdin. (@sivachandran)
    • Add ipfs log ls command for listing logging subsystems. (@hsanjuan)
    • Allow bitswap to read multiple messages per stream. (@whyrusleeping)
    • Remove make toolkit_upgrade step. (@chriscool)
  • Documentation

    • Add a debug-guidelines document. (@richardlitt)
    • Update the contribute document. (@richardlitt)
    • Fix documentation of many ipfs commands. (@richardlitt)
    • Fall back to ShortDesc if LongDesc is missing. (@Kubuxu)
  • Removals

    • Remove -f option from ipfs init command. (@whyrusleeping)
  • Bugfixes

    • Fix ipfs object patch argument handling and validation. (@jbenet)
    • Fix ipfs config edit command by running it client-side. (@Kubuxu)
    • Set default value for ipfs refs arguments. (@richardlitt)
    • Fix parsing of incorrect command and argument permutations. (@thomas-gardner)
    • Update Dockerfile to latest go1.5.4-r0. (@chriscool)
    • Allow passing IPFS_LOGGING to Docker image. (@lgierth)
    • Fix dot path parsing on Windows. (@djdv)
    • Fix formatting of ipfs log ls output. (@richardlitt)
  • General Codebase

    • Refactor Makefile. (@kevina)
    • Wire context into bitswap requests more deeply. (@whyrusleeping)
    • Use gx for iptb. (@chriscool)
    • Update gx and gx-go. (@chriscool)
    • Make blocks.Block an interface. (@kevina)
    • Silence check for Docker existance. (@chriscool)
    • Add dist_get script for fetching tools from dist.ipfs.tech. (@whyrusleeping)
    • Add proper defaults to all ipfs commands. (@richardlitt)
    • Remove dead count option from ipfs pin ls. (@richardlitt)
    • Initialize pin mode strings only once. (@chriscool)
    • Add changelog for v0.4.2. (@lgierth)
    • Specify a dist.ipfs.tech hash for tool downloads instead of trusting DNS. (@lgierth)
  • CI

    • Fix t0170-dht sharness test. (@chriscool)
    • Increase timeout in t0060-daemon sharness test. (@Kubuxu)
    • Have CircleCI use make deps instead of gx directly. (@whyrusleeping)

v0.4.1 - 2016-04-25

This is a patch release that fixes a few bugs, and adds a few small (but not insignificant) features. The primary reason for this release is the listener hang bugfix that was shipped in the 0.4.0 release.

  • Features

    • implemented ipfs object diff (@whyrusleeping)
    • allow promises (used in get, refs) to fail (@whyrusleeping)
  • Tool changes

    • Adds 'toolkit_upgrade' to the makefile help target (@achin)
  • General Codebase

    • Use extracted go-libp2p-crypto, -secio, -peer packages (@lgierth)
    • Update go-libp2p (@lgierth)
    • Fix package manifest fields (@lgierth)
    • remove incfusever dead-code (@whyrusleeping)
    • remove a ton of unused godeps (@whyrusleeping)
    • metrics: add prometheus back (@lgierth)
    • clean up dead code and config fields (@whyrusleeping)
    • Add log events when blocks are added/removed from the blockstore (@michealmure)
    • repo: don't create logs directory, not used any longer (@lgierth)
  • Bugfixes

    • fixed ipfs name resolve --local multihash error (@pfista)
    • ipfs patch commands won't return null links field anymore (@whyrusleeping)
    • Make non recursive resolve print the result (@Kubuxu)
    • Output dirs on ipfs add -rn (@noffle)
    • update libp2p dep to fix hanging listeners problem (@whyrusleeping)
    • Fix Swarm.AddrFilters config setting with regard to /ip6 addresses (@lgierth)
    • fix dht command key escaping (@whyrusleeping)
  • Testing

    • Adds tests to make sure 'object patch' writes. (@noffle)
    • small sharness test for promise failure checking (@whyrusleeping)
    • sharness/Makefile: clean all BINS when cleaning (@chriscool)
  • Documentation

    • Fix disconnect argument description (@richardlitt)
    • Added a note about swarm disconnect (@richardlitt)
    • Also fixed syntax for comment (@richardlitt)
    • Alphabetized swarm subcmds (@richardlitt)
    • Added note to ipfs stats bw interval option (@richardlitt)
    • Small syntax changes to repo stat man (@richardlitt)
    • update log command help text (@pfista)
    • Added a long description to add (@richardlitt)
    • Edited object patch set-data doc (@richardlitt)
    • add roadmap.md (@Jeromy)
    • Adds files api cmd to helptext (@noffle)

v0.4.0 - 2016-04-05

This is a major release with plenty of new features and bugfixes. It also includes breaking changes which make it incompatible with v0.3.x on the networking layer.

  • Major Changes
    • Multistream
      • The addition of multistream is a breaking change on the networking layer, but gives IPFS implementations the ability to mix and match different stream multiplexers, e.g. yamux, spdystream, or muxado. This adds a ton of flexibility on one of the lower layers of the protocol, and will help us avoid further breaking protocol changes in the future.
    • Files API
      • The new files command and API allow a program to interact with IPFS using familiar filesystem operations, namely: creating directories, reading, writing, and deleting files, listing out different directories, and so on. This feature enables any other application that uses a filesystem-like backend for storage, to use IPFS as its storage driver without having change the application logic at all.
    • Gx
      • go-ipfs now uses gx to manage its dependencies. This means that under the hood, go-ipfs's dependencies are backed by IPFS itself! It also means that go-ipfs is no longer installed using go get. Use make install instead.
  • New Features
    • Web UI
      • Update to new version which is compatible with 0.4.0. (@dignifiedquire)
    • Networking
      • Implement uTP transport. (@whyrusleeping)
      • Allow multiple addresses per configured bootstrap node. (@whyrusleeping)
    • IPNS
      • Improve IPNS resolution performance. (@whyrusleeping)
      • Have dnslink prefer TXT _dnslink.example.com, allows usage of CNAME records. (@Kubuxu)
      • Prevent ipfs name publish when /ipns is mounted. (@noffle)
    • Repo
      • Improve performance of ipfs add. (@whyrusleeping)
      • Add Datastore.NoSync config option for flatfs. (@rht)
      • Implement mark-and-sweep GC. (@whyrusleeping)
      • Allow for GC during ipfs add. (@whyrusleeping)
      • Add ipfs repo stat command. (@tmg, @diasdavid)
    • General
      • Add support for HTTP OPTIONS requests. (@lidel)
      • Add ipfs diag cmds to view active API requests (@whyrusleeping)
      • Add an IPFS_LOW_MEM environment variable which relaxes Bitswap's memory usage. (@whyrusleeping)
      • The Docker image now lives at ipfs/go-ipfs and has been completely reworked. (@lgierth)
  • Security fixes
    • The gateway path prefix added in v0.3.10 was vulnerable to cross-site scripting attacks. This release introduces a configurable list of allowed path prefixes. It's called Gateway.PathPrefixes and takes a list of strings, e.g. ["/blog", "/foo/bar"]. The v0.3.x line will not receive any further updates, so please update to v0.4.0 as soon as possible. (@lgierth)
  • Incompatible Changes
    • Install using make install instead of go get (@whyrusleeping)
    • Rewrite pinning to store pins in IPFS objects. (@tv42)
    • Bump fs-repo version to 3. (@whyrusleeping)
    • Use multistream muxer (@whyrusleeping)
    • The default for --type in ipfs pin ls is now all. (@chriscool)
  • Bug Fixes
    • Remove msgio double wrap. (@jbenet)
    • Buffer msgio. (@whyrusleeping)
    • Perform various fixes to the FUSE code. (@tv42)
    • Compute ipfs add size in background to not stall add operation. (@whyrusleeping)
    • Add option to have ipfs add include top-level hidden files. (@noffle)
    • Fix CORS checks on the API. (@rht)
    • Fix ipfs update error message. (@tomgg)
    • Resolve paths in ipfs pin rm without network lookup. (@noffle)
    • Detect FUSE unmounts and track mount state. (@noffle)
    • Fix go1.6rc2 panic caused by CloseNotify being called from wrong goroutine. (@rwcarlsen)
    • Bump DHT kvalue from 10 to 20. (@whyrusleeping)
    • Put public key and IPNS entry to DHT in parallel. (@whyrusleeping)
    • Fix panic in CLI argument parsing. (@whyrusleeping)
    • Fix range error by using larger-than-zero-length buffer. (@noffle)
    • Fix yamux hanging issue by increasing AcceptBacklog. (@whyrusleeping)
    • Fix double Transport-Encoding header bug. (@whyrusleeping)
    • Fix uTP panic and file descriptor leak. (@whyrusleeping)
  • Tool Changes
    • Add --pin option to ipfs add, which defaults to true and allows --pin=false. (@eminence)
    • Add arguments to ipfs pin ls. (@chriscool)
    • Add dns and resolve commands to read-only API. (@Kubuxu)
    • Add option to display headers for ipfs object links. (@palkeo)
  • General Codebase Changes
    • Check Golang version in Makefile. (@chriscool)
    • Improve Makefile. (@tomgg)
    • Remove dead Jenkins CI code. (@lgierth)
    • Add locking interface to blockstore. (@whyrusleeping)
    • Add Merkledag FetchGraph and EnumerateChildren. (@whyrusleeping)
    • Rename Lock/RLock to GCLock/PinLock. (@jbenet)
    • Implement pluggable datastore types. (@tv42)
    • Record datastore metrics for non-default datastores. (@tv42)
    • Allow multistream to have zero-rtt stream opening. (@whyrusleeping)
    • Refactor ipnsfs into a more generic and well tested mfs. (@whyrusleeping)
    • Grab more peers if bucket doesn't contain enough. (@whyrusleeping)
    • Use CloseNotify in gateway. (@whyrusleeping)
    • Flatten multipart file transfers. (@whyrusleeping)
    • Send updated DHT record fixes to peers who sent outdated records. (@whyrusleeping)
    • Replace go-psutil with go-sysinfo. (@whyrusleeping)
    • Use ServeContent for index.html. (@AtnNn)
    • Refactor object patch API to not store data in URL. (@whyrusleeping)
    • Use mfs for ipfs add. (@whyrusleeping)
    • Add Server header to API responses. (@Kubuxu)
    • Wire context directly into HTTP requests. (@rht)
    • Wire context directly into GetDAG operations within GC. (@rht)
    • Vendor libp2p using gx. (@whyrusleeping)
    • Use gx vendored packages instead of Godeps. (@whyrusleeping)
    • Simplify merkledag package interface to ease IPLD inclusion. (@mildred)
    • Add default option value support to commands lib. (@whyrusleeping)
    • Refactor merkledag fetching methods. (@whyrusleeping)
    • Use net/url to escape paths within Web UI. (@noffle)
    • Deprecated key.Pretty(). (@MichealMure)
  • Documentation
    • Fix and update help text for every ipfs command. (@RichardLitt)
    • Change sample API origin settings from wildcard (*) to example.com. (@Kubuxu)
    • Improve documentation of installation process in README. (@whyrusleeping)
    • Improve windows.md. (@chriscool)
    • Clarify instructions for installing from source. (@noffle)
    • Make version checking more robust. (@jedahan)
    • Assert the source code is located within GOPATH. (@whyrusleeping)
    • Remove mentions of /dns from ipfs dns command docs. (@lgierth)
  • Testing
    • Refactor iptb tests. (@chriscool)
    • Improve t0240 sharness test. (@chriscool)
    • Make bitswap tests less flaky. (@whyrusleeping)
    • Use TCP port zero for ipfs daemon in sharness tests. (@whyrusleeping)
    • Improve sharness tests on AppVeyor. (@chriscool)
    • Add a pause to fix timing on t0065. (@whyrusleeping)
    • Add support for arbitrary TCP ports to t0060-daemon.sh. (@noffle)
    • Make t0060 sharness test use TCP port zero. (@whyrusleeping)
    • Randomized ipfs stress testing via randor (@dignifiedquire)
    • Stress test pinning and migrations (@whyrusleeping)