Commit graph

44 commits

Author SHA1 Message Date
Laura Hausmann
cefbf4f898
[backend/core] Move AsyncLocals to FlagService, fix IsPleroma flag for streaming connections 2025-03-22 20:56:36 +01:00
Kopper
1e1364e2bb
[backend/masto-client] Add feature flag for inline media 2024-12-13 22:19:31 +01:00
Laura Hausmann
c0e8a6d680
[backend/streaming] Fix streaming updates not containing html markup if supported 2024-11-20 02:36:32 +01:00
Laura Hausmann
51e4846635
[backend/core] Revert Task.ContinueWithResult naming 2024-11-20 01:14:50 +01:00
Laura Hausmann
7dec2514da
[sln] Apply code style 2024-11-20 00:48:29 +01:00
kopper
7173373330
[backend/federation] Improved reply backfill
Instead of backfilling every note we come across that has a reply
collection, only schedule a backfill job if someone wants to see the
replies (on GET MastoAPI /context, or Iceshrimp API /descendants)

Reply backfilling is also done on a ThreadIdOrId basis as opposed to the
previous way of backfilling individual notes. This allows us finer
grained control over the recursion and frees up the job queue, alongside
allowing for easier implementation of context collection backfill in the
future (by mapping each context collection to a thread)

---

Currently, note threads are implicit based on the "threadId" column of a
note, which can be null (where it's the same as the note's "id")

This commit turns note threads into an actual entity, and as a part of
that, makes "threadId" non-nullable (by specifically setting it to "id"
for those cases)

This is done to attach extra metadata to the entire thread, currently
just the time of when it was last backfilled, but more may be added in
the future (the context collection associated with this thread, for example)

---

The data format for backfill jobs have backwards-incompatibly changed
since the introduction of the feature. We can drop all old jobs without
causing too much trouble as they will be re-scheduled on demand

---

