]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/snmp/Inquirer.h
2946c76a044d6dc3d07681665459805d2a7c11b1
2 * Copyright (C) 1996-2016 The Squid Software Foundation and contributors
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.
9 /* DEBUG: section 49 SNMP Interface */
11 #ifndef SQUID_SNMPX_INQUIRER_H
12 #define SQUID_SNMPX_INQUIRER_H
14 #include "comm/forward.h"
15 #include "ipc/Inquirer.h"
16 #include "snmp/forward.h"
19 class CommCloseCbParams
;
24 /// Coordinator's job that sends a PDU request to each strand,
25 /// aggregates strand responses and send back the result to client
26 class Inquirer
: public Ipc::Inquirer
28 CBDATA_CLASS(Inquirer
);
31 Inquirer(const Request
& aRequest
, const Ipc::StrandCoords
& coords
);
36 virtual bool doneAll() const;
38 /* Ipc::Inquirer API */
39 virtual void cleanup();
40 virtual void handleException(const std::exception
& e
);
41 virtual void sendResponse();
42 virtual bool aggregate(Ipc::Response::Pointer aResponse
);
45 void noteCommClosed(const CommCloseCbParams
& params
);
48 Pdu aggrPdu
; ///< aggregated pdu
49 Comm::ConnectionPointer conn
; ///< client connection descriptor
51 AsyncCall::Pointer writer
; ///< comm_write callback
52 AsyncCall::Pointer closer
; ///< comm_close handler
57 #endif /* SQUID_SNMPX_INQUIRER_H */