summaryrefslogtreecommitdiff
path: root/items.h
diff options
context:
space:
mode:
authordormando <dormando@rydia.net>2014-04-15 01:35:48 -0700
committerdormando <dormando@rydia.net>2014-04-17 00:43:18 -0700
commit6be2b6c077b83184d22a5e7ee672acea741924d0 (patch)
tree5e1c0a3991865b3d13dfd463a46c6a2e86a9792e /items.h
parent649f7f01498c13dbc1cd2a802e93d38766f905f3 (diff)
downloadmemcached-6be2b6c077b83184d22a5e7ee672acea741924d0.tar.gz
control system
nothing internally magically fires it off yet, but now there is an external command: lru_crawler crawl [classid] ... will signal the thread to wake up and immediately reap through a particular class. need some thought/feedback for internal kickoffs (plugins?)
Diffstat (limited to 'items.h')
-rw-r--r--items.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/items.h b/items.h
index 99e1d1e..6ef5cdc 100644
--- a/items.h
+++ b/items.h
@@ -27,5 +27,11 @@ void item_stats_reset(void);
extern pthread_mutex_t cache_lock;
void item_stats_evictions(uint64_t *evicted);
+enum crawler_result_type {
+ CRAWLER_OK=0, CRAWLER_RUNNING, CRAWLER_BADCLASS
+};
+
int start_item_crawler_thread(void);
int stop_item_crawler_thread(void);
+int init_lru_crawler(void);
+enum crawler_result_type lru_crawler_crawl(int sid);