Skip to content

Memory Leak because of AuthenticationFutures #73

@pLeminoq

Description

@pLeminoq

Running bco-test --simuate and observing its memory usage in VisualVM reveals a memory leak. The Heap Dump reveals that the static list authenticatedFutureList in the class AbstractAuthenticationFuture makes up a large amount of this memory and the number of futures in this list is always increasing.

The idea with this list is that it is required to call get on these futures to update the users session (this is a problem if the future is created but no one calls get on it). Thus we keep a list of these features and regularly call get on futures which are already done. These futures and canceled futures are then removed from the list.

We should investigate why some futures on this list are never removed (are they never done?). If they never finish we could still remove all futures which are older than a timeout (e.g. 30 seconds, or simply the session timeout) since it is unusual that these could still help in keeping the users session alive.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions