Fixes to infinispan user session provider
This commit is contained in:
parent
6ff37cfc24
commit
597ee2b8c9
2 changed files with 5 additions and 2 deletions
|
@ -395,7 +395,7 @@ public class InfinispanUserSessionProvider implements UserSessionProvider {
|
||||||
throw new IllegalStateException("Can't remove session: task in progress for session");
|
throw new IllegalStateException("Can't remove session: task in progress for session");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
tasks.put(key, new CacheTask(cache, CacheOperation.ADD, key, value));
|
tasks.put(key, new CacheTask(cache, CacheOperation.REPLACE, key, value));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -426,6 +426,7 @@ public class InfinispanUserSessionProvider implements UserSessionProvider {
|
||||||
break;
|
break;
|
||||||
case REPLACE:
|
case REPLACE:
|
||||||
cache.replace(key, value);
|
cache.replace(key, value);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -80,7 +80,9 @@ public class ClientSessionMapper implements Mapper<String, SessionEntity, String
|
||||||
collector.emit(key, entity);
|
collector.emit(key, entity);
|
||||||
break;
|
break;
|
||||||
case USER_SESSION_AND_TIMESTAMP:
|
case USER_SESSION_AND_TIMESTAMP:
|
||||||
collector.emit(entity.getUserSession(), entity.getTimestamp());
|
if (entity.getUserSession() != null) {
|
||||||
|
collector.emit(entity.getUserSession(), entity.getTimestamp());
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue