kubo/core
Lucas Molas 25cc85fa93
feat(gateway): Gateway.FastDirIndexThreshold (#8853)
* fix(core/gateway): option to limit directory size listing

* feat(gw): HTMLDirListingLimit

This is alternative take on the way we limit the HTML listing output.
Instead of a hard cut-off, we list up to HTMLDirListingLimit.
When a directory has more items than HTMLDirListingLimit we show
additional header and footer informing user that only $HTMLDirListingLimit
items are listed. This is a better UX.

* fix: 0 disables Gateway.HTMLDirListingLimit

* refactor: Gateway.FastDirIndexThreshold

see explainer in docs/config.md

* refactor: prealoc slices

* docs: Gateway.FastDirIndexThreshold

* refactor: core/corehttp/gateway_handler.go

https://github.com/ipfs/go-ipfs/pull/8853#discussion_r851437088

* docs: apply suggestions from code review

Co-authored-by: Alan Shaw <alan.shaw@protocol.ai>

Co-authored-by: Marcin Rataj <lidel@lidel.org>
Co-authored-by: Alan Shaw <alan.shaw@protocol.ai>
2022-04-28 19:36:57 +02:00
..
bootstrap fix(tracing): remove event tracing 2020-01-28 21:31:12 -08:00
commands docs: replace all git.io links with their actual URLs 2022-04-28 18:06:08 +02:00
coreapi feat(gateway): Gateway.FastDirIndexThreshold (#8853) 2022-04-28 19:36:57 +02:00
coredag gx: unrewrite 2019-03-05 18:33:56 +01:00
corehttp feat(gateway): Gateway.FastDirIndexThreshold (#8853) 2022-04-28 19:36:57 +02:00
corerepo feat: go-libp2p 0.16, UnixFS autosharding and go-datastore with contexts (#8563) 2021-11-29 19:58:05 +01:00
coreunix feat: add basic gateway tracing (#8595) 2022-04-04 19:24:05 +02:00
mock feat: opt-in Swarm.ResourceMgr (go-libp2p v0.18) (#8680) 2022-04-07 21:06:35 -04:00
node feat: relay v2 discovery (go-libp2p v0.19.0) (#8868) 2022-04-28 17:13:15 +02:00
.gitignore ignore testdb 2014-07-05 15:04:04 -07:00
builder.go fix(core/node): unwrap fx error in node construction 2022-03-16 19:32:31 -03:00
core_test.go fix: rewrite dependencies over the go-ipfs-config package 2022-03-04 09:45:16 +01:00
core.go feat: opt-in Swarm.ResourceMgr (go-libp2p v0.18) (#8680) 2022-04-07 21:06:35 -04:00