ipfs-cluster/ipfsconn/ipfshttp
Hector Sanjuan acde3f16d0 Fix: repo/stat gets hammered on busy cluster peers
Given that every pin and block/put writes something to IPFS and thus increases
the repo size, a while ago we added a check to let the IPFS connector directly
trigger the sending of metrics every 10 of such requests. This was meant to
update the metrics more often so that balancing happened more granularly
(particularly the freespace one).

In practice, on a cluster that receives several hundreds of pin/adds
operations in a few seconds, this is just bad.

So:

* We disable by default the whole thing.
* We add a new InformerTriggerInterval configuration option to enable the thing.
* Fix a bug that made this always call the first informer, which may not
  have been the freespace one).
2022-02-01 01:34:17 +01:00
..
config_test.go Fix: repo/stat gets hammered on busy cluster peers 2022-02-01 01:34:17 +01:00
config.go Fix: repo/stat gets hammered on busy cluster peers 2022-02-01 01:34:17 +01:00
ipfshttp_test.go Fix: repo/stat gets hammered on busy cluster peers 2022-02-01 01:34:17 +01:00
ipfshttp.go Fix: repo/stat gets hammered on busy cluster peers 2022-02-01 01:34:17 +01:00