Skip to content

Releases: ipni/go-libipni

v0.5.9

10 Jan 19:46
720283f
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.8...v0.5.9

v0.5.8

22 Dec 22:27
fe44e6c
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.7...v0.5.8

v0.5.7

21 Nov 11:41
0c8d003
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.6...v0.5.7

v0.5.6

15 Nov 19:54
81798c1
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v0.5.4...v0.5.6

v0.5.5

04 Nov 09:03
d9e9dec
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v0.5.4...v0.5.5

v0.5.4

27 Sep 12:14
c074248
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.3...v0.5.4

v0.5.3

25 Sep 15:02
f686b6d
Compare
Choose a tag to compare

What's Changed

  • Return same not-found response from dh and non-dh clients by @gammazero in #124
  • Option for double-hashed lookups to return only metadata by @gammazero in #123

Full Changelog: v0.5.2...v0.5.3

v0.5.2

19 Sep 13:42
3bc33f6
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.1...v0.5.2

v0.5.1

15 Sep 09:37
d307043
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.5.0...v0.5.1

v0.5.0

31 Aug 21:21
cacbccc
Compare
Choose a tag to compare

What's Changed

Use the new libp2phttp functionality for serving and requesting ipnisync over libp2p and HTTP.

The new publisher can publish ipnisync-http over libp2p if supplied with a stream host, over plain HTTP if supplied with a listen address, or both. The publisher also works as an HTTP handler to allow it to be used with existing HTTP listeners.

The sync client works with ipnisync-http over libp2p, plain HTTP, and legacy data-transfer sync. It is able to detect which protocol and transport to use with any provider, new or old.

Protocol negotiation

When a Syncer is created to sync with a specific advertisement publisher, it first uses libp2phttp to negotiate with the publisher whether to use HTTP with or without libp2p. If the publisher is an older publisher that does not support this negotiation, then the client tries to use plain HTTP or the legacy data-transfer/graphsync protocol depending on the publisher address.

If a publisher is newer, but uses an existing HTTP server, it can still support protocol negotiation by supporting the /.well-known/ HTTP endpoint. Here is an example of adding support for this. This is optional, and the cost for not supporting it is one additional HTTP round trip between the indexer and publisher per sync operation.

API Changes

This version has some minor ipnisync API changes to be aware of.

Publisher API Changes:

  • The NewPublisher function does not take a single HTTP listen address as its first argument. It now takes a list of HTTP address as an option, WithHTTPListenAddrs, since HTTP listen addresses are not required when using a libp2p stream host or with an existing HTTP server.
  • The NewPublisher can be given a libp2p stream host to serve advertisements, by specifying the option WithStreamHost.
  • The dagsync/p2p/protocol/head package has moved to dagsync/dtsync/head since it is only used in dtsync. This should not affect any external applications.
  • The WithServer has been renamed to WithStartServer.
  • A new option, WithRequireTLS tells whether to require https or allow the publisher to serve non-secure http. Default is false, allowing non-secure HTTP.

Sync client API changes:

  • The NewSync function does not take an http.Client. Options are used to configure a default or retryable HTTP client.
  • New options are available to the NewSync function:
    • ClientAuthServerPeerID tells the sync client that it must authenticate the Server's PeerID.
    • ClientHTTPTimeout specifies a time limit for HTTP requests
    • ClientStreamHost specifies an optional stream based libp2p host
    • ClientHTTPRetry configures a retriable HTTP client
  • The NewSyncer function now takes a single peer.AddrInfo instead of a separate peer.ID and []multiaddr.Multiaddr arguments.

dagsync.Subscriber API changes:

  • NewSubscriber no longer has a HttpClient option. It now supports the following options:
    • HttpTimeout which is passed through to the the ClientHttpTimeout option
    • RetryableHTTPClient which is passed through to the ClientHTTPRetry option.

EoL Notice for data-transfer/graphsync

Support for advertisement sync using data-transfer/graphsync is being discontinued in future releases. It remains in this release as a temporary backup in case there is some failure to publish when a publisher upgrades.

Any applications using the dagsync/dtsync package must switch to using dagsync/ipnisync as soon as possible.

Please also read the v0.4.0 Release Notes if converting from an earlier version of this package.

Full Changelog: v0.4.0...v0.5.0