cache_tab
cache_tab copied to clipboard
In-memory cache Erlang / Elixir library
In `lookup` call handler for `cache_tab`: ``` {ok, Prio, Val} when (State#state.lru == true) or (Prio =< CleanPrio) -> ``` This means that stale entries can still be returned by...
When I cache something which returns "error", the value is cached. For example: ``` > cache_tab:new(cache_test, []). > cache_tab:lookup(cache_test, key1, fun() -> error end). > error > cache_tab:lookup(cache_test, key1, fun()...
Can we have a hook/mechanism on cache entry removal. ? Eg . After timeout the entry is removed directly can we get mechanism of flushing the entry to DB /...
If the `update_fun()` returns `ok`, cache `{ok, Val}` rather than `Val`. Otherwise the `ets_cache:update()` caller would always have to specify `{ok, Val}`.