Mercurial > dovecot > original-hg > dovecot-1.2
view src/login-common/login-proxy-state.h @ 9442:562af4a76438 HEAD
imap/pop3 proxy: Track "destination down" state separately for IP+ports, not just IPs.
In some systems different ports could get redirected to different servers.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 16 Oct 2009 15:19:54 -0400 |
parents | 93e2b0519e65 |
children |
line wrap: on
line source
#ifndef LOGIN_PROXY_STATE_H #define LOGIN_PROXY_STATE_H #include <sys/time.h> struct login_proxy_record { struct ip_addr ip; unsigned int port; unsigned int num_waiting_connections; struct timeval last_failure; struct timeval last_success; }; struct login_proxy_state *login_proxy_state_init(void); void login_proxy_state_deinit(struct login_proxy_state **state); struct login_proxy_record * login_proxy_state_get(struct login_proxy_state *state, const struct ip_addr *ip, unsigned int port); #endif