Go to the documentation of this file.
27 #if URL_CHECKSUM_DEBUG
28 static unsigned int url_checksum(
const char *url);
30 url_checksum(
const char *url)
34 static unsigned char digest[16];
38 memcpy(&ck, digest,
sizeof(ck));
49 return Pool().inUseCount();
85 if (!aLogUri || aLogUri == aStoreId)
92 #if URL_CHECKSUM_DEBUG
93 chksum = url_checksum(
urlXXX());
99 debugs(20, 3,
"MemObject constructed, this=" <<
this);
107 debugs(20, 3,
"MemObject destructed, this=" <<
this);
109 #if URL_CHECKSUM_DEBUG
140 debugs(19, 6,
"memWrite: offset " << writeBuffer.
offset <<
" len " << writeBuffer.
length);
212 for_each<StoreClientStats>(
clients, statsVisitor);
256 debugs(20, 7,
"unknown; hdr: " << hdr_sz);
260 const auto messageSize = clen + hdr_sz;
261 debugs(20, 7, messageSize <<
" hdr: " << hdr_sz <<
" clen: " << clen);
283 for_each <LowestMemReader>(
clients, lowest);
293 const bool canRead =
endOffset() - savedHttpHeaders <
311 #if URL_CHECKSUM_DEBUG
313 MemObject::checkUrlChecksum ()
const
361 return lowest_offset;
381 new_mem_lo = on_disk - 1;
383 if (new_mem_lo == -1)
406 debugs (19, result ? 4 :3,
"MemObject::isContiguous: Returning " << (result ?
"true" :
"false"));
414 if (!ignoreDelayPools) {
420 (void)ignoreDelayPools;
433 sc->delayId.setNoDelay(newValue);
446 mostAllowedId.delayRead(aRead);
471 j =
sc->bytesWanted();
475 result =
sc->delayId;
int64_t freeDataUpto(int64_t)
int64_t queue_offset
number of bytes sent to SwapDir for writing
HttpReply & adjustableBaseReply()
bool readAheadPolicyCanRead() const
void dlinkAdd(void *data, dlink_node *m, dlink_list *list)
LowestMemReader(int64_t seed)
void appendf(const char *fmt,...) PRINTF_FORMAT_ARG2
Append operation with printf-style arguments.
StoreClientStats(MemBuf *anEntry)
SQUIDCEXTERN void SquidMD5Init(struct SquidMD5Context *context)
const char * storeId() const
String storeId_
StoreId for our entry (usually request URI)
int mostBytesWanted(int max, bool ignoreDelayPools) const
struct timeval start_ping
int bytesWanted(int min, int max) const
DelayedAsyncCalls deferredReads
int64_t offset
bytes written/read to/from the memory cache so far
int64_t bodySize(const HttpRequestMethod &) const
MemCache memCache
current [shared] memory caching state for the entry
StoreIOState::Pointer sio
void delay(const AsyncCallPointer &)
stores the given call to schedule it at schedule() or destruction time
void setNoDelay(bool const newValue)
int64_t expectedReplySize() const
DelayId mostBytesAllowed() const
bool isContiguous() const
const SBuf & image() const
bool write(StoreIOBuffer const &)
int64_t endOffset() const
SQUIDCEXTERN void SquidMD5Final(uint8_t digest[16], struct SquidMD5Context *context)
int64_t availableForSwapOut() const
buffered bytes we have not swapped out yet
RemovalPolicy * mem_policy
A const & max(A const &lhs, A const &rhs)
void replaceBaseReply(const HttpReplyPointer &r)
int64_t endOffset() const
const char * logUri() const
client request URI used for logging; storeId() by default
void operator()(store_client const &x)
int64_t readOffset() const
#define SQUIDSBUFPRINT(s)
const HttpReply & baseReply() const
int64_t policyLowestOffsetToKeep(bool swap) const
int32_t index
entry position inside the in-transit table
void write(const StoreIOBuffer &buf)
XitTable xitTable
current [shared] memory caching state for the entry
char const * termedBuf() const
void schedule()
schedules and forgets all async calls previously stored by delay()
static size_t inUseCount()
void delayRead(const AsyncCallPointer &)
String logUri_
URI used for logging (usually request URI)
void markEndOfReplyHeaders()
sets baseReply().hdr_sz (i.e. written reply headers size) to endOffset()
bool hasContigousContentRange(Range< int64_t > const &range) const
int32_t index
entry position inside the memory cache
struct SquidConfig::@110 onoff
bool hasUris() const
whether setUris() has been called
void dumpStats(MemBuf *output, int clientNumber) const
void addClient(store_client *)
HttpReplyPointer updatedReply_
SQUIDCEXTERN void SquidMD5Update(struct SquidMD5Context *context, const void *buf, unsigned len)
int64_t lowestMemReaderOffset() const
const char * urlXXX() const
IRCB * ping_reply_callback
A const & min(A const &lhs, A const &rhs)
int64_t objectBytesOnDisk() const
#define debugs(SECTION, LEVEL, CONTENT)
void stat(MemBuf *mb) const
HttpRequestPointer request
void setUris(char const *aStoreId, char const *aLogUri, const HttpRequestMethod &aMethod)
void operator()(store_client const &x)
struct SquidConfig::@108 Store