Signed-off-by: Laura Hausmann <laura@hausmann.dev>
2024-10-24 21:18:57 +02:00
Laura Hausmann
304d9f2750
[backend/masto-client] Enforce RestrictedNoMedia public preview mode 2024-09-24 01:02:05 +02:00
Kopper
7518cf7422 [backend/akko-client] Handle websocket ping 2024-09-13 17:30:05 +02:00
Kopper
9d6d892091 [backend/akko-client] Fix notifications, including emoji reaction notifications 2024-09-13 17:30:05 +02:00
Laura Hausmann
86a5da5418
[backend/streaming] Switch to WriteLockingHashSet for cached streaming connection data 2024-08-13 17:39:59 +02:00
Laura Hausmann
3132b6b8c9
[backend/core] Fix note thread mute handling inconsistencies 2024-08-13 03:11:09 +02:00
Laura Hausmann
c7d0280eb6
[backend] Use SemaphorePlus instead of SemaphoreSlim 2024-07-22 05:59:41 +02:00
Laura Hausmann
1e8f1cb964
[backend/database] Migrate references to Note.ThreadId ?? Note.Id to Note.ThreadIdOrId 2024-07-14 22:06:29 +02:00
Laura Hausmann
9233e43b81
[backend/api-shared] Don't dispose DbContext prematurely in streaming connection handlers 2024-07-13 15:59:35 +02:00
Laura Hausmann
1d43f2c30b
[backend/api-shared] Add thread mute support (ISH-172) 2024-07-13 01:35:28 +02:00
Laura Hausmann
df3a7bdfe5
[backend] Apply formatting rules 2024-06-29 01:06:19 +02:00
Laura Hausmann
24bde5ad29
[backend] Use User.IsLocalUser / .IsRemoteUser instead of null-checks where applicable (ISH-370) 2024-06-17 17:25:29 +02:00
Laura Hausmann
4c342b0657
[backend/masto-client] Add direct streaming channel (ISH-332) 2024-05-23 17:24:06 +02:00
Laura Hausmann
434d532318
[backend/streaming] Respect list members that are hidden from home in streaming connections 2024-05-23 17:23:50 +02:00
Laura Hausmann
dc09a4ada2
[backend/masto-client] Add list streaming channel (ISH-332) 2024-05-23 17:10:36 +02:00
Laura Hausmann
a4087a4c81
[backend/masto-client] Add hashtag streaming channel (ISH-332) 2024-05-23 17:10:32 +02:00
Laura Hausmann
329f677075
[backend/masto-client] Fix IsApplicableBool check in UserChannel 2024-05-23 14:48:16 +02:00
Laura Hausmann
9636a096fc
[backend/masto-client] Respect filters in WebSocket connections (ISH-328) 2024-05-17 19:21:41 +02:00
Laura Hausmann
b97c21a87b
[backend/streaming] Enforce mutes/blocks in note mentions (ISH-320) 2024-05-06 23:01:06 +02:00
Laura Hausmann
bf26ed58ff
[backend/masto-client] Initialize all relationship collections on websocket connect, not just following 2024-05-02 21:29:37 +02:00
Laura Hausmann
78e47c3236
[backend/streaming] Don't send notes older than a 5 minutes to home timeline streams
This fixes the issue where when older notes get ingested through ways other than direct federation, they don't erroneously appear at the top of the home timeline.
2024-04-28 19:46:04 +02:00
Laura Hausmann
b9fa870054
[backend/streaming] Fix renote visibility checks 2024-04-26 18:58:50 +02:00
Laura Hausmann
0fc834693a
[backend/streaming] Fix pure renote without renote data filters (ISH-260) 2024-04-16 17:07:57 +02:00
Laura Hausmann
f611e01bda
[backend/masto-client] Fix user channel (ISH-260) 2024-04-16 17:01:48 +02:00
Laura Hausmann
fae324c3f3
[backend] Add [MustDisposeResource] attribute to WebSocketConnection & StreamingConnectionAggregate 2024-04-09 18:23:11 +02:00
Laura Hausmann
998a4412cb
[backend/api-shared] Clone NoteResponse / StatusEntity in streaming handlers' EnforceRenoteReplyVisibility functions (ISH-250) 2024-04-08 21:36:12 +02:00
Laura Hausmann
bc50aa0259
[backend/masto-client] Enforce renote/reply visibility in ws/streaming (ISH-248) 2024-04-08 21:10:05 +02:00
Laura Hausmann
4ff1b5f4c4
[backend] Implement streaming hub for timelines & notifications (ISH-244) 2024-04-08 20:45:30 +02:00
Laura Hausmann
45dcbf29fe
[backend/masto-client] Handle mutes & blocks in WebSockets (ISH-219) 2024-03-26 19:11:49 +01:00
Laura Hausmann
b4adfe7067
[backend/masto-client] Update followed users on user follow/unfollow/block (ISH-218) 2024-03-26 18:17:24 +01:00
Laura Hausmann
6d49eb07ca
[backend/core] Dispose service scopes properly for long-running connections (WebSocket) 2024-03-24 14:34:07 +01:00
Laura Hausmann
a67fe3722d
[backend] Code cleanup 2024-03-24 14:17:02 +01:00
Laura Hausmann
c02b2bd34c
[backend/core] Improve handling of explicit service scopes & event logic 2024-03-24 14:13:51 +01:00
Laura Hausmann
a408fa247a
[backend] Code cleanup 2024-03-17 13:36:08 +01:00
Laura Hausmann
64fc07ff53
[backend/masto-client] Fix errors in WebSocket notification handler 2024-03-11 04:00:40 +01:00
Laura Hausmann
a855e0fc44
[backend/core] Catch exceptions in WebSocket event handlers (ISH-158) 2024-03-09 03:11:00 +01:00
Laura Hausmann
c083305123
[backend] Code cleanup 2024-02-24 21:03:29 +01:00
Laura Hausmann
18af329ba6
[backend/masto-client] Handle query parameters for streaming API WebSocket connections 2024-02-21 19:32:58 +01:00
Laura Hausmann
9b99f9245f
[backend/masto-client] Add basic WebSocket support 2024-02-21 03:36:34 +01:00