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

chore(deps): move several common dependency declarations to workspace Cargo.toml #8171

Merged
merged 1 commit into from Oct 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 18 additions & 0 deletions Cargo.toml
Expand Up @@ -77,6 +77,24 @@ members = [
"src/workspace-hack",
]

[workspace.dependencies]
# databend maintains:
openraft = { git = "https://github.com/drmingdrmer/openraft", tag = "v0.7.4-alpha.2" }
sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }

# error
anyhow = { version = "1.0.65" }
anyerror = { version = "=0.1.7" }
thiserror = { version = "1" }

# CLI
clap = { version = "3.2.22", features = ["derive", "env"] }

# serialization
prost = { version = "0.11.0" }
serde = { version = "1.0.145", features = ["derive", "rc"] }
serde_json = { version = "1.0.85", default-features = false, features = ["preserve_order"] }

[profile.release]
debug = 1
lto = "thin"
Expand Down
10 changes: 5 additions & 5 deletions src/binaries/Cargo.toml
Expand Up @@ -48,12 +48,12 @@ databend-meta = { path = "../meta/service" }
databend-query = { path = "../query/service" }

# Crates.io dependencies
anyhow = "1.0.65"
clap = { version = "3.2.22", features = ["derive", "env"] }
openraft = { git = "https://github.com/drmingdrmer/openraft", tag = "v0.7.4-alpha.2" }
anyhow = { workspace = true }
clap = { workspace = true }
openraft = { workspace = true }
sentry = "0.27.0"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
serde = { workspace = true }
serde_json = { workspace = true }
tokio-stream = "0.1.10"
tonic = "0.8.1"
tracing = "0.1.36"
Expand Down
4 changes: 2 additions & 2 deletions src/common/base/Cargo.toml
Expand Up @@ -37,13 +37,13 @@ pprof = { version = "0.10.1", features = [
"protobuf-codec",
"protobuf",
] }
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
tikv-jemalloc-ctl = { version = "0.4.2", optional = true }
tikv-jemalloc-sys = "0.4.3"
tokio = { version = "1.21.1", features = ["full"] }
tracing = "0.1.36"
uuid = { version = "1.1.2", features = ["serde", "v4"] }

[dev-dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }
rand = "0.8.3"
2 changes: 1 addition & 1 deletion src/common/building/Cargo.toml
Expand Up @@ -11,7 +11,7 @@ doctest = false
test = false

[dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }
cargo-license = "0.5.1"
cargo_metadata = "0.15.0"
git2 = { version = "0.14.4", default-features = false }
Expand Down
10 changes: 5 additions & 5 deletions src/common/exception/Cargo.toml
Expand Up @@ -13,13 +13,13 @@ test = false
[dependencies] # In alphabetical order
common-arrow = { path = "../arrow" }

anyhow = "1.0.65"
anyhow = { workspace = true }
bincode = { version = "2.0.0-rc.1", features = ["serde", "std", "alloc"] }
paste = "1.0.9"
prost = "0.11.0"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
thiserror = "1"
prost = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
thiserror = { workspace = true }
tonic = "0.8.1"

# Github dependencies
Expand Down
6 changes: 3 additions & 3 deletions src/common/grpc/Cargo.toml
Expand Up @@ -18,12 +18,12 @@ common-exception = { path = "../exception" }
# Github dependencies

# Crates.io dependencies
anyerror = "=0.1.7"
anyerror = { workspace = true }
hyper = "0.14.20"
jwt-simple = "0.11.0"
once_cell = "1.15.0"
serde = { version = "1.0.145", features = ["derive"] }
thiserror = "1"
serde = { workspace = true }
thiserror = { workspace = true }
tonic = { version = "0.8.1", features = ["transport", "codegen", "prost", "tls-roots", "tls"] }
tracing = "0.1.36"
trust-dns-resolver = { version = "0.22.0", features = ["system-config"] }
Expand Down
2 changes: 1 addition & 1 deletion src/common/http/Cargo.toml
Expand Up @@ -25,7 +25,7 @@ common-exception = { path = "../exception" }
# Crates.io dependencies
futures = "0.3.24"
poem = { version = "1", features = ["rustls"] }
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
tempfile = { version = "3.3.0", optional = true }
tracing = "0.1.36"

Expand Down
2 changes: 1 addition & 1 deletion src/common/io/Cargo.toml
Expand Up @@ -23,7 +23,7 @@ chrono = "0.4.22"
chrono-tz = "0.6.3"
lexical-core = "0.8.5"
micromarshal = "0.2.0"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }

[dev-dependencies]
rand = "0.8.5"
4 changes: 2 additions & 2 deletions src/common/metrics/Cargo.toml
Expand Up @@ -20,11 +20,11 @@ metrics-exporter-prometheus = { version = "0.11.0", default-features = false }
once_cell = "1.15.0"
parking_lot = "0.12.1"
prometheus-parse = "0.2.3"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
tracing = "0.1.36"

[dev-dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }

