Inquirer.cc
Go to the documentation of this file.
void CallService(const CodeContext::Pointer &serviceContext, Fun &&service)
Definition: CodeContext.h:133
void CallBack(const CodeContext::Pointer &callbackContext, Fun &&callback)
Definition: CodeContext.h:116
Definition: AsyncJob.h:32
virtual void callException(const std::exception &e)
called when the job throws during an async call
Definition: AsyncJob.cc:143
Definition: CbcPointer.h:26
Definition: CodeContext.h:53
Definition: Inquirer.h:28
static void RequestTimedOut(void *param)
Ipc::Inquirer::requestTimedOut wrapper.
Definition: Inquirer.cc:194
virtual void handleException(const std::exception &e)
do specific exception handling
Definition: Inquirer.cc:152
const char * status() const override
internal cleanup; do not call directly
Definition: Inquirer.cc:220
Inquirer(Request::Pointer aRequest, const Ipc::StrandCoords &coords, double aTimeout)
Definition: Inquirer.cc:65
void callException(const std::exception &e) override
called when the job throws during an async call
Definition: Inquirer.cc:159
static void HandleRemoteAck(const Response &response)
finds and calls the right Inquirer upon strand's response
Definition: Inquirer.cc:171
void removeTimeoutEvent()
called when we are no longer waiting for the strand to respond
Definition: Inquirer.cc:186
void requestTimedOut()
called when the strand failed to respond (or finish responding) in time
Definition: Inquirer.cc:207
void handleRemoteAck(Response::Pointer response)
called when a strand is done writing its output
Definition: Inquirer.cc:118
static String MakeAddr(const char *proccessLabel, int id)
calculates IPC message address for strand id of processLabel type
Definition: Port.cc:52
struct msghdr with a known type, fixed-size I/O and control buffers
Definition: TypedMsgHdr.h:35
Definition: MemBuf.h:24
void appendf(const char *fmt,...) PRINTF_FORMAT_ARG2
Append operation with printf-style arguments.
Definition: Packable.h:61
STL Allocator that uses Squid memory pools for memory management.
Definition: PoolingAllocator.h:19
void eventAdd(const char *name, EVH *func, void *arg, double when, int weight, bool cbdata)
Definition: event.cc:107
static bool LesserStrandByKidId(const Ipc::StrandCoord &c1, const Ipc::StrandCoord &c2)
compare Ipc::StrandCoord using kidId, for std::sort() below
Definition: Inquirer.cc:60
Definition: IpcIoFile.h:24
void SendMessage(const String &toAddress, const TypedMsgHdr &message)
Definition: UdsOp.cc:188
std::unordered_map< RequestId::Index, InquirerPointer, std::hash< RequestId::Index >, std::equal_to< RequestId::Index >, PoolingAllocator< WaitingInquiriesItem > > WaitingInquiries
Definition: Inquirer.cc:36
std::pair< const RequestId::Index, InquirerPointer > WaitingInquiriesItem
Definition: Inquirer.cc:30
static InquirerPointer DequeueRequest(const RequestId::Index requestId)
returns and forgets the Inquirer waiting for the given requests
Definition: Inquirer.cc:43
static WaitingInquiries TheWaitingInquirers
pending Inquirer requests for this process
Definition: Inquirer.cc:39
CbcPointer< Inquirer > InquirerPointer
maps request->id to the Inquirer waiting for the response to that request
Definition: Inquirer.cc:29
std::vector< StrandCoord > StrandCoords
a collection of strand coordinates; the order, if any, is owner-dependent
Definition: StrandCoords.h:19