mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-01-01 14:07:54 +01:00
Skip invalid sessions when adding ping to them
Root cause for invalid sessions unknown Affects issues: - Fixed #1544
This commit is contained in:
parent
2b85c75b7f
commit
4804d9be9b
@ -92,6 +92,7 @@ public class PingMutator {
|
|||||||
for (Session session : sessionsOfServer) {
|
for (Session session : sessionsOfServer) {
|
||||||
long start = session.getDate();
|
long start = session.getDate();
|
||||||
Long end = session.getValue(SessionKeys.END).orElseGet(System::currentTimeMillis);
|
Long end = session.getValue(SessionKeys.END).orElseGet(System::currentTimeMillis);
|
||||||
|
if (end < start) continue;
|
||||||
// Calculate average ping for each session with a Ping submap
|
// Calculate average ping for each session with a Ping submap
|
||||||
SortedMap<Long, Ping> duringSession = pingOfServer.subMap(start, end);
|
SortedMap<Long, Ping> duringSession = pingOfServer.subMap(start, end);
|
||||||
for (Ping ping : duringSession.values()) {
|
for (Ping ping : duringSession.values()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user