mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
20 lines
465 B
C++
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;
|
|
};
|
|
|
|
}
|