|
Squid Web Cache master
|
#include "acl/ChecklistFiller.h"#include "base/AsyncCall.h"#include "base/forward.h"#include "dlink.h"#include "store/ParsingBuffer.h"#include "StoreIOBuffer.h"#include "StoreIOState.h"#include "DelayId.h"Go to the source code of this file.
Classes | |
| class | StoreClient |
| a storeGetPublic*() caller More... | |
| class | store_client |
| struct | store_client::Callback |
Typedefs | |
| using | STCB = void(void *, StoreIOBuffer) |
Functions | |
| void | storeClientCopy (store_client *, StoreEntry *, StoreIOBuffer, STCB *, void *) |
| store_client * | storeClientListAdd (StoreEntry *e, void *data) |
| int | storeUnregister (store_client *sc, StoreEntry *e, void *data) |
| int | storePendingNClients (const StoreEntry *e) |
| int | storeClientIsThisAClient (store_client *sc, void *someClient) |
| using STCB = void (void *, StoreIOBuffer) |
A storeClientCopy() callback function.
Upon storeClientCopy() success, StoreIOBuffer::flags.error is zero, and
STCB callbacks may use response semantics to detect certain EOF conditions. Callbacks that expect HTTP headers may call store_client::atEof(). Similar to clientStreamCallback() callbacks, callbacks dedicated to receiving HTTP bodies may use zero StoreIOBuffer::length as an EOF condition.
Errors are indicated by setting StoreIOBuffer flags.error.
Definition at line 32 of file StoreClient.h.
| void storeClientCopy | ( | store_client * | sc, |
| StoreEntry * | e, | ||
| StoreIOBuffer | copyInto, | ||
| STCB * | callback, | ||
| void * | data | ||
| ) |
Asynchronously read HTTP response headers and/or body bytes from Store.
The requested zero-based HTTP body offset is specified via the StoreIOBuffer::offset field. The first call (for a given store_client object) must specify zero offset.
The requested HTTP body portion size is specified via the StoreIOBuffer::length field. The function may return fewer body bytes.
See STCB for result delivery details.
Definition at line 224 of file store_client.cc.
References assert, and store_client::copy().
Referenced by netdbExchangeHandleReply(), netdbExchangeStart(), peerDigestHandleReply(), peerDigestRequest(), Mgr::StoreToCommWriter::scheduleStoreCopy(), UrnState::start(), and urnHandleReply().
| int storeClientIsThisAClient | ( | store_client * | sc, |
| void * | someClient | ||
| ) |
Referenced by clientReplyContext::processExpired().
| store_client * storeClientListAdd | ( | StoreEntry * | e, |
| void * | data | ||
| ) |
Definition at line 124 of file store_client.cc.
References MemObject::addClient(), assert, StoreEntry::mem_obj, and NULL.
Referenced by Ssl::ServerBump::ServerBump(), clientReplyContext::createStoreEntry(), clientReplyContext::doGetMoreData(), netdbExchangeStart(), peerDigestRequest(), clientReplyContext::processExpired(), clientReplyContext::setReplyToStoreEntry(), Mgr::StoreToCommWriter::start(), and UrnState::start().
| int storePendingNClients | ( | const StoreEntry * | e | ) |
Definition at line 890 of file store_client.cc.
References debugs, StoreEntry::mem_obj, and MemObject::nclients.
Referenced by CheckQuickAbortIsReasonable(), FwdState::completed(), StoreEntry::doAbandon(), and statStoreEntry().
| int storeUnregister | ( | store_client * | sc, |
| StoreEntry * | e, | ||
| void * | data | ||
| ) |
Definition at line 765 of file store_client.cc.
References store_client::_callback, StoreEntry::abort(), assert, store_client::Callback::callback_handler, AsyncCall::cancel(), cbdataReferenceDone, CheckQuickAbortIsReasonable(), MemObject::clientCount(), MemObject::clients, debugs, dlinkDelete(), StoreEntry::getMD5Text(), StatCounters::ins, StoreEntry::kickProducer(), MemObject::kickReads(), StoreEntry::lock(), StoreEntry::mem_obj, MemObject::nclients, store_client::node, store_client::Callback::notifier, StoreIOState::readerDone, statCounter, STORE_OK, StoreEntry::store_status, storeClose(), StatCounters::swap, store_client::swapin_sio, StoreEntry::swapOut(), StoreEntry::swapoutFailed(), StoreEntry::swappedOut(), and StoreEntry::unlock().
Referenced by DigestFetchState::~DigestFetchState(), netdbExchangeState::~netdbExchangeState(), Ssl::ServerBump::~ServerBump(), UrnState::~UrnState(), peerDigestFetchReply(), clientReplyContext::removeStoreReference(), and Mgr::StoreToCommWriter::swanSong().