-
Notifications
You must be signed in to change notification settings - Fork 290
ffi: Refactor timeline creation and lifetimes #5058
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like this is on the right track, thanks for taking a stab at this!
(removing Ivan from the reviewer list, as I've reviewed it.) |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5058 +/- ##
=======================================
Coverage 85.85% 85.86%
=======================================
Files 325 325
Lines 35937 35920 -17
=======================================
- Hits 30855 30841 -14
+ Misses 5082 5079 -3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks! we can likely get rid of more room wrappers in the SDK, after this…
Ideally, in terms of clean history management, we'd do some tidying up of the commits here:
- the "make ci happy" only contains changes that ought to be included in other commits.
git absorb
is your friend in this kind of situations! - the commit introducing the
OnceLock
for the UTD hook manager ought to be squashed with the other one that introduced theArc<Mutex<...>>
because this commit is undoing things that another commit made (fixup commit FTW!).
…service and room list items
… timeline As per the plan defined in #4718: ``` the room_list_service::room::RoomInner shouldn't make use of its inner timeline; it's only used in a direct getter, or to compute the latest room event, but it's not working as intended, since local echoes aren't properly displayed in the room list. This non-working feature can be removed, in favor of #4112 ```
…callback (dropped in favor of the `ClientSessionDelegate`)
… the hook manager isn't configured
This PR implements the plan laid out in #4718: it removes long living timeline instances from the room list service and its items in favor of directly creating a timeline through its parent room and the
timeline_with_configuration
method.In order to do so it also moves the previously internally configured UTD hook to the FFI client and exposes an option to use it on the aforementioned timeline configuration method.
NB: the event filter is already exposed in the configuration and the event cache is now enabled by default.