Jitter proportionate to size

Not not default size
This commit is contained in:
Martin Sumner 2018-06-07 18:08:54 +01:00
parent 95aa1c632b
commit 589d947c01

View file

@ -593,9 +593,12 @@ init([Opts]) ->
% Start from file not snapshot % Start from file not snapshot
{InkerOpts, PencillerOpts} = set_options(Opts), {InkerOpts, PencillerOpts} = set_options(Opts),
CacheJitter = ?CACHE_SIZE div (100 div ?CACHE_SIZE_JITTER), CacheJitter =
CacheSize = proplists:get_value(cache_size, Opts) proplists:get_value(cache_size, Opts)
+ erlang:phash2(self()) rem CacheJitter, div (100 div ?CACHE_SIZE_JITTER),
CacheSize =
proplists:get_value(cache_size, Opts)
+ erlang:phash2(self()) rem CacheJitter,
RecentAAE = RecentAAE =
case proplists:get_value(recent_aae, Opts) of case proplists:get_value(recent_aae, Opts) of
false -> false ->