1
0
Fork 0
forgejo/routers
zeripath 196593e2e9
More efficiently parse shas for shaPostProcessor (#16101)
* More efficiently parse shas for shaPostProcessor

The shaPostProcessor currently repeatedly calls git rev-parse --verify on both backends
which is fine if there is only one thing that matches a sha - however if there are
multiple things then this becomes wildly inefficient.

This PR provides functions for both backends which are much faster to use.

Fix #16092

* Add ShaExistCache to RenderContext

Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
2021-06-21 00:39:12 +02:00
..
api/v1 Fix some API bugs (#16184) 2021-06-18 01:24:55 +02:00
common Refactor routers directory (#15800) 2021-06-09 01:33:54 +02:00
install Add asymmetric JWT signing (#16010) 2021-06-17 23:56:46 +02:00
private Make modules/context.Context a context.Context (#16031) 2021-05-31 02:18:11 -04:00
utils Clarify the suffices and prefixes of setting.AppSubURL and setting.AppURL (#12999) 2021-02-19 22:36:43 +01:00
web More efficiently parse shas for shaPostProcessor (#16101) 2021-06-21 00:39:12 +02:00
init.go Add sso.Group, context.Auth, context.APIAuth to allow auth special routes (#16086) 2021-06-09 19:53:16 +02:00