Skip to content

Commit

Permalink
feat: Add listener for server sockets (#15)
Browse files Browse the repository at this point in the history
* feat: Add listener for server sockets
* fix: Correct doc tests and ALPN select

---------

Signed-off-by: Jeremy HERGAULT <[email protected]>
  • Loading branch information
reneca authored Dec 19, 2024
1 parent 6e89db3 commit 301b913
Show file tree
Hide file tree
Showing 6 changed files with 1,860 additions and 627 deletions.
4 changes: 4 additions & 0 deletions prosa/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ tracing = "0.1"
tracing-subscriber = {version = "0.3", features = ["std", "env-filter"]}
thiserror.workspace = true
url = { version = "2", features = ["serde"] }
rlimit = "0.10"

aquamarine.workspace = true

Expand All @@ -58,3 +59,6 @@ opentelemetry-stdout.workspace = true
opentelemetry-otlp.workspace = true
opentelemetry-appender-log.workspace = true
memory-stats = "1"

[dev-dependencies]
futures-util = { version = "0.3", default-features = false }
15 changes: 14 additions & 1 deletion prosa/src/inj/proc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ extern crate self as prosa;

/// Inj settings for service and speed parameters
#[proc_settings]
#[derive(Default, Debug, Deserialize, Serialize, Clone)]
#[derive(Debug, Deserialize, Serialize, Clone)]
pub struct InjSettings {
/// Service to inject to
service_name: String,
Expand Down Expand Up @@ -83,6 +83,19 @@ impl InjSettings {
}
}

#[proc_settings]
impl Default for InjSettings {
fn default() -> InjSettings {
InjSettings {
service_name: Default::default(),
max_speed: InjSettings::default_max_speed(),
timeout_threshold: InjSettings::default_timeout_threshold(),
max_concurrents_send: InjSettings::default_max_concurrents_send(),
speed_interval: InjSettings::default_speed_interval(),
}
}
}

/// Inj processor to inject transactions
///
/// ```
Expand Down
Loading

0 comments on commit 301b913

Please sign in to comment.