runtime-api subsystem lru cache (#2309)

* Add memory-lru cache to runtime-api

* Add cache.rs

* Adds MallocSizeOf

* Review nits

* Add a cached requests metric

* More review nits

* Some more review nits
This commit is contained in:
Fedor Sakharov
2021-01-26 18:51:10 +03:00
committed by GitHub
parent f3adf8b864
commit 5634d289ee
11 changed files with 525 additions and 39 deletions
@@ -8,6 +8,9 @@ edition = "2018"
futures = "0.3.12"
tracing = "0.1.22"
tracing-futures = "0.2.4"
memory-lru = "0.1.0"
parity-util-mem = { version = "0.8.0", default-features = false }
sp-api = { git = "https://github.com/paritytech/substrate", branch = "master" }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "master" }