Skip to content

Commit

Permalink
use workspace for dependencies (#240)
Browse files Browse the repository at this point in the history
  • Loading branch information
fanatid authored Nov 17, 2023
1 parent 9ecf8d2 commit c2a76f3
Show file tree
Hide file tree
Showing 9 changed files with 153 additions and 91 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ The minor version will be incremented upon a breaking change and the patch versi

### Features

- use workspace for dependencies ([#240](https://github.com/rpcpool/yellowstone-grpc/pull/240))

### Breaking

## 2023-11-14
Expand Down
16 changes: 8 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

45 changes: 45 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,56 @@ license = "Apache-2.0"
keywords = ["solana"]

[workspace.dependencies]
anyhow = "1.0.62"
async-trait = "0.1.73"
atty = "0.2.14"
backoff = { version = "0.4.0", features = ["tokio"] }
base64 = "0.21.0"
bincode = "1.3.3"
bs58 = "0.4.0"
bytes = "1.3.0"
cargo-lock = "9.0.0"
chrono = "0.4.26"
clap = { version = "4.3.0", features = ["cargo", "derive"] }
const-hex = "1.6.2"
crossbeam-channel = "0.5.8"
env_logger = "0.10.0"
futures = "0.3.24"
git-version = "0.3.5"
google-cloud-googleapis = "0.11.0"
google-cloud-pubsub = "0.21.0"
hex = "0.4.3"
http = "0.2.8"
hyper = { version = "0.14.27", features = ["server"] }
json5 = "0.4.1"
lazy_static = "1.4.0"
log = "0.4.17"
maplit = "1.0.2"
prometheus = "0.13.2"
prost = "0.12.1"
protobuf-src = "1.1.0"
rdkafka = { version = "0.34.0", features = ["sasl"] }
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.86"
serde_yaml = "0.9.25"
sha2 = "0.10.7"
solana-account-decoder = "=1.17.5"
solana-geyser-plugin-interface = "=1.17.5"
solana-logger = "=1.17.5"
solana-sdk = "=1.17.5"
solana-transaction-status = "=1.17.5"
spl-token-2022 = { version = "0.9.0", features = ["no-entrypoint"] }
thiserror = "1.0"
tokio = { version = "1.21.2", features = ["rt-multi-thread", "macros", "time", "fs", "signal"] }
tokio-stream = "0.1.11"
tonic = { version = "0.10.2", features = ["gzip", "tls", "tls-roots"] }
tonic-build = "0.10.2"
tonic-health = "0.10.2"
tracing = "0.1.37"
tracing-subscriber = { version = "0.3.17", features = ["env-filter"] }
vergen = { version = "8.2.1", features = ["build", "rustc"] }
yellowstone-grpc-client = { path = "yellowstone-grpc-client", version = "=1.12.0+solana.1.17.5" }
yellowstone-grpc-proto = { path = "yellowstone-grpc-proto", version = "=1.11.0+solana.1.17.5" }

[profile.release]
debug = true
Expand Down
30 changes: 15 additions & 15 deletions examples/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,20 @@ publish = false
name = "client"

[dependencies]
anyhow = "1.0.62"
backoff = { version = "0.4.0", features = ["tokio"] }
bincode = "1.3.3"
bs58 = "0.4.0"
chrono = "0.4.26"
clap = { version = "4.3.0", features = ["cargo", "derive"] }
env_logger = "0.10.0"
futures = "0.3.24"
hex = "0.4.3"
log = { version = "0.4.14", features = ["std"] }
maplit = "1.0.2"
serde_json = "1.0.86"
anyhow = { workspace = true }
backoff = { workspace = true }
bincode = { workspace = true }
bs58 = { workspace = true }
chrono = { workspace = true }
clap = { workspace = true }
env_logger = { workspace = true }
futures = { workspace = true }
hex = { workspace = true }
log = { workspace = true }
maplit = { workspace = true }
serde_json = { workspace = true }
solana-sdk = { workspace = true }
solana-transaction-status = { workspace = true }
tokio = { version = "1.32.0", features = ["rt-multi-thread", "macros", "time"] }
yellowstone-grpc-client = { path = "../../yellowstone-grpc-client" }
yellowstone-grpc-proto = { path = "../../yellowstone-grpc-proto" }
tokio = { workspace = true }
yellowstone-grpc-client = { workspace = true }
yellowstone-grpc-proto = { workspace = true }
17 changes: 9 additions & 8 deletions yellowstone-grpc-client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@ homepage = { workspace = true }
repository = { workspace = true }
license = { workspace = true }
keywords = { workspace = true }
publish = true

[dependencies]
bytes = "1.3.0"
futures = "0.3.24"
http = "0.2.8"
thiserror = "1.0"
tonic = { version = "0.10.2", features = ["gzip", "tls", "tls-roots"] }
tonic-health = "0.10.2"
yellowstone-grpc-proto = { path = "../yellowstone-grpc-proto", version = "1.11.0+solana.1.17.5" }
bytes = { workspace = true }
futures = { workspace = true }
http = { workspace = true }
thiserror ={ workspace = true }
tonic = { workspace = true }
tonic-health = { workspace = true }
yellowstone-grpc-proto = { workspace = true }

[dev-dependencies]
tokio = { version = "1.32.0", features = ["macros"] }
tokio = { workspace = true }
46 changes: 23 additions & 23 deletions yellowstone-grpc-geyser/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,32 +17,32 @@ crate-type = ["cdylib", "rlib"]
name = "config-check"

[dependencies]
anyhow = "1.0.62"
base64 = "0.21.0"
bincode = "1.3.3"
bs58 = "0.4.0"
clap = { version = "4.3.24", features = ["cargo", "derive"] }
crossbeam-channel = "0.5.8"
futures = "0.3.24"
hyper = { version = "0.14.20", features = ["server"] }
lazy_static = "1.4.0"
log = "0.4.17"
prometheus = "0.13.2"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.86"
anyhow = { workspace = true }
base64 = { workspace = true }
bincode = { workspace = true }
bs58 = { workspace = true }
clap = { workspace = true }
crossbeam-channel = { workspace = true }
futures = { workspace = true }
hyper = { workspace = true }
lazy_static = { workspace = true }
log = { workspace = true }
prometheus = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
solana-geyser-plugin-interface = { workspace = true }
solana-logger = { workspace = true }
solana-sdk = { workspace = true }
solana-transaction-status = { workspace = true }
spl-token-2022 = { version = "0.9.0", features = ["no-entrypoint"] }
tokio = { version = "1.32.0", features = ["rt-multi-thread", "macros", "time", "fs"] }
tokio-stream = "0.1.11"
tonic = { version = "0.10.2", features = ["gzip", "tls", "tls-roots"] }
tonic-health = "0.10.2"
yellowstone-grpc-proto = { path = "../yellowstone-grpc-proto" }
spl-token-2022 = { workspace = true }
tokio = { workspace = true, features = ["fs"] }
tokio-stream = { workspace = true }
tonic = { workspace = true }
tonic-health = { workspace = true }
yellowstone-grpc-proto = { workspace = true }

[build-dependencies]
anyhow = "1.0.62"
cargo-lock = "9.0.0"
git-version = "0.3.5"
vergen = { version = "8.2.1", features = ["build", "rustc"] }
anyhow = { workspace = true }
cargo-lock = { workspace = true }
git-version = { workspace = true }
vergen = { workspace = true }
13 changes: 7 additions & 6 deletions yellowstone-grpc-proto/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,17 @@ homepage = { workspace = true }
repository = { workspace = true }
license = { workspace = true }
keywords = { workspace = true }
publish = true

[dependencies]
bincode = "1.3.3"
prost = "0.12.1"
bincode = { workspace = true }
prost = { workspace = true }
solana-account-decoder = { workspace = true }
solana-sdk = { workspace = true }
solana-transaction-status = { workspace = true }
tonic = "0.10.2"
tonic = { workspace = true }

[build-dependencies]
anyhow = "1.0.62"
protobuf-src = "1.1.0"
tonic-build = "0.10.2"
anyhow = { workspace = true }
protobuf-src = { workspace = true }
tonic-build = { workspace = true }
73 changes: 43 additions & 30 deletions yellowstone-grpc-tools/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,40 +10,53 @@ license = { workspace = true }
keywords = { workspace = true }
publish = false

[[bin]]
name = "grpc-google-pubsub"
required-features = ["google-pubsub"]

[[bin]]
name = "grpc-kafka"
required-features = ["kafka"]

[dependencies]
anyhow = "1.0.62"
async-trait = "0.1.73"
atty = "0.2.14"
clap = { version = "4.3.0", features = ["cargo", "derive"] }
const-hex = "1.6.2"
futures = "0.3.24"
google-cloud-googleapis = "0.11.0"
google-cloud-pubsub = "0.21.0"
hyper = { version = "0.14.27", features = ["server"] }
json5 = "0.4.1"
lazy_static = "1.4.0"
prometheus = "0.13.2"
serde = { version = "1.0.145", features = ["derive"] }
serde_json = "1.0.86"
serde_yaml = "0.9.25"
sha2 = "0.10.7"
tokio = { version = "1.21.2", features = ["rt-multi-thread", "macros", "time", "fs", "signal"] }
tokio-stream = "0.1.11"
tonic = { version = "0.10.2", features = ["gzip", "tls", "tls-roots"] }
tonic-health = "0.10.2"
tracing = "0.1.37"
tracing-subscriber = { version = "0.3.17", features = ["env-filter"] }
yellowstone-grpc-client = { path = "../yellowstone-grpc-client" }
yellowstone-grpc-proto = { path = "../yellowstone-grpc-proto" }
anyhow = { workspace = true }
async-trait = { workspace = true }
atty = { workspace = true }
clap = { workspace = true }
const-hex = { workspace = true, optional = true }
futures = { workspace = true }
google-cloud-googleapis = { workspace = true, optional = true }
google-cloud-pubsub = { workspace = true, optional = true }
hyper = { workspace = true }
json5 = { workspace = true }
lazy_static = { workspace = true }
prometheus = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_yaml = { workspace = true }
sha2 = { workspace = true, optional = true }
tokio = { workspace = true }
tokio-stream = { workspace = true }
tonic = { workspace = true }
tonic-health = { workspace = true }
tracing = { workspace = true }
tracing-subscriber = { workspace = true }
yellowstone-grpc-client = { workspace = true }
yellowstone-grpc-proto = { workspace = true }

[target.'cfg(not(all(target_os = "macos", target_arch = "aarch64")))'.dependencies]
rdkafka = { version = "0.34.0", features = ["ssl", "sasl"] }
rdkafka = { workspace = true, features = ["ssl"], optional = true }

[target.'cfg(all(target_os = "macos", target_arch = "aarch64"))'.dependencies]
rdkafka = { version = "0.34.0", features = ["ssl-vendored", "sasl"] }
rdkafka = { workspace = true, features = ["ssl-vendored"], optional = true }

[build-dependencies]
anyhow = "1.0.62"
cargo-lock = "9.0.0"
git-version = "0.3.5"
vergen = { version = "8.2.1", features = ["build", "rustc"] }
anyhow = { workspace = true }
cargo-lock = { workspace = true }
git-version = { workspace = true }
vergen = { workspace = true }

[features]
default = ["google-pubsub", "kafka"]
google-pubsub = ["google-cloud-googleapis", "google-cloud-pubsub"]
kafka = ["const-hex", "rdkafka", "sha2"]
2 changes: 1 addition & 1 deletion yellowstone-grpc-tools/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ where
Some("yaml") | Some("yml") => {
serde_yaml::from_str(&text).context("failed to parse config from file")
}
Some("json") => serde_yaml::from_str(&text).context("failed to parse config from file"),
Some("json") => json5::from_str(&text).context("failed to parse config from file"),
value => anyhow::bail!("unknown config extension: {value:?}"),
}
}
Expand Down

0 comments on commit c2a76f3

Please sign in to comment.