You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
611 B
C

14 years ago
#ifndef SERVER_H
#define SERVER_H
#include <hiredis/async.h>
#include <time.h>
#include <sys/queue.h>
#include <event.h>
14 years ago
struct evhttp;
struct server {
struct conf *cfg;
struct event_base *base;
redisAsyncContext *ac;
/* server socket and event struct */
int fd;
struct event ev;
struct event ev_reconnect;
struct timeval tv_reconnect;
};
void
14 years ago
webdis_connect(struct server *s);
14 years ago
struct server *
server_new(const char *filename);
14 years ago
struct server *
server_copy(const struct server *s);
14 years ago
void
server_start(struct server *s);
14 years ago
void
webdis_log(struct server *s, int level, const char *body);
#endif