Limit the number of events per user per day

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

  • Close this issue

Right now we store an infinite amount of events for every user for every day for up to 12 months. This does not scale database wise and makes it increasingly more difficult to perform even simple operations such as a table vacuum.

To deal with this we should put an upper limit to the number of events we store per user per day. This limit should be something reasonable but not too great. For example, 500 events per user per day may be more than enough. Combined with https://gitlab.com/gitlab-org/gitlab-ce/issues/22623 this would possibly allow us to remove a lot of data from this table.

Edited Sep 25, 2025 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading