-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
[grid] Tracking SessionRemovalInfo when removing session from SessionMap #16678
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
Signed-off-by: Viet Nguyen Duc <[email protected]>
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
|||||||||||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||||||||||
Signed-off-by: Viet Nguyen Duc <[email protected]>
Signed-off-by: Viet Nguyen Duc <[email protected]>
User description
🔗 Related Issues
💥 What does this PR do?
SeleniumHQ/docker-selenium#3025 - Selenium Grid throwing NoSuchSessionException – Session ID not found
There are 3 events to trigger the removal of the session from LocalSessionMap. Possibility session closed on demand (QUIT command) or timed out, Node restarted, or Node removed (detach from grid and shutdown)
Based on triggered event, reason will be attached with closed timestamp for more info instead of a common message
🔧 Implementation Notes
💡 Additional Considerations
🔄 Types of changes
PR Type
Enhancement
Description
Add session closure reason tracking throughout grid lifecycle
Create SessionClosedReason enum with four closure scenarios
Track recently removed sessions with removal info for diagnostics
Enhance NoSuchSessionException with detailed closure reasons
Update SessionId to carry close reason metadata
Diagram Walkthrough
File Walkthrough
8 files
New enum for session closure reasonsNew class to track session removal detailsAdd reason parameter to SessionClosedEventAdd close reason tracking to SessionIdPass SessionClosedReason to slot stop methodAccept and propagate SessionClosedReasonTrack removed sessions with Caffeine cacheInclude close reason in exception messages1 files
Add tests for session closure reasons1 files
Add Caffeine cache dependency