diff --git a/CHANGELOG.md b/CHANGELOG.md index f346b18..f37c46d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## 0.7.1 +- Fixed high CPU usage when polling data from a Logstash diagnostic path (`--diagnostic-path`). + ## 0.7.0 - Logstash APIs are now fetched concurrently, improving the overall performance, and reducing UI lags when pipelines are too complex or contains several components. [#12](https://github.com/edmocosta/tuistash/pull/12) diff --git a/Cargo.lock b/Cargo.lock index ec59a35..68a7b9c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -785,7 +785,7 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tuistash" -version = "0.7.0" +version = "0.7.1" dependencies = [ "base64", "clap", diff --git a/Cargo.toml b/Cargo.toml index e60712d..3fe1ea1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -7,7 +7,7 @@ documentation = "https://github.com/edmocosta/tuistash" keywords = ["logstash", "tui", "cli", "terminal"] categories = ["command-line-utilities"] authors = ["Edmo Vamerlatti Costa "] -version = "0.7.0" +version = "0.7.1" edition = "2021" [dependencies] diff --git a/src/cli/commands/tui/backend.rs b/src/cli/commands/tui/backend.rs index 965aeb8..270d9c9 100644 --- a/src/cli/commands/tui/backend.rs +++ b/src/cli/commands/tui/backend.rs @@ -96,10 +96,11 @@ fn run_app(terminal: &mut Terminal, mut app: App) -> io::Result<( if app.sampling_interval.is_some() && last_tick.elapsed() >= tick_interval { app.on_tick(); - last_tick = Instant::now(); } if app.should_quit { return Ok(()); } + + last_tick = Instant::now(); } }