ServiceRep.h
Go to the documentation of this file.
78 virtual Initiate *makeXactLauncher(Http::Message *virginHeader, HttpRequest *virginCause, AccessLogEntry::Pointer &alp);
89 void putConnection(const Comm::ConnectionPointer &conn, bool isReusable, bool sendReset, const char *comment);
199 ConnWaiterDialer(const CbcPointer<Adaptation::Icap::ModXact> &xact, Adaptation::Icap::ConnWaiterDialer::Parent::Method aHandler);
Definition: Initiate.h:31
~ConnWaiterDialer()
Definition: ServiceRep.cc:755
void noteNewWaiter()
New xaction waiting for service to be up or available.
Definition: ServiceRep.h:95
virtual Initiate * makeXactLauncher(Http::Message *virginHeader, HttpRequest *virginCause, AccessLogEntry::Pointer &alp)
Definition: ServiceRep.cc:682
Definition: Service.h:28
int availableConnections() const
Definition: ServiceRep.cc:200
bool connOverloadReported
whether we reported exceeding theMaxConnections
Definition: ServiceRep.h:141
void callWhenAvailable(AsyncCall::Pointer &cb, bool priority=false)
Definition: ServiceRep.cc:413
ServiceRep(const ServiceConfigPointer &aConfig)
Definition: ServiceRep.cc:34
Security::SessionStatePointer sslSession
Definition: ServiceRep.h:114
void startGettingOptions()
Definition: ServiceRep.cc:608
ICAP::Method parseMethod(const char *) const
Definition: pconn.h:38
void noteConnectionFailed(const char *comment)
Definition: ServiceRep.cc:179
ICAP::VectPoint parseVectPoint(const char *) const
virtual void callException(const std::exception &e)
called when the job throws during an async call
Definition: ServiceRep.cc:578
ServiceRep::Pointer theService
Definition: ServiceRep.h:198
AsyncCall::Pointer callback
Definition: ServiceRep.h:121
virtual void noteAdaptationAnswer(const Answer &answer)
Definition: ServiceRep.cc:548
Definition: HttpRequest.h:49
bool availableForOld() const
a transaction notified about connection slot availability may start communicating with the service
Definition: ServiceRep.cc:317
Definition: AsyncJobCalls.h:91
ConnWaiterDialer(const CbcPointer< Adaptation::Icap::ModXact > &xact, Adaptation::Icap::ConnWaiterDialer::Parent::Method aHandler)
Definition: ServiceRep.cc:741
void scheduleUpdate(time_t when)
Definition: ServiceRep.cc:620
void putConnection(const Comm::ConnectionPointer &conn, bool isReusable, bool sendReset, const char *comment)
Definition: ServiceRep.cc:147
bool wantsUrl(const SBuf &urlPath) const
Definition: ServiceRep.cc:325
void noteConnectionUse(const Comm::ConnectionPointer &conn)
Definition: ServiceRep.cc:173
std::map< OptionName, const Option *, OptionNameCmp > Options
name:option map
Definition: Options.h:159
void callWhenReady(AsyncCall::Pointer &cb)
Definition: ServiceRep.cc:431
Security::ContextPointer sslContext
Definition: ServiceRep.h:113
bool existWaiters() const
if there are xactions waiting for the service to be available
Definition: ServiceRep.h:97
void noteGoneWaiter()
An xaction is not waiting any more for service to be available.
Definition: ServiceRep.cc:239
void scheduleNotification()
Definition: ServiceRep.cc:454
Definition: Options.h:26
std::deque< Client > theNotificationWaiters
Definition: ServiceRep.h:134
time_t optionsFetchTime() const
Definition: ServiceRep.cc:658
summarizes adaptation service answer for the noteAdaptationAnswer() API
Definition: Answer.h:23
Definition: Initiator.h:29
bool wantsPreview(const SBuf &urlPath, size_t &wantedSize) const
Definition: ServiceRep.cc:331
Comm::ConnectionPointer getConnection(bool isRetriable, bool &isReused)
Definition: ServiceRep.cc:117
std::unique_ptr< SSL_SESSION, HardFun< void, SSL_SESSION *, &SSL_SESSION_free > > SessionStatePointer
Definition: Session.h:48
Counts events, forgetting old ones. Useful for "3 errors/minute" limits.
Definition: FadingCounter.h:16
FadingCounter theSessionFailures
Definition: ServiceRep.h:144
void changeOptions(Options *newOptions)
Definition: ServiceRep.cc:465
CBDATA_CLASS(ServiceRep)
bool availableForNew() const
a new transaction may start communicating with the service
Definition: ServiceRep.cc:307
bool needNewOptions() const
Definition: ServiceRep.cc:460
void setMaxConnections()
Set the maximum allowed connections for the service.
Definition: ServiceRep.cc:185
NullaryMemFunT< ModXact > Parent
Definition: ServiceRep.h:197
CbcPointer< Adaptation::Initiate > theOptionsFetcher
Definition: ServiceRep.h:129
int excessConnections() const
The number of connections which excess the Max-Connections limit.
Definition: ServiceRep.cc:224
void handleNewOptions(Options *newOptions)
Definition: ServiceRep.cc:586
void announceStatusChange(const char *downPhrase, bool important) const
Definition: ServiceRep.cc:533
Definition: ServiceRep.h:61
Definition: AccessCheck.h:25
Definition: ModXact.h:142