Squid Web Cache master
Loading...
Searching...
No Matches
HierarchyLogEntry.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 1996-2025 The Squid Software Foundation and contributors
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
9#ifndef SQUID_SRC_HIERARCHYLOGENTRY_H
10#define SQUID_SRC_HIERARCHYLOGENTRY_H
11
12#include "base/Stopwatch.h"
13#include "comm/Connection.h"
14#include "enums.h"
15#include "hier_code.h"
16#include "http/StatusCode.h"
17#include "lookup_t.h"
18#include "PingData.h"
19#include "rfc2181.h"
20
24{
25
26public:
28
31 void resetPeerNotes(const Comm::ConnectionPointer &server, const char *requestedHost);
32
35 void notePeerRead();
36
39 void notePeerWrite();
40
43 bool peerResponseTime(struct timeval &responseTime);
44
45public:
49 char cd_host[SQUIDHOSTNAMELEN]; /* the host of selected by cd peer */
50 lookup_t cd_lookup; /* cd prediction: none, miss, hit */
51 int n_choices; /* #peers we selected from (cd only) */
52 int n_ichoices; /* #peers with known rtt we selected from (cd only) */
53
54 struct timeval peer_select_start;
55
56 struct timeval store_complete_stop;
57
60 int64_t bodyBytesRead;
61
64
65private:
66 void clearPeerNotes();
67
68 struct timeval peer_last_read_;
69 struct timeval peer_last_write_;
70};
71
72#endif /* SQUID_SRC_HIERARCHYLOGENTRY_H */
73
static char server[MAXLINE]
char host[SQUIDHOSTNAMELEN]
struct timeval peer_select_start
void clearPeerNotes()
forget previous notePeerRead() and notePeerWrite() calls (if any)
struct timeval peer_last_write_
time of the last write to the last peer
Stopwatch totalPeeringTime
cumulative time spent (so far) communicating with all peers (see %<tt)
struct timeval store_complete_stop
int64_t bodyBytesRead
number of body bytes received from the next hop or -1
Http::StatusCode peer_reply_status
last HTTP status code received
Comm::ConnectionPointer tcpServer
TCP/IP level details of the last peer/server connection.
char cd_host[SQUIDHOSTNAMELEN]
bool peerResponseTime(struct timeval &responseTime)
struct timeval peer_last_read_
time of the last read from the last peer
void resetPeerNotes(const Comm::ConnectionPointer &server, const char *requestedHost)
ICP probing of cache_peers during peer selection.
Definition PingData.h:26
hier_code
Definition hier_code.h:12
lookup_t
Definition lookup_t.h:12
StatusCode
Definition StatusCode.h:20
#define SQUIDHOSTNAMELEN
Definition rfc2181.h:30