fix intermintent hang on remote server disconnect
All checks were successful
Blockstorage/repertory/pipeline/head This commit looks good
All checks were successful
Blockstorage/repertory/pipeline/head This commit looks good
This commit is contained in:
@@ -58,7 +58,7 @@ inline constexpr std::string_view REPERTORY{"repertory"};
|
||||
inline constexpr std::string_view REPERTORY_DATA_NAME{"repertory2"};
|
||||
inline constexpr std::wstring_view REPERTORY_W{L"repertory"};
|
||||
|
||||
inline constexpr std::uint64_t REPERTORY_CONFIG_VERSION{4ULL};
|
||||
inline constexpr std::uint64_t REPERTORY_CONFIG_VERSION{5ULL};
|
||||
inline constexpr std::string_view REPERTORY_MIN_REMOTE_VERSION{"2.1.0"};
|
||||
inline constexpr std::string_view RENTERD_MIN_VERSION{"2.0.0"};
|
||||
|
||||
|
@@ -37,8 +37,8 @@ inline constexpr auto default_remote_client_pool_size{20U};
|
||||
inline constexpr auto default_remote_conn_timeout_ms{3000U};
|
||||
inline constexpr auto default_remote_directory_page_size{std::size_t(100U)};
|
||||
inline constexpr auto default_remote_max_connections{20U};
|
||||
inline constexpr auto default_remote_recv_timeout_ms{3000U};
|
||||
inline constexpr auto default_remote_send_timeout_ms{1500U};
|
||||
inline constexpr auto default_remote_recv_timeout_ms{6000U};
|
||||
inline constexpr auto default_remote_send_timeout_ms{6000U};
|
||||
|
||||
namespace repertory::remote {
|
||||
struct remote_config final {
|
||||
@@ -231,7 +231,7 @@ template <> struct adl_serializer<repertory::remote::remote_config> {
|
||||
static void to_json(json &data,
|
||||
const repertory::remote::remote_config &value) {
|
||||
data[repertory::JSON_API_PORT] = value.api_port;
|
||||
data[repertory::JSON_CONNECT_TIMEOUT_MS] = value.api_port;
|
||||
data[repertory::JSON_CONNECT_TIMEOUT_MS] = value.conn_timeout_ms;
|
||||
data[repertory::JSON_ENCRYPTION_TOKEN] = value.encryption_token;
|
||||
data[repertory::JSON_HOST_NAME_OR_IP] = value.host_name_or_ip;
|
||||
data[repertory::JSON_MAX_CONNECTIONS] = value.max_connections;
|
||||
|
@@ -1097,7 +1097,7 @@ auto app_config::load() -> bool {
|
||||
}
|
||||
}
|
||||
|
||||
if (version_ == 3U || version_ == 4U) {
|
||||
if (version_ >= 3U && version_ <= 5U) {
|
||||
if (json_document.contains(JSON_REMOTE_CONFIG)) {
|
||||
auto cfg = get_remote_config();
|
||||
cfg.conn_timeout_ms = default_remote_conn_timeout_ms;
|
||||
|
Reference in New Issue
Block a user