Closed chrosim closed 2 years ago
Seems like this can happen in case a timeout has been set for a map (or list) that never has had any content. The map case can be tested with this variation of the regular expiration timeout test (expirationTimeout_mapClearedAfterTimeout
):
@Test
public void expirationTimeout_unpopulatedMap_mapClearWithoutExplosions() {
Duration timeout = Duration.ofMinutes(15);
map.setExpirationTimeout(timeout);
registration.remove();
ce.setClock(Clock.offset(ce.getClock(), timeout.plusMinutes(1)));
ce.openTopicConnection(context, "topic", SystemUserInfo.getInstance(), connection -> null);
// All is fine if openTopicConnection runs successfully
}
@chrosim the issue has been fixed in Collaboration Engine 5.0.0.alpha2 which requires Vaadin 23.0.0.alpha3.
We are backporting the fix also to Collaboration Engine 3.2 and 4.0, I'll let you know once released.
I am facing a NPE sometimes which is raised in the Topic.class More specific inside the clearExpiredData Method the namedMapData.get(name) sometimes results in a null value.
Versions