Chore(postgres): prefer sub-crates of futures

This commit is contained in:
Basti Ortiz 2022-08-14 23:49:40 +08:00
parent aeb8fe0df0
commit 8abc3eaa65
No known key found for this signature in database
GPG Key ID: 1402D5CB17F48E1B
7 changed files with 8 additions and 8 deletions

View File

@ -37,7 +37,7 @@ with-time-0_3 = ["tokio-postgres/with-time-0_3"]
[dependencies]
bytes = "1.0"
fallible-iterator = "0.2"
futures = "0.3"
futures-util = { version = "0.3", features = ["sink"] }
tokio-postgres = { version = "0.7.6", path = "../tokio-postgres" }
tokio = { version = "1.0", features = ["rt", "time"] }
@ -45,3 +45,4 @@ log = "0.4"
[dev-dependencies]
criterion = "0.3"
tokio = { version = "1.0", features = ["rt-multi-thread"] }

View File

@ -4,7 +4,7 @@ use crate::connection::ConnectionRef;
use crate::types::{BorrowToSql, ToSql, Type};
use crate::{CopyInWriter, CopyOutReader, Error};
use fallible_iterator::FallibleIterator;
use futures::StreamExt;
use futures_util::StreamExt;
use std::pin::Pin;
#[doc(inline)]
pub use tokio_postgres::binary_copy::BinaryCopyOutRow;

View File

@ -1,6 +1,5 @@
use crate::{Error, Notification};
use futures::future;
use futures::{pin_mut, Stream};
use futures_util::{future, pin_mut, Stream};
use std::collections::VecDeque;
use std::future::Future;
use std::ops::{Deref, DerefMut};

View File

@ -1,7 +1,7 @@
use crate::connection::ConnectionRef;
use crate::lazy_pin::LazyPin;
use bytes::{Bytes, BytesMut};
use futures::SinkExt;
use futures_util::SinkExt;
use std::io;
use std::io::Write;
use tokio_postgres::{CopyInSink, Error};

View File

@ -1,7 +1,7 @@
use crate::connection::ConnectionRef;
use crate::lazy_pin::LazyPin;
use bytes::{Buf, Bytes};
use futures::StreamExt;
use futures_util::StreamExt;
use std::io::{self, BufRead, Read};
use tokio_postgres::CopyOutStream;

View File

@ -3,7 +3,7 @@
use crate::connection::ConnectionRef;
use crate::{Error, Notification};
use fallible_iterator::FallibleIterator;
use futures::{ready, FutureExt};
use futures_util::{ready, FutureExt};
use std::pin::Pin;
use std::task::Poll;
use std::time::Duration;

View File

@ -1,6 +1,6 @@
use crate::connection::ConnectionRef;
use fallible_iterator::FallibleIterator;
use futures::StreamExt;
use futures_util::StreamExt;
use std::pin::Pin;
use tokio_postgres::{Error, Row, RowStream};