Update sqlx to enable statement cache

This commit is contained in:
link2xt
2021-04-07 00:36:36 +03:00
committed by link2xt
parent 6bb5721f29
commit 720135a915
3 changed files with 5 additions and 6 deletions

8
Cargo.lock generated
View File

@@ -3465,7 +3465,7 @@ dependencies = [
[[package]]
name = "sqlx"
version = "0.5.1"
source = "git+https://github.com/dignifiedquire/sqlx?branch=fix-pool-time-out#30a6f04a193632f5d43c02da9dc6d0ef84e88920"
source = "git+https://github.com/link2xt/sqlx?branch=sqlite3-reset-fetch_many#7a29ed87120231b5150386971f0639a90ab8c14f"
dependencies = [
"sqlx-core",
"sqlx-macros",
@@ -3474,7 +3474,7 @@ dependencies = [
[[package]]
name = "sqlx-core"
version = "0.5.1"
source = "git+https://github.com/dignifiedquire/sqlx?branch=fix-pool-time-out#30a6f04a193632f5d43c02da9dc6d0ef84e88920"
source = "git+https://github.com/link2xt/sqlx?branch=sqlite3-reset-fetch_many#7a29ed87120231b5150386971f0639a90ab8c14f"
dependencies = [
"ahash 0.6.3",
"atoi",
@@ -3512,7 +3512,7 @@ dependencies = [
[[package]]
name = "sqlx-macros"
version = "0.5.1"
source = "git+https://github.com/dignifiedquire/sqlx?branch=fix-pool-time-out#30a6f04a193632f5d43c02da9dc6d0ef84e88920"
source = "git+https://github.com/link2xt/sqlx?branch=sqlite3-reset-fetch_many#7a29ed87120231b5150386971f0639a90ab8c14f"
dependencies = [
"dotenv",
"either",
@@ -3530,7 +3530,7 @@ dependencies = [
[[package]]
name = "sqlx-rt"
version = "0.3.0"
source = "git+https://github.com/dignifiedquire/sqlx?branch=fix-pool-time-out#30a6f04a193632f5d43c02da9dc6d0ef84e88920"
source = "git+https://github.com/link2xt/sqlx?branch=sqlite3-reset-fetch_many#7a29ed87120231b5150386971f0639a90ab8c14f"
dependencies = [
"async-native-tls",
"async-std",

View File

@@ -61,7 +61,7 @@ async-std-resolver = "0.19.5"
async-tar = "0.3.0"
uuid = { version = "0.8", features = ["serde", "v4"] }
rust-hsluv = "0.1.4"
sqlx = { git = "https://github.com/dignifiedquire/sqlx", branch = "fix-pool-time-out", features = ["runtime-async-std-native-tls", "sqlite"] }
sqlx = { git = "https://github.com/link2xt/sqlx", branch = "sqlite3-reset-fetch_many", features = ["runtime-async-std-native-tls", "sqlite"] }
# keep in sync with sqlx
libsqlite3-sys = { version = "0.20.1", default-features = false, features = [ "pkg-config", "vcpkg", "bundled" ] }

View File

@@ -85,7 +85,6 @@ impl Sql {
.read_only(false)
.busy_timeout(Duration::from_secs(100))
.create_if_missing(true)
.statement_cache_capacity(0) // XXX workaround for https://github.com/launchbadge/sqlx/issues/1147
.synchronous(SqliteSynchronous::Normal);
PoolOptions::<Sqlite>::new()