Files
mattermost/store/sqlstore
Ashish Bhate e50cfca2ea [MM-35345][MM-35494] fixes for incorrect mentions and unreads for threads and channels (#17803)
Summary:
The CRT backend was first released in version 5.29.0. Since then, the behaviour of the CRT feature has been refined, several bugs have been fixed, and a few sql columns have been added. Before these various fixes went in, the threads and channel membership tables have accumulated incorrect mention and unreads data. This PR fixes some of this bad historical data.
Summary of fixes:

- Marks threads as read for users where the last reply time of the thread is earlier than the time the user viewed the channel. Marking a thread means setting the mention count to zero and setting the last viewed at time of the the thread as the last viewed at time of the channel. This is done through a "sql migration"
- Fix channel counts, i.e. the total message count, total root message count, mention count, and mention count in root messages for users who have viewed the channel after the last post in the channel. This is done as a "sql migration"


Ticket Link:
Parts of
https://mattermost.atlassian.net/browse/MM-35494
https://mattermost.atlassian.net/browse/MM-35345
2021-07-14 17:39:40 +05:30
..
2021-01-07 22:42:43 +05:30
2021-03-05 09:18:37 +01:00
2021-01-07 22:42:43 +05:30
2021-03-05 09:18:37 +01:00
2021-01-07 22:42:43 +05:30
2021-03-05 09:18:37 +01:00