10#include <userver/utils/not_null.hpp>
12USERVER_NAMESPACE_BEGIN
14namespace clients::
http {
21class PluginRequest
final {
24 explicit PluginRequest(RequestState& state);
27 void SetHeader(std::string_view name, std::string_view value);
29 void AddQueryParams(std::string_view params);
31 void SetTimeout(std::chrono::milliseconds ms);
40 explicit Plugin(std::string name);
42 virtual ~Plugin() =
default;
64 const std::string name_;
69class PluginPipeline
final {
71 PluginPipeline(
const std::vector<utils::NotNull<Plugin*>>& plugins);
73 void HookPerformRequest(RequestState& request);
75 void HookCreateSpan(RequestState& request);
77 void HookOnCompleted(RequestState& request, Response& response);
80 const std::vector<utils::NotNull<Plugin*>> plugins_;