Update deps

This commit is contained in:
Dominik Werder
2023-05-10 09:41:56 +02:00
parent 6c76a70940
commit fb875f81d6
7 changed files with 35 additions and 41 deletions

View File

@@ -2394,6 +2394,15 @@ dependencies = [
"getrandom",
]
[[package]]
name = "rand_pcg"
version = "0.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "59cad018caf63deb318e5a4586d99a24424a364f40f1e5778c29aca23f4fc73e"
dependencies = [
"rand_core",
]
[[package]]
name = "rayon"
version = "1.7.0"
@@ -2602,9 +2611,9 @@ checksum = "1792db035ce95be60c3f8853017b3999209281c24e2ba5bc8e59bf97a0c590c1"
[[package]]
name = "scylla"
version = "0.7.0"
version = "0.8.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4b9d4ef7fb24d95d30c4a8da782bb2afead3a8b66f32c805bb82a03722d7be33"
checksum = "530af73ae66ea56dcc2dd6a8900b442c31da0f068923ea41e0b0f3d0703b067c"
dependencies = [
"arc-swap",
"async-trait",
@@ -2620,6 +2629,7 @@ dependencies = [
"num-bigint",
"num_enum",
"rand",
"rand_pcg",
"scylla-cql",
"scylla-macros",
"smallvec",
@@ -2634,9 +2644,9 @@ dependencies = [
[[package]]
name = "scylla-cql"
version = "0.0.3"
version = "0.0.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6972061cbcc83754b4243d007ae51c1a1345a950b368cbdaad0186eac8799203"
checksum = "0fc8568c89b1d70547881610ad2423157267d57552edb4861e6bd4394e53f26c"
dependencies = [
"async-trait",
"bigdecimal",
@@ -2655,10 +2665,11 @@ dependencies = [
[[package]]
name = "scylla-macros"
version = "0.1.2"
version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e03b3a19daa79085439113c746d2946e5e6effd2d9039bf092bb08df915487b2"
checksum = "32d777dadbf7163d1524ea4f5a095146298d263a686febb96d022cf46d06df32"
dependencies = [
"proc-macro2",
"quote",
"syn 1.0.109",
]
@@ -3476,6 +3487,9 @@ name = "uuid"
version = "1.3.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4dad5567ad0cf5b760e5665964bec1b47dfd077ba8a2544b513f3556d3d239a2"
dependencies = [
"getrandom",
]
[[package]]
name = "valuable"

View File

@@ -19,7 +19,7 @@ futures-util = "0.3.25"
bytes = "1.3"
pin-project = "1"
#dashmap = "3"
scylla = "0.7"
scylla = "0.8.1"
async-channel = "1.8.0"
chrono = "0.4"
regex = "1.7.0"

View File

@@ -21,7 +21,7 @@ tracing-futures = "0.2"
async-channel = "1.8.0"
itertools = "0.10.1"
chrono = "0.4.23"
scylla = "0.7"
scylla = "0.8.1"
md-5 = "0.10"
regex = "1.7"
err = { path = "../err" }

View File

@@ -24,7 +24,6 @@ use netpod::ACCEPT_ALL;
use netpod::APP_JSON;
use query::api4::binned::BinnedQuery;
use query::api4::events::PlainEventsQuery;
use scylla::batch::Consistency;
use scylla::frame::response::cql_to_rust::FromRowError as ScyFromRowError;
use scylla::transport::errors::NewSessionError as ScyNewSessionError;
use scylla::transport::errors::QueryError as ScyQueryError;
@@ -267,13 +266,7 @@ impl ScyllaConfigsHisto {
.scylla
.as_ref()
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
let scy = scylla::SessionBuilder::new()
.known_nodes(&scyco.hosts)
.use_keyspace(&scyco.keyspace, true)
.default_consistency(Consistency::One)
.build()
.await
.err_conv()?;
let scy = scyllaconn::create_scy_session(scyco).await?;
let res = scy
.query(
"select scalar_type, shape_dims, series from series_by_channel where facility = ? allow filtering",
@@ -388,13 +381,7 @@ impl ScyllaChannelsWithType {
.scylla
.as_ref()
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
let scy = scylla::SessionBuilder::new()
.known_nodes(&scyco.hosts)
.use_keyspace(&scyco.keyspace, true)
.default_consistency(Consistency::One)
.build()
.await
.err_conv()?;
let scy = scyllaconn::create_scy_session(scyco).await?;
let res = scy
.query(
"select channel_name, series from series_by_channel where facility = ? and scalar_type = ? and shape_dims = ? allow filtering",
@@ -553,13 +540,7 @@ impl ScyllaChannelsActive {
.scylla
.as_ref()
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
let scy = scylla::SessionBuilder::new()
.known_nodes(&scyco.hosts)
.use_keyspace(&scyco.keyspace, true)
.default_consistency(Consistency::One)
.build()
.await
.err_conv()?;
let scy = scyllaconn::create_scy_session(scyco).await?;
// Database stores tsedge/ts_msp in units of (10 sec), and we additionally map to the grid.
let tsedge = q.tsedge / 10 / (6 * 2) * (6 * 2);
info!(
@@ -756,13 +737,7 @@ impl ScyllaSeriesTsMsp {
.scylla
.as_ref()
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
let scy = scylla::SessionBuilder::new()
.known_nodes(&scyco.hosts)
.use_keyspace(&scyco.keyspace, true)
.default_consistency(Consistency::One)
.build()
.await
.err_conv()?;
let scy = scyllaconn::create_scy_session(scyco).await?;
let mut ts_msps = Vec::new();
let mut res = scy
.query_iter("select ts_msp from ts_msp where series = ?", (q.series as i64,))

View File

@@ -19,7 +19,7 @@ byteorder = "1.4.3"
futures-util = "0.3.14"
tracing = "0.1.25"
hex = "0.4.3"
scylla = "0.7"
scylla = "0.8.1"
tokio-postgres = "0.7.7"
wasmer = { version = "3.2.0", default-features = false, features = ["sys", "cranelift"] }
err = { path = "../err" }

View File

@@ -21,7 +21,7 @@ chrono = { version = "0.4.19", features = ["serde"] }
crc32fast = "1.3.2"
futures-util = "0.3.24"
async-channel = "1.8.0"
scylla = "0.7"
scylla = "0.8.1"
tokio-postgres = { version = "0.7.7", features = ["with-chrono-0_4", "with-serde_json-1"] }
err = { path = "../err" }
netpod = { path = "../netpod" }

View File

@@ -6,9 +6,9 @@ pub mod status;
use err::Error;
use errconv::ErrConv;
use netpod::range::evrange::NanoRange;
use netpod::range::evrange::SeriesRange;
use netpod::ScyllaConfig;
use scylla::execution_profile::ExecutionProfileBuilder;
use scylla::statement::Consistency;
use scylla::Session as ScySession;
use std::sync::Arc;
@@ -32,7 +32,12 @@ pub async fn create_scy_session(scyconf: &ScyllaConfig) -> Result<Arc<ScySession
let scy = scylla::SessionBuilder::new()
.known_nodes(&scyconf.hosts)
.use_keyspace(&scyconf.keyspace, true)
.default_consistency(Consistency::LocalOne)
.default_execution_profile_handle(
ExecutionProfileBuilder::default()
.consistency(Consistency::LocalOne)
.build()
.into_handle(),
)
.build()
.await
.err_conv()?;