#include "squid.h"
#include "base/RunnersRegistry.h"
#include "CachePeer.h"
#include "CachePeers.h"
#include "carp.h"
#include "HttpRequest.h"
#include "mgr/Registration.h"
#include "neighbors.h"
#include "PeerSelectState.h"
#include "SquidConfig.h"
#include "Store.h"
#include <cmath>
![](carp_8cc__incl.png)
Go to the source code of this file.
Classes | |
class | CarpRr |
reacts to RegisteredRunner events relevant to this module More... | |
Macros | |
#define | ROTATE_LEFT(x, n) (((x) << (n)) | ((x) >> (32-(n)))) |
Functions | |
static auto & | CarpPeers () |
CARP cache_peers ordered by their CARP weight. More... | |
static int | peerSortWeight (const void *a, const void *b) |
static void | carpRegisterWithCacheManager (void) |
static void | carpInit (void) |
DefineRunnerRegistrator (CarpRr) | |
CachePeer * | carpSelectParent (PeerSelector *ps) |
static void | carpCachemgr (StoreEntry *sentry) |
Variables | |
static OBJH | carpCachemgr |
Macro Definition Documentation
◆ ROTATE_LEFT
#define ROTATE_LEFT | ( | x, | |
n | |||
) | (((x) << (n)) | ((x) >> (32-(n)))) |
Function Documentation
◆ carpCachemgr()
|
static |
Definition at line 227 of file carp.cc.
References CarpPeers(), and storeAppendPrintf().
◆ carpInit()
|
static |
Definition at line 52 of file carp.cc.
References assert, CarpPeers(), carpRegisterWithCacheManager(), CurrentCachePeers(), double, int, PEER_PARENT, peerSortWeight(), and ROTATE_LEFT.
Referenced by CarpRr::syncConfig(), and CarpRr::useConfig().
◆ CarpPeers()
|
static |
Definition at line 29 of file carp.cc.
Referenced by carpCachemgr(), carpInit(), and carpSelectParent().
◆ carpRegisterWithCacheManager()
|
static |
Definition at line 46 of file carp.cc.
References carpCachemgr, and Mgr::RegisterAction().
Referenced by carpInit().
◆ carpSelectParent()
CachePeer* carpSelectParent | ( | PeerSelector * | ps | ) |
Definition at line 150 of file carp.cc.
References SBuf::append(), SBuf::appendf(), assert, CarpPeers(), debugs, HttpRequest::effectiveRequestUri(), AnyP::Uri::getScheme(), AnyP::Uri::host(), AnyP::UriScheme::image(), SBuf::isEmpty(), SBuf::length(), SBuf::npos, AnyP::Uri::path(), peerHTTPOkay(), AnyP::Uri::port(), SBuf::rawContent(), PeerSelector::request, ROTATE_LEFT, and HttpRequest::url.
Referenced by PeerSelector::selectSomeParent().
◆ DefineRunnerRegistrator()
DefineRunnerRegistrator | ( | CarpRr | ) |
◆ peerSortWeight()
|
static |
Variable Documentation
◆ carpCachemgr
|
static |
Definition at line 35 of file carp.cc.
Referenced by carpRegisterWithCacheManager().
Introduction
- About Squid
- Why Squid?
- Squid Developers
- How to Donate
- How to Help Out
- Getting Squid
- Squid Source Packages
- Squid Deployment Case-Studies
- Squid Software Foundation
Documentation
- Quick Setup
- Configuration:
- FAQ and Wiki
- Guide Books:
- Non-English
- More...
Support
- Security Advisories
- Bugzilla Database
- Mailing lists
- Contacting us
- Commercial services
- Project Sponsors
- Squid-based products