kubo icon indicating copy to clipboard operation
kubo copied to clipboard

Move `ipfs routing provide` and `reprovide` into `ipfs provide` namespace

Open gammazero opened this issue 6 months ago • 6 comments

Deprecate ipfs routing provide and ipfs routing reprovide have modern version ~at ipfs provide stat [cid] that returns state of both systems + optional stat per cid (when/why it was provided last time).~ at ipfs provide added in https://github.com/ipfs/kubo/pull/10863

gammazero avatar Jul 11 '25 19:07 gammazero

Do you mean replacing ipfs stats provide and ipfs stats reprovide?

➜  ~ ipfs routing provide --help
WARNING:   EXPERIMENTAL, command may change in future releases

USAGE
  ipfs routing provide <key>... - Announce to the network that you are providing given values.

SYNOPSIS
  ipfs routing provide [--verbose | -v] [--recursive | -r] [--] <key>...

ARGUMENTS

  <key>... - The key[s] to send provide records for.

OPTIONS

  -v, --verbose    bool - Print extra information.
  -r, --recursive  bool - Recursively provide entire graph.


➜  ~ ipfs routing reprovide --help
WARNING:   EXPERIMENTAL, command may change in future releases

USAGE
  ipfs routing reprovide - Trigger reprovider.

SYNOPSIS
  ipfs routing reprovide

DESCRIPTION

  Trigger reprovider to announce our data to network.


➜  ~ ipfs stats provide --help
USAGE
  ipfs stats provide - Returns statistics about the node's (re)provider system.

SYNOPSIS
  ipfs stats provide

DESCRIPTION

  Returns statistics about the content the node is advertising.
  
  This interface is not stable and may change from release to release.

IIUC ipfs routing provide <cid> is used to provide a cid to the DHT, and ipfs routing reprovide is used to trigger a reprovide of all cids (matching reprovide strategy) to the DHT.


ipfs provide stat [cid]

The boxo/provider package doesn't track the state of each cid. This will be possible with the new DHT provider system though.

guillaumemichel avatar Jul 11 '25 21:07 guillaumemichel

Triage notes:

  • the https://github.com/ipfs/kubo/pull/10863 introduces ipfs provide
  • we cleanup/add commands in new PRs
    • have cmd for each operation from https://github.com/libp2p/go-libp2p-kad-dht/pull/1093/files
    • for clearing
      • avoiding collisions / shadowing is preferred
      • ipfs provide clear <optional-scope> may be a nice way of implementing it with open door for adding more resolution in the future (future feature where scope can be only provide/reprovide queue, or a specific cid/dag etc)
    • for ad-hoc providing
      • ipfs routing provide <key> to ipfs provide start|stop|once <cid>
    • for triggering reprovider
      • ipfs routing reprovide - TBD, maybe ipfs provide once [--background] withh no args

lidel avatar Jul 15 '25 14:07 lidel

Triage notes:

  • Let's keep current ipfs routing provide commands
  • The new provide system will use the ipfs provide namespace

guillaumemichel avatar Jul 22 '25 15:07 guillaumemichel

Meta integration issue:

  • https://github.com/ipfs/kubo/issues/10881

lidel avatar Jul 22 '25 21:07 lidel

Need recursive flag for use with ipfs provide once. This is for ad-hoc providing and will override roots only strategy. This can be done later if recursive providing is difficult.

This will allow us to alias the old ipfs routing provide to use the new ipfs provide ... command.

gammazero avatar Sep 02 '25 17:09 gammazero

Triage:

  • Will address once the new providing system is in place etc.

hsanjuan avatar Sep 16 '25 14:09 hsanjuan