7#include "CivetServer.h"
9#include "prometheus/collectable.h"
10#include "prometheus/registry.h"
18 explicit Endpoint(CivetServer& server, std::string uri);
21 Endpoint(
const Endpoint&) =
delete;
22 Endpoint(Endpoint&&) =
delete;
23 Endpoint& operator=(
const Endpoint&) =
delete;
24 Endpoint& operator=(Endpoint&&) =
delete;
26 void RegisterCollectable(
const std::weak_ptr<Collectable>& collectable);
28 std::function<
bool(
const std::string&,
const std::string&)> authCB,
29 const std::string& realm);
30 void RemoveCollectable(
const std::weak_ptr<Collectable>& collectable);
32 const std::string& GetURI()
const;
36 const std::string uri_;
38 std::shared_ptr<Registry> endpoint_registry_;
39 std::unique_ptr<MetricsHandler> metrics_handler_;
40 std::unique_ptr<BasicAuthHandler> auth_handler_;