Sessions (Simulation Life-cycle)
The Sessions module handles the technical life-cycle of your simulation, ensuring that your environment is persisted across browser reloads and tab switches.
Technical Architecture
Emuluxe uses a dual-layer persistence model to manage your active testing sessions:
- LocalStorage Layer: We store active session data under the
emuluxe_session_andemuluxe_global_sessionkeys. This allows for near-instant resumption when you refresh the page or return to a hidden tab. - Heartbeat Synchronization: Every 60 seconds, the extension sends a "heartbeat" to the Emuluxe platform (
/api/session/activity). This keeps your session alive in the background and ensures your concurrency slots are managed correctly.
The Billing Clock (Pause & Resume)
To maximize your plan's value, Emuluxe implements a smart "Pause" feature:
- Auto-Pause: When a tab is hidden (
visibilitychange) or you navigate away from the simulator, the session timer is stamped aspausedAt. - Auto-Resume: When you return, the engine calculates the "away duration" and advances your session's
endsAttimestamp accordingly, effectively "pausing" the clock while you aren't actively testing.
Plan Durations
- Free: 10-minute sessions per device activation.
- Pro/Business: 30-minute sessions with auto-continue capabilities.
- Enterprise: Unlimited session duration.