aboutsummaryrefslogtreecommitdiff
path: root/zenserver/monitoring/httpstats.cpp
blob: a82cfda500f13309faac1995bd047b41903882a5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
// Copyright Epic Games, Inc. All Rights Reserved.

#include "httpstats.h"

namespace zen {

HttpStatsService::HttpStatsService() : m_Log(logging::Get("stats"))
{
}

HttpStatsService::~HttpStatsService()
{
}

const char*
HttpStatsService::BaseUri() const
{
	return "/stats/";
}

void
HttpStatsService::HandleRequest(HttpServerRequest& Request)
{
	using namespace std::literals;

	switch (Request.RequestVerb())
	{
		case HttpVerb::kGet:
			return Request.WriteResponse(HttpResponseCode::OK, HttpContentType::kText, u8"OK!"sv);
	}
}

}  // namespace zen