@page @model RR3CommunityServer.Pages.SessionsModel @{ ViewData["Title"] = "Session Management"; }

🔄 Session Management

Monitor active and expired sessions

← Back
Active Sessions

@Model.ActiveSessions.Count

Expired Sessions

@Model.ExpiredSessions.Count

Total Sessions

@Model.AllSessions.Count

@if (Model.ActiveSessions.Any()) {
🟢 Active Sessions (@Model.ActiveSessions.Count)
@foreach (var session in Model.ActiveSessions) { var timeLeft = session.ExpiresAt - DateTime.UtcNow; }
Session ID User ID Device ID Created Expires Time Left Actions
@session.SessionId.Substring(0, 12)... @session.UserId @session.DeviceId.Substring(0, 12)... @session.CreatedAt.ToString("g") @session.ExpiresAt.ToString("g") @((int)timeLeft.TotalHours)h @timeLeft.Minutes)m
} @if (Model.ExpiredSessions.Any()) {
⚫ Expired Sessions (@Model.ExpiredSessions.Count)
@foreach (var session in Model.ExpiredSessions.Take(20)) { var duration = session.ExpiresAt - session.CreatedAt; }
Session ID User ID Device ID Created Expired Duration
@session.SessionId.Substring(0, 12)... @session.UserId @session.DeviceId.Substring(0, 12)... @session.CreatedAt.ToString("g") @session.ExpiresAt.ToString("g") @((int)duration.TotalHours)h
@if (Model.ExpiredSessions.Count > 20) {
Showing 20 of @Model.ExpiredSessions.Count expired sessions
}
} @if (!Model.AllSessions.Any()) {
No sessions yet. Sessions will appear when players connect to the server.
}