let (client, actor) = Client::builder().build(connection).await.unwrap();
Client::build and builder::ClientBuilder are deperecated.
I've added #[deprecated(since = "0.11.0", note = "use Client::builder() instead")] (update since if necessary)
Moreover, connection is needed only when calling subscribe or build having the advantage that the overall implementation is much simpler since there is no need for:
connection: Box<dyn ObjectSafeConnection>
impl IntoFuture for ClientBuilder {
type Output = Result<(Client, ConnectionActor), Error>;
type IntoFuture = future::Boxed<Self::Output>;
fn into_future(self) -> Self::IntoFuture {
Box::pin(self.build())
}
}
Fix #112
Client::build
andbuilder::ClientBuilder
are deperecated. I've added#[deprecated(since = "0.11.0", note = "use Client::builder() instead")]
(updatesince
if necessary) Moreover,connection
is needed only when callingsubscribe
orbuild
having the advantage that the overall implementation is much simpler since there is no need for:connection: Box<dyn ObjectSafeConnection>
What do you think?