diff --git a/CHANGELOG.md b/CHANGELOG.md index 6e5e4dec..16807cf0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +# 0.8.0 + +- Upgrade step 4 of 4. This version always assumes the new semantics and + no longer sets the non-standard flag in intial window updates. +- The configuration option `lazy_open` is removed. Initial window updates + are sent automatically if the receive window is configured to be larger + than the default. + # 0.7.0 Upgrade step 3 of 4. This version sets the non-standard flag, but diff --git a/Cargo.toml b/Cargo.toml index e452ab6f..4e43d3b5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "yamux" -version = "0.7.0" +version = "0.8.0" authors = ["Parity Technologies "] license = "Apache-2.0 OR MIT" description = "Multiplexer over reliable, ordered connections" diff --git a/src/connection.rs b/src/connection.rs index f1a6d85c..0458a15e 100644 --- a/src/connection.rs +++ b/src/connection.rs @@ -467,7 +467,6 @@ impl Connection { if extra_credit > 0 { let mut frame = Frame::window_update(id, extra_credit); frame.header_mut().syn(); - frame.header_mut().additive(); log::trace!("{}: sending initial {}", self.id, frame.header()); self.socket.get_mut().send(&frame).await.or(Err(ConnectionError::Closed))? } diff --git a/src/frame/header.rs b/src/frame/header.rs index 2e4bb7aa..8e70f225 100644 --- a/src/frame/header.rs +++ b/src/frame/header.rs @@ -99,11 +99,6 @@ impl Header { pub fn syn(&mut self) { self.flags.0 |= SYN.0 } - - /// Set the [`ADD`] flag. - pub fn additive(&mut self) { - self.flags.0 |= ADD.0 - } } impl Header { @@ -349,10 +344,6 @@ pub const FIN: Flags = Flags(4); /// Indicates an immediate stream reset. pub const RST: Flags = Flags(8); -/// Temporary flag indicating that the initial window update is additive. -/// (See https://github.com/paritytech/yamux/issues/92) -pub const ADD: Flags = Flags(0x8000); - /// The serialised header size in bytes. pub const HEADER_SIZE: usize = 12; diff --git a/src/lib.rs b/src/lib.rs index bbb162fd..44528100 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -133,23 +133,6 @@ impl Config { self.read_after_close = b; self } - - /// Enable or disable the sending of an initial window update frame - /// when opening outbound streams. - /// - /// When enabled, opening a new outbound stream will not result in an - /// immediate send of a frame, instead the first outbound data frame - /// will be marked as opening a stream. - /// - /// When disabled (the current default), opening a new outbound - /// stream will result in a window update frame being sent immediately - /// to the remote. This allows opening a stream with a custom receive - /// window size (cf. [`Config::set_receive_window`]) which the remote - /// can directly make use of. - #[deprecated(since = "0.6.0")] - pub fn set_lazy_open(&mut self, _: bool) -> &mut Self { - self - } } // Check that we can safely cast a `usize` to a `u64`.