feat: Update device last active timestamp #1210

Open
nex wants to merge 3 commits from nex/feat/session-activity into main
Owner

This PR updates the "device last active" timestamp when /messages, /send, PUT /state, /redact, /typing, or either sync or sliding sync starts processing. For the sake of simplicity only endpoints that are typically hit quite frequently during normal usage will perform this update, I didn't bother adding it to the more exotic endpoints.

This PR updates the "device last active" timestamp when `/messages`, `/send`, `PUT /state`, `/redact`, `/typing`, or either sync or sliding sync starts processing. For the sake of simplicity only endpoints that are typically hit quite frequently during normal usage will perform this update, I didn't bother adding it to the more exotic endpoints.
feat: Update device metadata upon hitting hot endpoints
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Successful in 48s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 2m57s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 9m3s
56702e2204
nex added this to the 0.5.0 milestone 2025-12-02 13:43:21 +00:00
nex requested review from Owners 2025-12-02 13:43:27 +00:00
Jade left a comment
Owner

feels like it should be factored into a function. also needs some kind of throttle I think?

feels like it should be factored into a function. also needs some kind of throttle I think?
perf: Don't increment the device list version when updating local info
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Successful in 56s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m30s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 7m5s
9c0449c981
perf: Throttle frequent device metadata updates & centralise site
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 51s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m26s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 8m25s
6c4b78a432
Author
Owner

How's that @Jade?

How's that @Jade?
Jade approved these changes 2025-12-02 16:01:45 +00:00
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 51s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m26s
Required
Details
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 8m25s
Required
Details
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin nex/feat/session-activity:nex/feat/session-activity
git switch nex/feat/session-activity
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
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
continuwuation/continuwuity!1210
No description provided.