From f3655e79ca971c5a18de3a4a52be5052edcff3b2 Mon Sep 17 00:00:00 2001 From: danielsanchezq Date: Thu, 26 Jan 2023 11:10:21 +0100 Subject: [PATCH] Add relay topics config entry --- waku-bindings/src/node/config.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/waku-bindings/src/node/config.rs b/waku-bindings/src/node/config.rs index 6a5edb5..ecbf5a6 100644 --- a/waku-bindings/src/node/config.rs +++ b/waku-bindings/src/node/config.rs @@ -4,6 +4,7 @@ use std::fmt::{Display, Formatter}; use std::str::FromStr; // std // crates +use crate::WakuPubSubTopic; use multiaddr::Multiaddr; use secp256k1::SecretKey; use serde::{Deserialize, Serialize}; @@ -33,6 +34,8 @@ pub struct WakuNodeConfig { /// Enable relay protocol. Default `true` #[default(Some(true))] pub relay: Option, + #[serde(default)] + pub relay_topics: Vec, /// The minimum number of peers required on a topic to allow broadcasting a message. Default `0` #[default(Some(0))] pub min_peers_to_publish: Option, @@ -47,7 +50,7 @@ pub struct WakuNodeConfig { #[serde(rename = "discV5")] pub discv5: Option, /// Array of bootstrap nodes ENR. - #[serde(rename = "discV5BootstrapNodes")] + #[serde(rename = "discV5BootstrapNodes", default)] pub discv5_bootstrap_nodes: Vec, /// UDP port for DiscoveryV5. Default `9000`. #[default(Some(9000))]