userver: userver/congestion_control/controllers/linear_config.hpp Source File
Loading...
Searching...
No Matches
linear_config.hpp
1#pragma once
2
3#include <chrono>
4#include <cstddef>
5
6#include <userver/dynamic_config/snapshot.hpp>
7
8USERVER_NAMESPACE_BEGIN
9
10namespace congestion_control::v2 {
11
12struct Config {
13 double errors_threshold_percent{5.0}; // 5%
14 std::size_t safe_delta_limit{10};
15 std::size_t timings_burst_threshold{5};
16 std::chrono::milliseconds min_timings{20};
17 std::size_t min_limit{10};
18 std::size_t min_qps{10};
19};
20
21Config Parse(const formats::json::Value& value, formats::parse::To<Config>);
22
23} // namespace congestion_control::v2
24
25USERVER_NAMESPACE_END