-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make interrupting by Ctrl-C more reliable
The retrying logic made Ctrl-C handling a bit broken, because the streams could be terminated only at the complete cycles. If a query retries for a long time it prevented terminating the program. This commit implements interruption logic in a different way, by using tokio::signal and tokio::select! so all streams are terminated immediately, regardless of their progress.
- Loading branch information
Showing
8 changed files
with
51 additions
and
100 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
[package] | ||
name = "latte-cli" | ||
description = "A database benchmarking tool for Apache Cassandra" | ||
version = "0.26.0" | ||
version = "0.27.0" | ||
authors = ["Piotr Kołaczkowski <[email protected]>"] | ||
edition = "2021" | ||
readme = "README.md" | ||
|
@@ -21,7 +21,6 @@ chrono = { version = "0.4.18", features = ["serde"] } | |
clap = { version = "4", features = ["derive", "cargo", "env"] } | ||
console = "0.15.0" | ||
cpu-time = "1.0.0" | ||
ctrlc = "3.2.1" | ||
err-derive = "0.3" | ||
futures = "0.3" | ||
hdrhistogram = "7.1.0" | ||
|
@@ -39,7 +38,7 @@ rand = "0.8" | |
regex = "1.5" | ||
rune = "0.12" | ||
rust-embed = "8" | ||
scylla = { version = "0.13", features = ["ssl"] } | ||
scylla = { path = "../scylla-rust-driver/scylla", features = ["ssl"] } | ||
search_path = "0.1" | ||
serde = { version = "1.0.116", features = ["derive"] } | ||
serde_json = "1.0.57" | ||
|
@@ -49,7 +48,7 @@ strum = { version = "0.26", features = ["derive"] } | |
strum_macros = "0.26" | ||
time = "0.3" | ||
thiserror = "1.0.26" | ||
tokio = { version = "1", features = ["rt", "rt-multi-thread", "time", "parking_lot"] } | ||
tokio = { version = "1", features = ["rt", "rt-multi-thread", "time", "parking_lot", "signal"] } | ||
tokio-stream = "0.1" | ||
tracing = "0.1" | ||
tracing-subscriber = "0.3" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.