|
Squid Web Cache master
|
#include "squid.h"#include "base/RunnersRegistry.h"#include "comm.h"#include "comm/Connection.h"#include "comm/Loops.h"#include "compat/socket.h"#include "event.h"#include "fatal.h"#include "SquidConfig.h"#include "tools.h"Go to the source code of this file.
Classes | |
| struct | wccp_here_i_am_t |
| struct | wccp_cache_entry_t |
| struct | wccp_i_see_you_t |
| struct | wccp_assign_bucket_t |
| class | WccpRr |
Macros | |
| #define | WCCP_PORT 2048 |
| #define | WCCP_REVISION 0 |
| #define | WCCP_ACTIVE_CACHES 32 |
| #define | WCCP_HASH_SIZE 32 |
| #define | WCCP_BUCKETS 256 |
| #define | WCCP_CACHE_LEN 4 |
| #define | WCCP_HERE_I_AM 7 |
| #define | WCCP_I_SEE_YOU 8 |
| #define | WCCP_ASSIGN_BUCKET 9 |
Functions | |
| static int | wccpLowestIP (void) |
| static void | wccpAssignBuckets (void) |
| static void | wccpInit (void) |
| static void | wccpConnectionOpen (void) |
| static void | wccpConnectionClose (void) |
| DefineRunnerRegistrator (WccpRr) | |
| static void | wccpHandleUdp (int sock, void *) |
| static void | wccpHereIam (void *) |
Variables | |
| static int | theWccpConnection = -1 |
| static struct wccp_here_i_am_t | wccp_here_i_am |
| static struct wccp_i_see_you_t | wccp_i_see_you |
| static int | last_change |
| static int | last_id |
| static int | last_assign_buckets_change |
| static unsigned int | number_caches |
| static Ip::Address | local_ip |
| static PF | wccpHandleUdp |
| static EVH | wccpHereIam |
| DefineRunnerRegistrator | ( | WccpRr | ) |
|
static |
Definition at line 308 of file wccp.cc.
References assert, buckets, comm_udp_send(), debugs, wccp_i_see_you_t::id, wccp_assign_bucket_t::id, wccp_cache_entry_t::ip_addr, last_change, wccp_i_see_you_t::number, wccp_assign_bucket_t::number, number_caches, theWccpConnection, wccp_assign_bucket_t::type, WCCP_ACTIVE_CACHES, WCCP_ASSIGN_BUCKET, WCCP_BUCKETS, wccp_i_see_you_t::wccp_cache_entry, WCCP_CACHE_LEN, wccp_i_see_you, xfree, and xmalloc.
Referenced by wccpHandleUdp().
|
static |
Definition at line 161 of file wccp.cc.
References comm_close, DBG_IMPORTANT, debugs, IamPrimaryProcess(), and theWccpConnection.
Referenced by WccpRr::startReconfigure(), and WccpRr::startShutdown().
|
static |
Definition at line 106 of file wccp.cc.
References SquidConfig::address, COMM_NONBLOCKING, comm_open_listener(), COMM_SELECT_READ, Config, DBG_CRITICAL, DBG_IMPORTANT, debugs, fatal(), Ip::Address::getSockAddr(), IamPrimaryProcess(), Ip::Address::isAnyAddr(), local_ip, Ip::Address::port(), SquidConfig::router, Ip::Address::setIPv4(), Comm::SetSelect(), theWccpConnection, SquidConfig::Wccp, WCCP_PORT, wccpHandleUdp, xconnect(), and xgetsockname().
Referenced by WccpRr::syncConfig(), and WccpRr::useConfig().
|
static |
Definition at line 191 of file wccp.cc.
References wccp_i_see_you_t::change, COMM_SELECT_READ, comm_udp_recvfrom(), Config, DBG_IMPORTANT, debugs, wccp_i_see_you_t::id, last_assign_buckets_change, last_change, last_id, wccp_i_see_you_t::number, number_caches, SquidConfig::router, Comm::SetSelect(), wccp_i_see_you_t::type, SquidConfig::version, wccp_i_see_you_t::version, SquidConfig::Wccp, WCCP_ACTIVE_CACHES, WCCP_I_SEE_YOU, wccp_i_see_you, wccpAssignBuckets(), wccpHandleUdp, and wccpLowestIP().
|
static |
Definition at line 288 of file wccp.cc.
References comm_udp_send(), debugs, eventAdd(), eventFind(), wccp_here_i_am_t::id, last_id, theWccpConnection, wccp_here_i_am, wccpHereIam, and xstrerr().
|
static |
Definition at line 85 of file wccp.cc.
References Config, debugs, eventAdd(), eventFind(), IamPrimaryProcess(), Ip::Address::isAnyAddr(), last_assign_buckets_change, last_change, last_id, number_caches, wccp_here_i_am_t::revision, SquidConfig::router, wccp_here_i_am_t::type, SquidConfig::version, wccp_here_i_am_t::version, SquidConfig::Wccp, WCCP_HERE_I_AM, wccp_here_i_am, WCCP_REVISION, and wccpHereIam.
Referenced by WccpRr::useConfig().
|
static |
Definition at line 265 of file wccp.cc.
References assert, wccp_cache_entry_t::ip_addr, local_ip, wccp_i_see_you_t::number, WCCP_ACTIVE_CACHES, wccp_i_see_you_t::wccp_cache_entry, and wccp_i_see_you.
Referenced by wccpHandleUdp().
|
static |
Definition at line 74 of file wccp.cc.
Referenced by wccpHandleUdp(), and wccpInit().
|
static |
Definition at line 72 of file wccp.cc.
Referenced by wccpAssignBuckets(), wccpHandleUdp(), and wccpInit().
|
static |
Definition at line 73 of file wccp.cc.
Referenced by wccpHandleUdp(), wccpHereIam(), and wccpInit().
|
static |
Definition at line 77 of file wccp.cc.
Referenced by wccpConnectionOpen(), and wccpLowestIP().
|
static |
Definition at line 75 of file wccp.cc.
Referenced by wccpAssignBuckets(), wccpHandleUdp(), and wccpInit().
|
static |
Definition at line 67 of file wccp.cc.
Referenced by wccpAssignBuckets(), wccpConnectionClose(), wccpConnectionOpen(), and wccpHereIam().
|
static |
Definition at line 69 of file wccp.cc.
Referenced by wccpHereIam(), and wccpInit().
|
static |
Definition at line 71 of file wccp.cc.
Referenced by wccpAssignBuckets(), wccpHandleUdp(), and wccpLowestIP().
|
static |
Definition at line 79 of file wccp.cc.
Referenced by wccpConnectionOpen(), and wccpHandleUdp().
|
static |
Definition at line 81 of file wccp.cc.
Referenced by wccpHereIam(), and wccpInit().