//------------------------------------------------------------------------------ /* This file is part of clio: https://github.com/XRPLF/clio Copyright (c) 2023, the clio developers. Permission to use, copy, modify, and distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ //============================================================================== #pragma once #include "data/LedgerCacheInterface.hpp" #include "rpc/Errors.hpp" #include "util/Assert.hpp" #include "util/Taggable.hpp" #include "util/build/Build.hpp" #include "util/log/Logger.hpp" #include "util/prometheus/Http.hpp" #include "web/AdminVerificationStrategy.hpp" #include "web/ProxyIpResolver.hpp" #include "web/SubscriptionContextInterface.hpp" #include "web/dosguard/DOSGuardInterface.hpp" #include "web/interface/Concepts.hpp" #include "web/interface/ConnectionBase.hpp" #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include namespace web::impl { static constexpr auto kHEALTH_CHECK_HTML = R"html( Test page for Clio

Clio Test

This page shows Clio http(s) connectivity is working.

)html"; static constexpr auto kCACHE_CHECK_LOADED_HTML = R"html( Cache state

Cache state

Cache is fully loaded

)html"; static constexpr auto kCACHE_CHECK_NOT_LOADED_HTML = R"html( Cache state

Cache state

Cache is not yet loaded

)html"; using tcp = boost::asio::ip::tcp; /** * @brief This is the implementation class for http sessions * * @tparam Derived The derived class * @tparam HandlerType The handler class, will be called when a request is received. */ template