-
Enhancement
-
Resolution: Won't Do
-
Major
-
8.0.0.Beta1
-
None
These implementation uses a ScheduledThreadPoolExecutor to schedule expiration of beans/sessions, and rely heavily on task cancellation to reschedule expiration upon access.
Unfortunately, the remove method of the BlockingQueue used by ScheduledThreadPoolExecutor is an O(N) operation.
Upon further review, task queue removal isn't actually an O(N) operation. The task references an index into the queue, which gets updated as its position shifts, so queue removal is really O(1).