You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
forgejo/modules
wxiaoguang 18f26cfbf7
Improve queue and logger context (#24924)
Before there was a "graceful function": RunWithShutdownFns, it's mainly
for some modules which doesn't support context.

The old queue system doesn't work well with context, so the old queues
need it.

After the queue refactoring, the new queue works with context well, so,
use Golang context as much as possible, the `RunWithShutdownFns` could
be removed (replaced by RunWithCancel for context cancel mechanism), the
related code could be simplified.

This PR also fixes some legacy queue-init problems, eg:

* typo : archiver: "unable to create codes indexer queue" => "unable to
create repo-archive queue"
* no nil check for failed queues, which causes unfriendly panic

After this PR, many goroutines could have better display name:

![image](https://github.com/go-gitea/gitea/assets/2114189/701b2a9b-8065-4137-aeaa-0bda2b34604a)

![image](https://github.com/go-gitea/gitea/assets/2114189/f1d5f50f-0534-40f0-b0be-f2c9daa5fe92)
1 year ago
..
actions Use the type RefName for all the needed places and fix pull mirror sync bugs (#24634) 1 year ago
activitypub Add Chef package registry (#22554) 2 years ago
analyze Implement FSFE REUSE for golang files (#21840) 2 years ago
assetfs Use a general approach to access custom/static/builtin assets (#24022) 1 year ago
auth Use a general approach to access custom/static/builtin assets (#24022) 1 year ago
avatar Improve avatar uploading / resizing / compressing, remove Fomantic card module (#24653) 1 year ago
base Use a general Eval function for expressions in templates. (#23927) 1 year ago
cache Update redis library to support redis v7 (#24114) 1 year ago
charset Update go tool dependencies, restructure lint targets (#24239) 1 year ago
container Implement FSFE REUSE for golang files (#21840) 2 years ago
context Fix install page context, make the install page tests really test (#24858) 1 year ago
csv Refactor locale number (#24134) 1 year ago
doctor Rewrite logger system (#24726) 1 year ago
emoji Fix unstable emoji sort (#22346) 2 years ago
eventsource Move `convert` package to services (#22264) 2 years ago
generate Implement FSFE REUSE for golang files (#21840) 2 years ago
git Use the type RefName for all the needed places and fix pull mirror sync bugs (#24634) 1 year ago
gitgraph Add context cache as a request level cache (#22294) 1 year ago
graceful Improve queue and logger context (#24924) 1 year ago
hcaptcha Consume hcaptcha and pwn deps (#22610) 2 years ago
highlight test_env: hardcode major go version in use (#23464) 1 year ago
hostmatcher Implement FSFE REUSE for golang files (#21840) 2 years ago
html Implement FSFE REUSE for golang files (#21840) 2 years ago
httpcache Use standard HTTP library to serve files (#24693) 1 year ago
httplib Use standard HTTP library to serve files (#24693) 1 year ago
indexer Improve queue and logger context (#24924) 1 year ago
issue/template Allow issue templates to not render title (#22589) 2 years ago
json Update gitea-vet to check FSFE REUSE (#22004) 2 years ago
label Make label templates have consistent behavior and priority (#23749) 1 year ago
lfs Rewrite logger system (#24726) 1 year ago
log Improve queue and logger context (#24924) 1 year ago
markup Fix video width overflow in markdown, and other changes to match img (#24834) 1 year ago
mcaptcha Implement FSFE REUSE for golang files (#21840) 2 years ago
metrics include build info in Prometheus metrics (#22819) 1 year ago
migration Scoped labels (#22585) 1 year ago
mirror Improve queue and logger context (#24924) 1 year ago
nosql Update redis library to support redis v7 (#24114) 1 year ago
notification Improve queue and logger context (#24924) 1 year ago
options Use a general approach to access custom/static/builtin assets (#24022) 1 year ago
packages Add CRAN package registry (#22331) 1 year ago
paginator Use more specific test methods (#24265) 1 year ago
pprof Implement FSFE REUSE for golang files (#21840) 2 years ago
private Use the type RefName for all the needed places and fix pull mirror sync bugs (#24634) 1 year ago
process Improve queue and logger context (#24924) 1 year ago
proxy Use proxy for pull mirror (#22771) 1 year ago
proxyprotocol Implement FSFE REUSE for golang files (#21840) 2 years ago
public Use standard HTTP library to serve files (#24693) 1 year ago
queue Improve queue and logger context (#24924) 1 year ago
recaptcha Implement FSFE REUSE for golang files (#21840) 2 years ago
references Use correct captured group range when parsing cross-reference (#22672) 2 years ago
regexplru Implement FSFE REUSE for golang files (#21840) 2 years ago
repository Use the type RefName for all the needed places and fix pull mirror sync bugs (#24634) 1 year ago
secret Improve decryption failure message (#24573) 1 year ago
session Update redis library to support redis v7 (#24114) 1 year ago
setting Add the ability to pin Issues (#24406) 1 year ago
sitemap Fix sitemap (#22272) 2 years ago
ssh Rewrite logger system (#24726) 1 year ago
storage Implement actions artifacts (#22738) 1 year ago
structs Add the ability to pin Issues (#24406) 1 year ago
svg Use a general approach to access custom/static/builtin assets (#24022) 1 year ago
sync Implement FSFE REUSE for golang files (#21840) 2 years ago
system Implement FSFE REUSE for golang files (#21840) 2 years ago
templates Improve RunMode / dev mode (#24886) 1 year ago
test Rewrite logger system (#24726) 1 year ago
testlogger Rewrite logger system (#24726) 1 year ago
timeutil Fix incorrect webhook time and use relative-time to display it (#24477) 1 year ago
translation Decouple the different contexts from each other (#24786) 1 year ago
turnstile Add new captcha: cloudflare turnstile (#22369) 2 years ago
typesniffer Do not recognize text files as audio (#23355) 1 year ago
updatechecker Implement FSFE REUSE for golang files (#21840) 2 years ago
upload Implement FSFE REUSE for golang files (#21840) 2 years ago
uri Implement FSFE REUSE for golang files (#21840) 2 years ago
user Implement FSFE REUSE for golang files (#21840) 2 years ago
util Rewrite logger system (#24726) 1 year ago
validation Map OIDC groups to Orgs/Teams (#21441) 1 year ago
web Fix install page context, make the install page tests really test (#24858) 1 year ago
webhook New webhook trigger for receiving Pull Request review requests (#24481) 1 year ago