mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-01 02:05:30 +00:00
ws: rename enable_http_health_check to enable_http_health_checks
This commit is contained in:
parent
a16ce91d46
commit
88971cd870
3 changed files with 4 additions and 4 deletions
|
|
@ -72,7 +72,7 @@ pub struct NetworkConfig {
|
|||
|
||||
/// Return a HTTP 200 Ok response when receiving GET /health, but only
|
||||
/// when not running over TLS
|
||||
pub enable_http_health_check: bool,
|
||||
pub enable_http_health_checks: bool,
|
||||
}
|
||||
|
||||
impl Default for NetworkConfig {
|
||||
|
|
@ -89,7 +89,7 @@ impl Default for NetworkConfig {
|
|||
websocket_max_message_size: 64 * 1024,
|
||||
websocket_max_frame_size: 16 * 1024,
|
||||
|
||||
enable_http_health_check: false,
|
||||
enable_http_health_checks: false,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ pub const APP_VERSION: &str = env!("CARGO_PKG_VERSION");
|
|||
pub const SHARED_IN_CHANNEL_SIZE: usize = 1024;
|
||||
|
||||
pub fn run(config: Config) -> ::anyhow::Result<()> {
|
||||
if config.network.enable_tls && config.network.enable_http_health_check {
|
||||
if config.network.enable_tls && config.network.enable_http_health_checks {
|
||||
return Err(anyhow::anyhow!(
|
||||
"configuration: network.enable_tls and network.enable_http_health_check can't both be set to true"
|
||||
));
|
||||
|
|
|
|||
|
|
@ -298,7 +298,7 @@ async fn run_connection(
|
|||
)
|
||||
.await
|
||||
} else {
|
||||
if config.network.enable_http_health_check {
|
||||
if config.network.enable_http_health_checks {
|
||||
let mut peek_buf = [0u8; 11];
|
||||
|
||||
stream
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue