neighbors.h File Reference
#include "anyp/forward.h"
#include "enums.h"
#include "ICP.h"
#include "lookup_t.h"
#include "typedefs.h"
Include dependency graph for neighbors.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


CachePeergetFirstPeer (void)
CachePeergetFirstUpParent (PeerSelector *)
CachePeergetNextPeer (CachePeer *)
CachePeergetSingleParent (PeerSelector *)
int neighborsCount (PeerSelector *)
int neighborsUdpPing (HttpRequest *, StoreEntry *, IRCB *callback, PeerSelector *ps, int *exprep, int *timeout)
void neighborAddAcl (const char *, const char *)
void neighborsUdpAck (const cache_key *, icp_common_t *, const Ip::Address &)
void neighborAdd (const char *, const char *, int, int, int, int, int)
void neighbors_init (void)
void neighborsHtcpClear (StoreEntry *, const char *, HttpRequest *, const HttpRequestMethod &, htcp_clr_reason)
CachePeerpeerFindByName (const char *)
CachePeerpeerFindByNameAndPort (const char *, unsigned short)
CachePeergetDefaultParent (PeerSelector *)
CachePeergetRoundRobinParent (PeerSelector *)
CachePeergetWeightedRoundRobinParent (PeerSelector *)
void peerClearRRStart (void)
void peerClearRR (void)
lookup_t peerDigestLookup (CachePeer *p, PeerSelector *)
CachePeerneighborsDigestSelect (PeerSelector *)
void peerNoteDigestLookup (HttpRequest *request, CachePeer *p, lookup_t lookup)
void peerNoteDigestGone (CachePeer *p)
int neighborUp (const CachePeer *e)
const char * neighborTypeStr (const CachePeer *e)
peer_t neighborType (const CachePeer *, const AnyP::Uri &)
void peerConnectFailed (CachePeer *)
void peerConnectSucceded (CachePeer *)
void dump_peer_options (StoreEntry *, CachePeer *)
int peerHTTPOkay (const CachePeer *, PeerSelector *)
time_t peerConnectTimeout (const CachePeer *peer)
time_t positiveTimeout (const time_t timeout)
bool peerCanOpenMore (const CachePeer *p)
 Whether we can open new connections to the peer (e.g., despite max-conn) More...
bool peerHasConnAvailable (const CachePeer *p)
 Whether the peer has idle or standby connections that can be used now. More...
void peerConnClosed (CachePeer *p)
 Notifies peer of an associated connection closure. More...
CachePeerwhichPeer (const Ip::Address &from)

Function Documentation

◆ dump_peer_options()

◆ getDefaultParent()

◆ getFirstPeer()

CachePeer* getFirstPeer ( void  )

Definition at line 500 of file

References Config, and SquidConfig::peers.

Referenced by statPeerSelect().

◆ getFirstUpParent()

◆ getNextPeer()

CachePeer* getNextPeer ( CachePeer )

Definition at line 494 of file

References CachePeer::next.

Referenced by statPeerSelect().

◆ getRoundRobinParent()

◆ getSingleParent()

CachePeer* getSingleParent ( PeerSelector )

◆ getWeightedRoundRobinParent()

◆ neighborAdd()

void neighborAdd ( const char *  ,
const char *  ,
int  ,
int  ,
int  ,
int  ,

◆ neighborAddAcl()

void neighborAddAcl ( const char *  ,
const char *   

◆ neighbors_init()

◆ neighborsCount()

int neighborsCount ( PeerSelector )

Definition at line 267 of file

References Config, debugs, CachePeer::next, NULL, p, SquidConfig::peers, and peerWouldBePinged().

Referenced by peerSelectIcpPing().

◆ neighborsDigestSelect()

◆ neighborsHtcpClear()

◆ neighborsUdpAck()

◆ neighborsUdpPing()

int neighborsUdpPing ( HttpRequest ,
StoreEntry ,
IRCB callback,
PeerSelector ps,
int exprep,
int timeout 

◆ neighborType()

◆ neighborTypeStr()

const char* neighborTypeStr ( const CachePeer e)

◆ neighborUp()

◆ peerCanOpenMore()

bool peerCanOpenMore ( const CachePeer p)

◆ peerClearRR()

void peerClearRR ( void  )

Called whenever the round-robin counters need to be reset to a sane state. So far those times are:

  • On startup and reconfigure - to set the counters to sane initial settings.
  • When a CachePeer has revived from dead, to prevent the revived CachePeer being flooded with requests which it has 'missed' during the down period.

Definition at line 440 of file

References Config, CachePeer::next, NULL, p, SquidConfig::peers, and CachePeer::rr_count.

Referenced by peerAlive(), and peerClearRRLoop().

◆ peerClearRRStart()

void peerClearRRStart ( void  )

This gets called on startup and restart to kick off the CachePeer round-robin maintenance event. It ensures that no matter how many times its called no more than one event is scheduled.

Definition at line 423 of file

References NULL, and peerClearRRLoop().

Referenced by parse_peer().

◆ peerConnClosed()

◆ peerConnectFailed()

◆ peerConnectSucceded()

◆ peerConnectTimeout()

time_t peerConnectTimeout ( const CachePeer peer)
the effective connect timeout for the given peer
the effective connect timeout for this peer

Definition at line 1182 of file

References Config, CachePeer::connect_timeout_raw, SquidConfig::peer_connect, and SquidConfig::Timeout.

Referenced by Comm::Connection::connectTimeout(), PeerPoolMgr::handleOpenedConnection(), PeerPoolMgr::openNewConnection(), and peerProbeConnect().

◆ peerDigestLookup()

◆ peerFindByName()

CachePeer* peerFindByName ( const char *  )

◆ peerFindByNameAndPort()

CachePeer* peerFindByNameAndPort ( const char *  ,
unsigned  short 

◆ peerHasConnAvailable()

bool peerHasConnAvailable ( const CachePeer p)

Definition at line 226 of file

References PconnPool::count(), debugs, CachePeer::pool, and CachePeer::standby.

Referenced by peerHTTPOkay().

◆ peerHTTPOkay()

◆ peerNoteDigestGone()

void peerNoteDigestGone ( CachePeer p)

◆ peerNoteDigestLookup()

void peerNoteDigestLookup ( HttpRequest request,
CachePeer p,
lookup_t  lookup 

◆ positiveTimeout()

time_t positiveTimeout ( const time_t  timeout)
max(1, timeout)

Definition at line 1189 of file

References max().

Referenced by FwdState::connectingTimeout(), and PeerPoolMgr::handleOpenedConnection().

◆ whichPeer()






Web Site Translations