Fixed entry size calculation for the max-size cache_dir selection
algorithms.
There were two sides of this bug:
In src/store_swapout.cc, we must create metadata earlier because
storeCreate() needs swap_hdr_sz. With swap_hdr_sz unknown at the time of
storeCreate(), the SwapDir selection algorithms may select SwapDirs that
should not really take the entry as the real storage size (with the
metadata swap_hdr_sz) would exceed the store slot size.
In src/store_dir.cc, we must add the metadata size before looking for
cache_dirs that accept objsize. Only the "new"
storeDirSelectSwapDirRoundRobin selection scheme was affected.
HTH,
Alex.
P.S. I do not have a version of this patch generated against trunk, but
I hope it applies easily.
This archive was generated by hypermail 2.2.0 : Thu Sep 03 2009 - 12:00:04 MDT