Skip to content

Commit

Permalink
enable tls
Browse files Browse the repository at this point in the history
  • Loading branch information
austbot committed Jan 24, 2023
1 parent c058063 commit 9c03b84
Show file tree
Hide file tree
Showing 7 changed files with 160 additions and 17 deletions.
148 changes: 143 additions & 5 deletions Cargo.lock

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

6 changes: 3 additions & 3 deletions plerkle/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "plerkle"
description = "Geyser plugin with dynamic config reloading, message bus agnostic abstractions and a whole lot of fun."
version = "1.1.3"
version = "1.2.0"
authors = ["Metaplex Developers <[email protected]>"]
repository = "https://github.com/metaplex-foundation/digital-asset-validator-plugin"
license = "AGPL-3.0"
Expand Down Expand Up @@ -31,9 +31,9 @@ cadence-macros = "0.29.0"
chrono = "0.4.19"
tracing = "0.1.35"
hex = "0.4.3"
plerkle_messenger = { path = "../plerkle_messenger", version = "1.1.3", features = ["redis"] }
plerkle_messenger = { path = "../plerkle_messenger", version = "1.2.0", features = ["redis"] }
flatbuffers = "22.10.26"
plerkle_serialization = { path = "../plerkle_serialization", version = "1.1.3" }
plerkle_serialization = { path = "../plerkle_serialization", version = "1.2.0" }
tokio = { version = "1.23.0", features = ["full"] }
figment = { version = "0.10.6", features = ["env", "test"] }

Expand Down
8 changes: 4 additions & 4 deletions plerkle/src/geyser_plugin_nft.rs
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ impl GeyserPlugin for Plerkle<'static> {
if transaction_info.is_vote || transaction_info.transaction_status_meta.status.is_err() {
return Ok(());
}

// Check if transaction was selected in config.
if let Some(transaction_selector) = &self.transaction_selector {
if !transaction_selector.is_transaction_selected(
Expand All @@ -408,9 +408,9 @@ impl GeyserPlugin for Plerkle<'static> {
builder,
};
let _ = sender.send(data).await;
safe_metric(|| {
statsd_count!("transaction_seen_event", 1, "slot-idx" => &slt_idx);
});
});
safe_metric(|| {
statsd_count!("transaction_seen_event", 1, "slot-idx" => &slt_idx);
});
Ok(())
}
Expand Down
4 changes: 2 additions & 2 deletions plerkle_messenger/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
[package]
name = "plerkle_messenger"
description = "Metaplex Messenger trait for Geyser plugin producer/consumer patterns."
version = "1.1.3"
version = "1.2.0"
authors = ["Metaplex Developers <[email protected]>"]
repository = "https://github.com/metaplex-foundation/digital-asset-validator-plugin"
license = "AGPL-3.0"
edition = "2021"
readme = "Readme.md"

[dependencies]
redis = { version = "0.22.1", features = ["aio", "tokio-comp", "streams"], optional = true}
redis = { version = "0.22.2", features = ["aio", "tokio-comp", "streams", "tokio-native-tls-comp"], optional = true}
log = "0.4.11"
thiserror = "1.0.30"
async-trait = "0.1.53"
Expand Down
5 changes: 5 additions & 0 deletions plerkle_messenger/src/redis_messenger.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,11 @@ impl Messenger for RedisMessenger {
MessengerError::ConnectionError { msg: e.to_string() }
})?;

let cluster_mode = config
.get("cluster_mode")
.and_then(|r| r.clone().to_bool())
.unwrap_or(false);

let consumer_id = config
.get("consumer_id")
.and_then(|id| id.clone().into_string())
Expand Down
2 changes: 1 addition & 1 deletion plerkle_serialization/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "plerkle_serialization"
description = "Metaplex Flatbuffers Plerkle Serialization for Geyser plugin producer/consumer patterns."
version = "1.1.3"
version = "1.2.0"
authors = ["Metaplex Developers <[email protected]>"]
repository = "https://github.com/metaplex-foundation/digital-asset-validator-plugin"
license = "AGPL-3.0"
Expand Down
4 changes: 2 additions & 2 deletions plerkle_serialization/src/serializer/serializer_stable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ use crate::{
Reward, RewardArgs, RewardType as FBRewardType, SlotStatusInfo, SlotStatusInfoArgs,
Status as FBSlotStatus, TransactionInfo, TransactionInfoArgs,
};
use chrono::{Utc, format::format};
use chrono::{format::format, Utc};
use flatbuffers::FlatBufferBuilder;
use solana_geyser_plugin_interface::geyser_plugin_interface::{
ReplicaBlockInfo, SlotStatus, ReplicaTransactionInfoV2, ReplicaAccountInfoV2,
ReplicaAccountInfoV2, ReplicaBlockInfo, ReplicaTransactionInfoV2, SlotStatus,
};
use solana_runtime::bank::RewardType;

Expand Down

0 comments on commit 9c03b84

Please sign in to comment.