mirror of
https://github.com/launchbadge/sqlx.git
synced 2025-10-02 15:25:32 +00:00
Update dependencies
This commit is contained in:
parent
2b2d37573c
commit
fecd367e8d
14
Cargo.toml
14
Cargo.toml
@ -22,14 +22,14 @@ postgres = []
|
||||
mariadb = []
|
||||
|
||||
[dependencies]
|
||||
async-std = { version = "1.1", features = ["attributes"] }
|
||||
async-stream = "0.2"
|
||||
async-trait = "0.1.11"
|
||||
bitflags = "1.1.0"
|
||||
async-std = { version = "1.1.0", features = ["attributes"] }
|
||||
async-stream = "0.2.0"
|
||||
async-trait = "0.1.18"
|
||||
bitflags = "1.2.1"
|
||||
byteorder = { version = "1.3.2", default-features = false }
|
||||
bytes = "0.4.12"
|
||||
crossbeam-queue = "0.1.2"
|
||||
crossbeam-utils = { version = "0.6.6", default-features = false }
|
||||
crossbeam-queue = "0.2.0"
|
||||
crossbeam-utils = { version = "0.7.0", default-features = false }
|
||||
futures-channel = "0.3.1"
|
||||
futures-core = "0.3.1"
|
||||
futures-util = "0.3.1"
|
||||
@ -42,7 +42,7 @@ uuid = { version = "0.8.1", optional = true }
|
||||
[dev-dependencies]
|
||||
matches = "0.1.8"
|
||||
sqlx-macros = { path = "sqlx-macros/", features = ["postgres", "mariadb", "uuid"] }
|
||||
criterion = "0.3"
|
||||
criterion = "0.3.0"
|
||||
|
||||
[profile.release]
|
||||
lto = true
|
||||
|
@ -12,4 +12,4 @@ dotenv = "0.15.0"
|
||||
tide = "0.3.0"
|
||||
tokio = { version = "0.2.0-alpha.4", default-features = false, features = [ "rt-full" ] }
|
||||
sqlx = { path = "../..", features = [ "postgres" ] }
|
||||
serde = { version = "1", features = [ "derive"] }
|
||||
serde = { version = "1", features = [ "derive"] }
|
||||
|
@ -1,9 +1,9 @@
|
||||
use sqlx::{Pool, Postgres};
|
||||
use std::env;
|
||||
use tide::error::ResultExt;
|
||||
use tide::http::StatusCode;
|
||||
use tide::response;
|
||||
use tide::EndpointResult;
|
||||
use tide::http::StatusCode;
|
||||
use tide::{App, Context};
|
||||
|
||||
// #[async_std::main]
|
||||
|
@ -8,13 +8,13 @@ edition = "2018"
|
||||
proc-macro = true
|
||||
|
||||
[dependencies]
|
||||
async-std = "1.0"
|
||||
async-std = "1.1.0"
|
||||
dotenv = "0.15.0"
|
||||
futures = "0.3.1"
|
||||
proc-macro2 = "1.0.6"
|
||||
sqlx = { path = "../" }
|
||||
syn = "1.0"
|
||||
quote = "1.0"
|
||||
syn = "1.0.8"
|
||||
quote = "1.0.2"
|
||||
tokio = { version = "0.2.0-alpha.4" }
|
||||
url = "2.1.0"
|
||||
|
||||
|
@ -1,10 +1,10 @@
|
||||
use bytes::{BufMut, BytesMut};
|
||||
use std::io;
|
||||
|
||||
use async_std::io::prelude::*;
|
||||
use async_std::io::{Read, Write, prelude::{ReadExt, WriteExt}};
|
||||
use async_std::future::poll_fn;
|
||||
|
||||
pub struct BufStream<S> {
|
||||
stream: S,
|
||||
pub(crate) stream: S,
|
||||
|
||||
// Have we reached end-of-file (been disconnected)
|
||||
stream_eof: bool,
|
||||
@ -29,12 +29,6 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
pub async fn close(&mut self) -> io::Result<()> {
|
||||
use futures_util::io::AsyncWriteExt;
|
||||
|
||||
self.stream.close().await
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn buffer_mut(&mut self) -> &mut Vec<u8> {
|
||||
&mut self.wbuf
|
||||
|
@ -5,6 +5,7 @@ use crate::{
|
||||
PostgresDatabaseError, PostgresQueryParameters, PostgresRow,
|
||||
},
|
||||
};
|
||||
use std::net::Shutdown;
|
||||
use byteorder::NetworkEndian;
|
||||
use std::{io, net::SocketAddr};
|
||||
use async_std::net::TcpStream;
|
||||
@ -134,7 +135,7 @@ impl PostgresRawConnection {
|
||||
protocol::Terminate.encode(self.stream.buffer_mut());
|
||||
|
||||
self.stream.flush().await?;
|
||||
self.stream.close().await?;
|
||||
self.stream.stream.shutdown(Shutdown::Both)?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user