You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bug: CacheFuzzer does not respect restartCache when initializing cache bytes (facebookincubator#12033)
Summary:
Pull Request resolved: facebookincubator#12033
When CacheFuzzer calls initializeCache it may allocate a new cache or restart the existing cache. When it's
supposed to restart the cache it picks a new value for memoryCacheBytes and ssdCacheBytes.
If when the cache was originally started ssdCacheBytes was 0, then SSD specific settings like ssdCacheShards
won't have values. If ssdCacheBytes > 0 when the cache is restarted it will try to reuse the original value of
those SSD specific settings, which since they were never initialized are arbitrary and can be non-sensical (e.g. <= 0 in the case of shards). This leads to division by 0 and other errors when the cache is initialized.
I think the intention was for the value of the cache bytes to be reused if the cache is restarted like the other
settings (the get methods already take that boolean as a parameter). That fixes the issue.
Reviewed By: zacw7
Differential Revision: D67909205
fbshipit-source-id: 74253a876ddcd25b0a73a84d2599ef1d499cc210
0 commit comments