forgejo/modules/log
Gusted a9d09e5019 chore: remove goroutine PID logging (#8851)
- It was possible for Forgejo adminstrators to configure the logger to log the goroutine PID that made the `Log` call.
- The need for the goroutine PID to be logged is that it might give insight which request or otherwise process made the log call by correlating the PID with other logs. However even for a single request I cannot make correlations between the goroutine PIDs and it seems that this particular need cannot be fulfilled by the current implementation.
- The gathering of this PID is discouraged, https://go.dev/doc/faq#no_goroutine_id, and the current implementation is a hack and can break in future Go releases; it has broken before in 61e21d7ded.
- If the need arise, we instead should make the logger implementation context aware and use a PID that's associated with the context, which is guarantees to be consistent (this is also the more idiomatic way to achieve this functionality).

<!--start release-notes-assistant-->

## Release notes
<!--URL:https://codeberg.org/forgejo/forgejo-->
- Other changes without a feature or bug label
  - [PR](https://codeberg.org/forgejo/forgejo/pulls/8851): <!--number 8851 --><!--line 0 --><!--description Y2hvcmU6IHJlbW92ZSBnb3JvdXRpbmUgUElEIGxvZ2dpbmc=-->chore: remove goroutine PID logging<!--description-->
<!--end release-notes-assistant-->

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8851
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Reviewed-by: Michael Kriese <michael.kriese@gmx.de>
Co-authored-by: Gusted <postmaster@gusted.xyz>
Co-committed-by: Gusted <postmaster@gusted.xyz>
2025-08-10 22:54:29 +02:00
..
color.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
color_console.go log: journald integration (#2869) 2024-08-09 07:49:13 +00:00
color_console_other.go Drop SSPI auth support and more Windows files (#7148) 2025-03-08 00:43:41 +00:00
color_router.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
event_format.go chore: remove goroutine PID logging (#8851) 2025-08-10 22:54:29 +02:00
event_format_test.go chore: remove goroutine PID logging (#8851) 2025-08-10 22:54:29 +02:00
event_writer.go feat: add a EXCLUSION to the logger (#8212) 2025-07-04 00:08:23 +02:00
event_writer_base.go feat: add a EXCLUSION to the logger (#8212) 2025-07-04 00:08:23 +02:00
event_writer_buffer.go feat: add a buffer writer to the logger, for internal use (#6551) 2025-01-13 13:40:24 +00:00
event_writer_buffer_test.go feat: add a EXCLUSION to the logger (#8212) 2025-07-04 00:08:23 +02:00
event_writer_conn.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
event_writer_conn_test.go Update module github.com/golangci/golangci-lint/cmd/golangci-lint to v1.64.6 (forgejo) (#7118) 2025-03-04 21:38:35 +00:00
event_writer_console.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
event_writer_file.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
flags.go chore: remove goroutine PID logging (#8851) 2025-08-10 22:54:29 +02:00
flags_test.go chore: remove goroutine PID logging (#8851) 2025-08-10 22:54:29 +02:00
init.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
level.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
level_test.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
logger.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
logger_global.go Fix sub-command log level (#25537) 2023-06-28 08:02:06 +02:00
logger_impl.go chore: remove goroutine PID logging (#8851) 2025-08-10 22:54:29 +02:00
logger_impl_test.go fix: correct logging if caller has generics 2025-03-05 00:10:46 +01:00
logger_test.go feat: add a EXCLUSION to the logger (#8212) 2025-07-04 00:08:23 +02:00
manager.go Do not output "Trace" level logs from process manager by default (#24952) 2023-05-27 10:55:24 +00:00
manager_test.go Add testifylint to lint checks (#4535) 2024-07-30 19:41:10 +00:00
misc.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00
stack.go Rewrite logger system (#24726) 2023-05-21 22:35:11 +00:00