Skip to content

Commit

Permalink
use TlsConfig with native roots (#1)
Browse files Browse the repository at this point in the history
Co-authored-by: Kirill Fomichev <[email protected]>
  • Loading branch information
wgx731 and fanatid authored Oct 21, 2024
1 parent acea4a4 commit 8e9e3bc
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ The minor version will be incremented upon a breaking change and the patch versi

### Breaking

## [2.0.1] - 2024-10-21

### Fixes

- use TlsConfig with native roots ([#1](https://github.com/rpcpool/yellowstone-grpc-kafka/pull/1))

## [2.0.0] - 2024-10-04

- Bump solana to to `2.0`.
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

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

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "yellowstone-grpc-kafka"
version = "2.0.0"
version = "2.0.1"
authors = ["Triton One"]
edition = "2021"
homepage = "https://triton.one"
Expand Down Expand Up @@ -32,7 +32,7 @@ serde_yaml = "0.9.25"
sha2 = { version = "0.10.7", optional = true }
tokio = { version = "1.21.2", features = ["rt-multi-thread", "fs", "signal", "time", "macros"] }
tokio-stream = { version = "0.1.11", optional = true }
tonic = { version = "0.12.1", features = ["gzip", "zstd"], optional = true }
tonic = { version = "0.12.1", features = ["gzip", "zstd", "tls", "tls-roots"], optional = true }
tonic-health = { version = "0.12.1", optional = true }
tracing = { version = "0.1.37", optional = true }
tracing-subscriber = { version = "0.3.17", features = ["env-filter"] }
Expand Down
2 changes: 2 additions & 0 deletions src/bin/grpc-kafka.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ use {
sha2::{Digest, Sha256},
std::{net::SocketAddr, sync::Arc, time::Duration},
tokio::task::JoinSet,
tonic::transport::ClientTlsConfig,
tracing::{debug, trace, warn},
yellowstone_grpc_client::GeyserGrpcClient,
yellowstone_grpc_kafka::{
Expand Down Expand Up @@ -231,6 +232,7 @@ impl ArgsAction {
.x_token(config.x_token)?
.connect_timeout(Duration::from_secs(10))
.timeout(Duration::from_secs(5))
.tls_config(ClientTlsConfig::new().with_native_roots())?
.connect()
.await?;
let mut geyser = client.subscribe_once(config.request.to_proto()).await?;
Expand Down

0 comments on commit 8e9e3bc

Please sign in to comment.