From 50be9b97bc975439cb34703acad5ac108952e672 Mon Sep 17 00:00:00 2001 From: antirez Date: Thu, 15 Sep 2011 15:46:29 +0200 Subject: Use a different thread for every different type of background job --- src/bio.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/bio.h') diff --git a/src/bio.h b/src/bio.h index ded0d2dce..ebd01ee28 100644 --- a/src/bio.h +++ b/src/bio.h @@ -1,11 +1,10 @@ /* Exported API */ void bioInit(void); -void bioCreateBackgroundJob(int type, void *data); +void bioCreateBackgroundJob(int type, void *arg1, void *arg2, void *arg3); unsigned long long bioPendingJobsOfType(int type); void bioWaitPendingJobsLE(int type, unsigned long long num); +time_t bioOlderJobOfType(int type); /* Background job opcodes */ -#define REDIS_BIO_ZERO_OP_ID 0 /* We don't use zero as it is the most likely - * passed value in case of bugs/races. */ -#define REDIS_BIO_CLOSE_FILE 1 /* Deferred close(2) syscall. */ -#define REDIS_BIO_MAX_OP_ID 1 +#define REDIS_BIO_CLOSE_FILE 0 /* Deferred close(2) syscall. */ +#define REDIS_BIO_NUM_OPS 1 -- cgit v1.2.1