[dev-dependencies.tokio]
default-features = false
Expand Down
4 changes: 2 additions & 2 deletions src/common/storage/Cargo.toml
Expand Up @@ -14,7 +14,7 @@ common-base = { path = "../base" }
common-contexts = { path = "../contexts" }
common-exception = { path = "../exception" }

anyhow = "1.0.65"
anyhow = { workspace = true }
backon = "0.2.0"
globiter = "0.1.0"
once_cell = "1.15.0"
Expand All @@ -27,4 +27,4 @@ opendal = { version = "0.19", features = [
"compress",
] }
percent-encoding = "2.2.0"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
2 changes: 1 addition & 1 deletion src/common/tracing/Cargo.toml
Expand Up @@ -24,7 +24,7 @@ once_cell = "1.15.0"
opentelemetry = { version = "0.18.0", default-features = false, features = ["trace", "rt-tokio"] }
opentelemetry-jaeger = { version = "0.17.0", features = ["rt-tokio"] }
sentry-tracing = "0.27.0"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
tonic = "0.8.1"
tracing = "0.1.36"
tracing-appender = "0.2.2"
Expand Down
6 changes: 3 additions & 3 deletions src/meta/api/Cargo.toml
Expand Up @@ -23,11 +23,11 @@ common-proto-conv = { path = "../proto-conv" }
common-protos = { path = "../protos" }
common-tracing = { path = "../../common/tracing" }

anyhow = "1.0.65"
anyhow = { workspace = true }
async-trait = "0.1.57"
enumflags2 = { version = "0.7.5", features = ["serde"] }
maplit = "1.0.2"
serde_json = "1.0.85"
thiserror = "1"
serde_json = { workspace = true }
thiserror = { workspace = true }
tonic = { version = "0.8.1", features = ["transport", "codegen", "prost", "tls-roots", "tls"] }
tracing = "0.1.36"
2 changes: 1 addition & 1 deletion src/meta/app/Cargo.toml
Expand Up @@ -19,7 +19,7 @@ enumflags2 = { version = "0.7.5", features = ["serde"] }
maplit = "1.0.2"
num-derive = "0.3.3"
num-traits = "0.2.15"
serde = { version = "1.0.145", features = ["derive", "rc"] }
serde = { workspace = true }

[build-dependencies]
common-building = { path = "../../common/building" }
Expand Down
6 changes: 3 additions & 3 deletions src/meta/client/Cargo.toml
Expand Up @@ -26,10 +26,10 @@ derive_more = "0.99.17"
futures = "0.3.24"
once_cell = "1.15.0"
parking_lot = "0.12.1"
prost = "0.11.0"
prost = { workspace = true }
semver = "1.0.14"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
serde = { workspace = true }
serde_json = { workspace = true }
tonic = { version = "0.8.1", features = ["transport", "codegen", "prost", "tls-roots", "tls"] }
tracing = "0.1.36"

Expand Down
2 changes: 1 addition & 1 deletion src/meta/embedded/Cargo.toml
Expand Up @@ -30,4 +30,4 @@ tempfile = "3.3.0"
tracing = "0.1.36"

[dev-dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }
4 changes: 2 additions & 2 deletions src/meta/proto-conv/Cargo.toml
Expand Up @@ -18,13 +18,13 @@ common-protos = { path = "../protos" }
common-storage = { path = "../../common/storage" }

num = "0.4.0"
thiserror = "1"
thiserror = { workspace = true }

enumflags2 = { version = "0.7.5", features = ["serde"] }

[build-dependencies]

[dev-dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }
maplit = "1.0.2"
pretty_assertions = "1.3.0"
2 changes: 1 addition & 1 deletion src/meta/protos/Cargo.toml
Expand Up @@ -13,7 +13,7 @@ test = false
[dependencies]
num-derive = "0.3.3"
num-traits = "0.2.15"
prost = "0.11.0"
prost = { workspace = true }
tonic = { version = "0.8.1", features = ["transport", "codegen", "prost", "tls-roots", "tls"] }

[build-dependencies]
Expand Down
4 changes: 2 additions & 2 deletions src/meta/raft-store/Cargo.toml
Expand Up @@ -24,14 +24,14 @@ common-meta-types = { path = "../types" }
common-tracing = { path = "../../common/tracing" }

# crates.io deps
anyhow = "1.0.65"
anyhow = { workspace = true }
async-trait = "0.1.57"
derive_more = "0.99.17"
hostname = "0.3.1"
maplit = "1.0.2"
num = "0.4.0"
once_cell = "1.15.0"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
tracing = "0.1.36"

[dev-dependencies]
Expand Down
14 changes: 7 additions & 7 deletions src/meta/service/Cargo.toml
Expand Up @@ -39,22 +39,22 @@ common-metrics = { path = "../../common/metrics" }
common-tracing = { path = "../../common/tracing" }

# Github dependencies
sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }
sled = { workspace = true }

