Forwarder.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2019 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 /* DEBUG: section 16 Cache Manager API */
10 
11 #ifndef SQUID_MGR_FORWARDER_H
12 #define SQUID_MGR_FORWARDER_H
13 
14 #include "comm/forward.h"
15 #include "ipc/Forwarder.h"
16 #include "log/forward.h"
17 #include "mgr/ActionParams.h"
18 
19 class CommCloseCbParams;
20 class HttpRequest;
21 class StoreEntry;
22 class ErrorState;
23 
24 namespace Mgr
25 {
26 
32 {
34 
35 public:
36  Forwarder(const Comm::ConnectionPointer &aConn, const ActionParams &aParams, HttpRequest* aRequest,
37  StoreEntry* anEntry, const AccessLogEntryPointer &anAle);
38  virtual ~Forwarder();
39 
40 protected:
41  /* Ipc::Forwarder API */
42  virtual void swanSong();
43  virtual void handleError();
44  virtual void handleTimeout();
45  virtual void handleException(const std::exception& e);
46 
47 private:
48  void noteCommClosed(const CommCloseCbParams& params);
49  void sendError(ErrorState* error);
50 
51 private:
57 };
58 
59 } // namespace Mgr
60 
61 #endif /* SQUID_MGR_FORWARDER_H */
62 
virtual void handleTimeout()
Definition: Forwarder.cc:81
AccessLogEntryPointer ale
more transaction details
Definition: Forwarder.h:56
void error(char *format,...)
Forwarder(const Comm::ConnectionPointer &aConn, const ActionParams &aParams, HttpRequest *aRequest, StoreEntry *anEntry, const AccessLogEntryPointer &anAle)
Definition: Forwarder.cc:29
Cache Manager Action parameters extracted from the user request.
Definition: ActionParams.h:23
AsyncCall::Pointer closer
comm_close handler for the HTTP connection
Definition: Forwarder.h:55
virtual void swanSong()
closes our copy of the client HTTP connection socket
Definition: Forwarder.cc:59
HttpRequest * httpRequest
HTTP client request for detailing errors.
Definition: Forwarder.h:52
virtual void handleException(const std::exception &e)
terminate with an error
Definition: Forwarder.cc:88
virtual void handleError()
Definition: Forwarder.cc:73
virtual ~Forwarder()
Definition: Forwarder.cc:47
void noteCommClosed(const CommCloseCbParams &params)
called when the client socket gets closed by some external force
Definition: Forwarder.cc:97
void sendError(ErrorState *error)
send error page
Definition: Forwarder.cc:106
CBDATA_CLASS(Forwarder)
StoreEntry * entry
Store entry expecting the response.
Definition: Forwarder.h:53
Cache Manager API.
Definition: Action.h:19
Comm::ConnectionPointer conn
HTTP client connection descriptor.
Definition: Forwarder.h:54

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors