Private Issues: Discover how public vs private comments should work (and other questions) #497

Closed
opened 2026-04-07 10:28:48 +00:00 by nphilipp · 3 comments
Member

Summary

Talk to upstream if private comments shouldn’t go into their own table, too. Also, any other questions we might have.

Details

  • As we understand it, Forgejo upstream wants to keep private and public issues separate in the database to prevent leaking of sensitive information from private issues. As a lot of information is contained in commits, this probably holds true for the Comment type and related DB table as well, but we didn’t consider this yet.
  • I discovered a third option in use for wrapping nullable DB fields with, namely Option[T] from modules/optional. I want it decided if we should use sql.NullInt64 or int64 pointers (we have implemented either), or this (not implemented).
  • Confirmation (or not) that private issue contents (issues and comments) should not end up being indexed, and any list/search involving private issues should directly access the database (and be potentially much slower due to it).
  • Any other unresolved questions we might have and I didn’t think of putting here. (This is a reminder to myself to put things here 😉.)
### Summary Talk to upstream if private comments shouldn’t go into their own table, too. Also, any other questions we might have. ### Details * As we understand it, Forgejo upstream wants to keep private and public issues separate in the database to prevent leaking of sensitive information from private issues. As a lot of information is contained in commits, this probably holds true for the `Comment` type and related DB table as well, but we didn’t consider this yet. * I discovered a third option in use for wrapping nullable DB fields with, namely `Option[T]` from `modules/optional`. I want it decided if we should use `sql.NullInt64` or `int64` pointers (we have implemented either), or this (not implemented). * Confirmation (or not) that private issue contents (issues and comments) should not end up being indexed, and any list/search involving private issues should directly access the database (and be potentially much slower due to it). * Any other unresolved questions we might have and I didn’t think of putting here. (This is a reminder to myself to put things here 😉.)
nphilipp added this to the Sprint 18 project 2026-04-07 10:29:25 +00:00
nphilipp changed title from Private Issues: Discover how public vs private comments should work to Private Issues: Discover how public vs private comments should work (and other questions) 2026-04-07 10:29:59 +00:00
Author
Member
Ongoing here: https://codeberg.org/forgejo/design/issues/2#issuecomment-12957774
Member
Checked in: https://codeberg.org/forgejo/design/issues/2#issuecomment-13210506
humaton modified the project from Sprint 19 to Sprint 20 2026-05-05 10:19:29 +00:00
humaton modified the project from Sprint 20 to Sprint 21 2026-05-18 10:16:08 +00:00
Author
Member

According to gusted, …

  • Comments for private issues should live in their own database table (private_comment probably).
  • Upstream prefers using optional.Option[…] over sql.NullInt64.
  • No information yet about private contents being indexed or not (will have to follow up on that).
According to [gusted](https://codeberg.org/forgejo/design/issues/2#issuecomment-13899974), … - Comments for private issues should live in their own database table (`private_comment` probably). - Upstream prefers using `optional.Option[…]` over `sql.NullInt64`. - No information yet about private contents being indexed or not (will have to follow up on that).
Sign in to join this conversation.
No milestone
No project
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
forge/forge#497
No description provided.