# Crates.io dependencies
anyerror = "=0.1.7"
anyhow = "1.0.65"
anyerror = { workspace = true }
anyhow = { workspace = true }
async-trait = "0.1.57"
backon = "0.2.0"
clap = { version = "3.2.22", features = ["derive", "env"] }
clap = { workspace = true }
futures = "0.3.24"
metrics = "0.20.1"
once_cell = "1.15.0"
poem = { version = "1", features = ["rustls"] }
prost = "0.11.0"
prost = { workspace = true }
semver = "1.0.14"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
serde = { workspace = true }
serde_json = { workspace = true }
serfig = "0.0.2"
tokio-stream = "0.1.10"
tonic = { version = "0.8.1", features = ["tls"] }
Expand Down
10 changes: 5 additions & 5 deletions src/meta/sled-store/Cargo.toml
Expand Up @@ -19,18 +19,18 @@ common-exception = { path = "../../common/exception" }
common-meta-stoerr = { path = "../stoerr" }
common-meta-types = { path = "../types" }

openraft = { git = "https://github.com/drmingdrmer/openraft", tag = "v0.7.4-alpha.2" }
sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }
openraft = { workspace = true }
sled = { workspace = true }

byteorder = "1.4.3"
once_cell = "1.15.0"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
serde = { workspace = true }
serde_json = { workspace = true }
tempfile = "3.3.0"
tracing = "0.1.36"

[dev-dependencies]
common-base = { path = "../../common/base" }
common-tracing = { path = "../../common/tracing" }

anyhow = "1.0.65"
anyhow = { workspace = true }
13 changes: 6 additions & 7 deletions src/meta/stoerr/Cargo.toml
Expand Up @@ -13,10 +13,9 @@ test = false
[dependencies]
common-exception = { path = "../../common/exception" }

sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }

anyerror = "=0.1.7"
prost = "0.11.0"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
thiserror = "1"
anyerror = { workspace = true }
prost = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
sled = { workspace = true }
thiserror = { workspace = true }
16 changes: 8 additions & 8 deletions src/meta/types/Cargo.toml
Expand Up @@ -15,23 +15,23 @@ common-exception = { path = "../../common/exception" }
common-meta-stoerr = { path = "../stoerr" }
common-storage = { path = "../../common/storage" }

openraft = { git = "https://github.com/drmingdrmer/openraft", tag = "v0.7.4-alpha.2" }
sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }
openraft = { workspace = true }
sled = { workspace = true }

anyerror = "=0.1.7"
anyerror = { workspace = true }
chrono = "0.4.22"
derive_more = "0.99.17"
enumflags2 = { version = "0.7.5", features = ["serde"] }
hex = "0.4.3"
num-derive = "0.3.3"
num-traits = "0.2.15"
once_cell = "1.15.0"
prost = "0.11.0"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
prost = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
sha1 = "0.10.5"
sha2 = "0.10.6"
thiserror = "1"
thiserror = { workspace = true }
tonic = { version = "0.8.1", features = ["transport", "codegen", "prost", "tls-roots", "tls"] }

[build-dependencies]
Expand All @@ -40,5 +40,5 @@ prost-build = "0.11.1"
tonic-build = "0.8.0"

[dev-dependencies]
anyhow = "1.0.65"
anyhow = { workspace = true }
regex = "1.6.0"
4 changes: 2 additions & 2 deletions src/query/config/Cargo.toml
Expand Up @@ -20,12 +20,12 @@ common-users = { path = "../users" }

thrift = { git = "https://github.com/datafuse-extras/thrift", tag = "v0.17.0", optional = true }

clap = { version = "3.2.22", features = ["derive", "env"] }
clap = { workspace = true }
hex = "0.4.3"
once_cell = "1.15.0"
opendal = { version = "0.19", features = ["layers-retry", "compress"], optional = true }
semver = "1.0.14"
serde = { version = "1.0.145", features = ["derive"] }
serde = { workspace = true }
serfig = "0.0.2"

[features]
Expand Down
2 changes: 1 addition & 1 deletion src/query/datablocks/Cargo.toml
Expand Up @@ -28,4 +28,4 @@ regex = "1.6.0"

[dev-dependencies]
pretty_assertions = "1.3.0"
serde_json = "1.0.85"
serde_json = { workspace = true }
4 changes: 2 additions & 2 deletions src/query/datavalues/Cargo.toml
Expand Up @@ -33,8 +33,8 @@ once_cell = "1.15.0"
ordered-float = "3.1.0"
paste = "1.0.9"
rand = { version = "0.8.5", features = ["small_rng"] }
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.85"
serde = { workspace = true }
serde_json = { workspace = true }
smallvec = { version = "1.9.0", features = ["write"] }

[dev-dependencies]
Expand Down
4 changes: 2 additions & 2 deletions src/query/expression/Cargo.toml
Expand Up @@ -31,8 +31,8 @@ match-template = "0.0.1"
num-traits = "0.2.15"
ordered-float = { version = "3.1.0", features = ["serde"] }
rust_decimal = "1.26"
serde = "1.0"
serde_json = "1.0.81"
serde = { workspace = true }
serde_json = { workspace = true }

[dev-dependencies]
common-ast = { path = "../ast" }
Expand Down