[sheepdog] [PATCH 0/5] introduce writethrough mode to object cache
Liu Yuan
namei.unix at gmail.com
Sat Aug 4 10:11:27 CEST 2012
From: Liu Yuan <tailai.ly at taobao.com>
This patch set does some refactors and mainly introduce writethrough mode.
Object cache writethrough mode provide us a read-only cache which is alwasy
consistent with backend store.
We can set the object cache mode by 'w' option as following:
sheep -w cache_size{,writethrough | writeback}
For e.g, we can set 1G size writethrough cache:
$ sheep -w 1000,writethrough
$ sheep -w 1000
writethrough mode is default object cache
to set as writeback cache:
$ sheep -w 1000,writeback
Liu Yuan (5):
object cache: remove file lock in create_cache_object()
object cache: refactor read/write path
object cache: add a new helper to get the entry idx
object cache: remove redundant code
object cache: implement writethrough mode
sheep/object_cache.c | 332 ++++++++++++++++++++++++++++----------------------
sheep/sheep.c | 22 +++-
sheep/sheep_priv.h | 1 +
3 files changed, 206 insertions(+), 149 deletions(-)
--
1.7.10.2
More information about the sheepdog
mailing list