More explicit wording on a comment.
[beanstalkd.git] / prot.h
blobf2ef8ff8ac0f25d9053c03f05ba15b48ee072c26
1 /* prot.h - protocol implementation header */
3 #ifndef prot_h
4 #define prot_h
6 #include "job.h"
7 #include "conn.h"
9 /* space for 16 Mi jobs */
10 #define HEAP_SIZE 16 * 1024 * 1024
12 #define URGENT_THRESHOLD 1024
14 /* measured in seconds */
15 #define RESERVATION_TIMEOUT 120
17 #define MSG_RESERVED "RESERVED"
19 void prot_init();
21 void reply(conn c, char *line, int len, int state);
22 void reply_job(conn c, job j, const char *word);
24 void enqueue_waiting_conn(conn c);
26 int enqueue_job(job j);
27 void bury_job(job j);
28 int kick_job();
29 void process_queue();
31 job peek_job(unsigned long long int id);
33 unsigned int get_ready_job_ct();
34 unsigned int get_buried_job_ct();
35 unsigned int get_urgent_job_ct();
37 #endif /*prot_h*/