linkerd2/proxy/router
Oliver Gould e91699bba2
proxy/router: Implement LRU cache eviction (#925)
The router's cache has no means to evict unused entries when capacity is
reached.

This change does the following:

- Wraps cache values in a smart pointer that tracks the last time of
  access for each entry. The smart pointer updates the access time when
  the reference to entry is dropped.
- When capacity is not available, all nodes that have not been accessed
  within some minimal idle age are dropped.

Accesses and updates to the map are O(1) when capacity is available.
Reclaiming capacity is O(n), so it's expected that the router is
configured with enough capacity such that capacity need not be reclaimed
usually.
2018-05-10 19:06:31 -07:00
..
src proxy/router: Implement LRU cache eviction (#925) 2018-05-10 19:06:31 -07:00
Cargo.toml proxy: Upgrade tower dependencies (#892) 2018-05-02 13:40:55 -07:00