Skip to content

Commit 84c10b2

Browse files
committed
cargo: bump rust-driver to 0.15
1 parent 21292f9 commit 84c10b2

File tree

6 files changed

+202
-65
lines changed

6 files changed

+202
-65
lines changed

scylla-rust-wrapper/Cargo.lock

Lines changed: 71 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scylla-rust-wrapper/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ categories = ["database"]
1010
license = "MIT OR Apache-2.0"
1111

1212
[dependencies]
13-
scylla = { git = "https://github.com/scylladb/scylla-rust-driver.git", rev = "64b4afcd", features = [
13+
scylla = { git = "https://github.com/scylladb/scylla-rust-driver.git", rev = "v0.15.0", features = [
1414
"ssl",
1515
] }
1616
tokio = { version = "1.27.0", features = ["full"] }
@@ -33,7 +33,7 @@ bindgen = "0.65"
3333
chrono = "0.4.20"
3434

3535
[dev-dependencies]
36-
scylla-proxy = { git = "https://github.com/scylladb/scylla-rust-driver.git", rev = "64b4afcd" }
36+
scylla-proxy = { git = "https://github.com/scylladb/scylla-rust-driver.git", rev = "v0.15.0" }
3737

3838
assert_matches = "1.5.0"
3939
ntest = "0.9.3"

scylla-rust-wrapper/src/cass_error.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,15 @@ impl ToCassError for CassErrorResult {
1313
fn to_cass_error(&self) -> CassError {
1414
match self {
1515
CassErrorResult::Query(query_error) => query_error.to_cass_error(),
16+
17+
// For now let's leave these as LIB_INVALID_DATA.
18+
// I don't see any variants that would make more sense.
19+
// TBH, I'm almost sure that we should introduce additional enum variants
20+
// of CassError in the future ~ muzarski.
21+
CassErrorResult::ResultMetadataLazyDeserialization(_) => {
22+
CassError::CASS_ERROR_LIB_INVALID_DATA
23+
}
24+
CassErrorResult::Deserialization(_) => CassError::CASS_ERROR_LIB_INVALID_DATA,
1625
}
1726
}
1827
}

scylla-rust-wrapper/src/query_error.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ use crate::cass_error::*;
33
use crate::cass_error_types::CassWriteType;
44
use crate::cass_types::CassConsistency;
55
use crate::types::*;
6+
use scylla::deserialize::DeserializationError;
7+
use scylla::frame::frame_errors::ResultMetadataAndRowsCountParseError;
68
use scylla::statement::Consistency;
79
use scylla::transport::errors::*;
810
use thiserror::Error;
@@ -11,6 +13,10 @@ use thiserror::Error;
1113
pub enum CassErrorResult {
1214
#[error(transparent)]
1315
Query(#[from] QueryError),
16+
#[error(transparent)]
17+
ResultMetadataLazyDeserialization(#[from] ResultMetadataAndRowsCountParseError),
18+
#[error("Failed to deserialize rows: {0}")]
19+
Deserialization(#[from] DeserializationError),
1420
}
1521

1622
impl From<Consistency> for CassConsistency {

0 commit comments

Comments
 (0)