Closed
Bug 2077139
Opened 1 month ago
Closed 7 days ago
Terminate active flow instances when the session ends
Categories
(Data Platform and Tools :: Glean: SDK, enhancement, P1)
Data Platform and Tools
Glean: SDK
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: travis_, Assigned: travis_)
References
(Blocks 1 open bug)
Details
Attachments
(1 external file)
No flow instance may span a session boundary. When a session ends, close every active instance with reason: session_end before glean.session_end is recorded. Depends on the lifecycle bug.
- Hook in at the top of
Glean::session_end(), beforesession::clear()andSessionManager::reset_state(). Eachglean.flow_endmust be recorded with an in-session context while the ending session is still current, so it gets asession.event_seqfrom that session. - This covers every reason that goes through
session_end():replaced,timeout,inactive, and explicit calls. The paths that callrecord_session_end_event()directly (dirty-flag recovery, and abandonment on session mode change at startup) are handled in the persistence bug. - Close instances in reverse order of opening.
- Reset the session-wide flow counter at session start, so the first instance in a session has
flow_seq0.
Tests: assert the order in the events ping is the last member event, then one glean.flow_end per active instance in reverse order of opening, then glean.session_end. Cover at least the replaced and AUTO-mode timeout paths. In the timeout case session_end() runs on the next handle_client_active(), so flow_end is timestamped when the timeout is noticed, the same as session_end.
Comment 1•23 days ago
|
||
(via GitHub webhook, authenticated as shared-secret)
| Assignee | ||
Updated•22 days ago
|
Assignee: nobody → tlong
Priority: P3 → P1
| Assignee | ||
Updated•22 days ago
|
Status: NEW → ASSIGNED
| Assignee | ||
Updated•7 days ago
|
Status: ASSIGNED → RESOLVED
Closed: 7 days ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•