Skip to content

Commit

Permalink
Migrate tonic to workspace (#1161)
Browse files Browse the repository at this point in the history
### What does this PR do?

This commit migrates the `tonic` dependency to the workspace. Unfortunately
this leaves tonic-build still in shared/Cargo.toml but it's a start. Goal
here is to make upgrading tonic more achievable.
  • Loading branch information
blt authored Dec 18, 2024
1 parent b5b96b4 commit 0148bf5
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ serde = { version = "1.0", features = ["std", "derive"] }
serde_json = { version = "1.0", features = ["std"] }
thiserror = { version = "1.0" }
tokio = { version = "1.41" }
# If you update tonic, search for tonic-build in sub-crates and update their
# version.
tonic = { version = "0.9", default-features = false, features = [] }
tower = { version = "0.5", default-features = false }
tracing = { version = "0.1" }
uuid = { version = "1.11", default-features = false, features = [
Expand All @@ -34,6 +37,7 @@ uuid = { version = "1.11", default-features = false, features = [
once_cell = { version = "1.20" }
hyper = { version = "0.14", default-features = false }


[profile.release]
lto = true # Optimize our binary at link stage.
codegen-units = 1 # Increases compile time but improves optmization alternatives.
Expand Down
2 changes: 1 addition & 1 deletion integration/ducks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ tokio = { workspace = true, features = [
"net",
] }
tokio-stream = { version = "0.1", features = ["net"] }
tonic = { version = "0.9", default-features = false, features = [
tonic = { workspace = true, default-features = false, features = [
"transport",
"prost",
] }
Expand Down
4 changes: 2 additions & 2 deletions integration/shared/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ publish = false

[dependencies]
serde = { version = "1.0", features = ["derive"] }
tonic = { version = "0.9", default-features = false, features = [
tonic = { workspace = true, default-features = false, features = [
"codegen",
"prost",
"transport",
Expand All @@ -18,4 +18,4 @@ prost = "0.11"
serde_json = "1.0"

[build-dependencies]
tonic-build = "0.9"
tonic-build = { version = "0.9" }
2 changes: 1 addition & 1 deletion integration/sheepdog/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ tokio = { version = "1.41", features = [
"time",
"net",
] }
tonic = { version = "0.9", default-features = false, features = [
tonic = { workspace = true, default-features = false, features = [
"transport",
"prost",
] }
Expand Down

0 comments on commit 0148bf5

Please sign in to comment.