mirror of
https://github.com/fluencelabs/rust-libp2p
synced 2025-07-02 19:21:37 +00:00
swarm-derive/: Make event_process = false the default (#2214)
Co-authored-by: Max Inden <mail@max-inden.de>
This commit is contained in:
@ -209,7 +209,7 @@ fn get_client_listen_address(opt: &Opt) -> String {
|
||||
}
|
||||
|
||||
#[derive(NetworkBehaviour)]
|
||||
#[behaviour(out_event = "Event", event_process = false)]
|
||||
#[behaviour(out_event = "Event")]
|
||||
struct Behaviour {
|
||||
relay: Relay,
|
||||
ping: ping::Behaviour,
|
||||
|
@ -1129,7 +1129,11 @@ fn yield_incoming_connection_through_correct_listener() {
|
||||
}
|
||||
|
||||
#[derive(NetworkBehaviour)]
|
||||
#[behaviour(out_event = "CombinedEvent", poll_method = "poll")]
|
||||
#[behaviour(
|
||||
out_event = "CombinedEvent",
|
||||
poll_method = "poll",
|
||||
event_process = true
|
||||
)]
|
||||
struct CombinedBehaviour {
|
||||
relay: Relay,
|
||||
ping: ping::Behaviour,
|
||||
@ -1195,6 +1199,7 @@ impl NetworkBehaviourEventProcess<()> for CombinedBehaviour {
|
||||
}
|
||||
|
||||
#[derive(NetworkBehaviour)]
|
||||
#[behaviour(event_process = true)]
|
||||
struct CombinedKeepAliveBehaviour {
|
||||
relay: Relay,
|
||||
keep_alive: DummyBehaviour,
|
||||
|
Reference in New Issue
Block a user