ClickHouse/programs/odbc-bridge/PingHandler.h

20 lines
465 B
C++

#pragma once
#include <Server/HTTP/HTTPRequestHandler.h>
namespace DB
{
/// Simple ping handler, answers "Ok." to GET request
class PingHandler : public HTTPRequestHandler
{
public:
explicit PingHandler(size_t keep_alive_timeout_) : keep_alive_timeout(keep_alive_timeout_) {}
void handleRequest(HTTPServerRequest & request, HTTPServerResponse & response, const ProfileEvents::Event & write_event) override;
private:
size_t keep_alive_timeout;
};
}