Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make controller RPC timeout configurable #101

Merged
merged 3 commits into from
Oct 2, 2023

Conversation

hikinggrass
Copy link
Contributor

Also make it available to the admin panel

@hikinggrass hikinggrass requested a review from a-w50 September 28, 2023 10:31
Comment on lines +243 to +249
const auto settings_controller_rpc_timeout_ms_it = settings.find("controller_rpc_timeout_ms");
if (settings_controller_rpc_timeout_ms_it != settings.end()) {
controller_rpc_timeout_ms = settings_controller_rpc_timeout_ms_it->get<int>();
} else {
controller_rpc_timeout_ms = defaults::CONTROLLER_RPC_TIMEOUT_MS;
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how about
controller_rpc_timeout_ms = settings.value("controller_rpc_timeout_ms", defaults::CONTROLLER_RPC_TIMEOUT_MS);?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good idea, right now it just follows the style of the surrounding code, we should probably refactor this in a different PR though

src/controller/rpc.cpp Outdated Show resolved Hide resolved
Also make it available to the admin panel

Signed-off-by: Kai-Uwe Hermann <kai-uwe.hermann@pionix.de>
Signed-off-by: Kai-Uwe Hermann <kai-uwe.hermann@pionix.de>
@hikinggrass hikinggrass force-pushed the kh-configurable-rpc-timeout branch from 8e6cf60 to cea732d Compare October 2, 2023 12:25
Signed-off-by: Kai-Uwe Hermann <kai-uwe.hermann@pionix.de>
@hikinggrass hikinggrass merged commit 7fcf0ac into main Oct 2, 2023
2 of 3 checks passed
@hikinggrass hikinggrass deleted the kh-configurable-rpc-timeout branch October 2, 2023 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants