Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

codewide: re-structure modules #804

Closed
wants to merge 43 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
2f8d998
topology->metadata
wprzytula Aug 30, 2023
6e3dc38
AddressTranslator session->connection
wprzytula Aug 30, 2023
e28ac5b
routing->sharding
wprzytula Aug 30, 2023
c4073c4
move session out of transport
wprzytula Aug 30, 2023
5b67d97
move caching_session.rs to new session mod
wprzytula Aug 30, 2023
2fb76e9
extract connection module
wprzytula Aug 30, 2023
6e7e3c6
move open_connection_to_shard_aware_port() to connection
wprzytula Aug 30, 2023
25c41ca
move metadata.rs to new cluster mod
wprzytula Aug 30, 2023
59144ee
move cluster.rs to new cluster mod
wprzytula Aug 30, 2023
9c457bd
move locator to new cluster mod
wprzytula Aug 30, 2023
33c94e2
move node.rs to new cluster module
wprzytula Aug 30, 2023
f673b44
move host_filter.rs to new cluster module
wprzytula Aug 30, 2023
f2b63db
move load_balancing to new execution mod
wprzytula Aug 30, 2023
34c765f
move execution_profile.rs to new execution mod
wprzytula Aug 31, 2023
5607cbe
unpub fns in execution_profile.rs (private anyway)
wprzytula Aug 31, 2023
d27ae2d
move speculative_execution.rs to new execution mod
wprzytula Aug 31, 2023
bbd4751
extract retries module into execution mod
wprzytula Aug 31, 2023
ddae8cb
move iterator.rs to execution mod
wprzytula Aug 31, 2023
a9c809a
move history.rs to execution mod
wprzytula Aug 31, 2023
e599114
move tracing.rs to execution mod
wprzytula Aug 31, 2023
675d874
move metrics.rs to execution mod
wprzytula Aug 31, 2023
c406286
extract routing module
wprzytula Aug 31, 2023
6273f6a
extract tests module from transport tests
wprzytula Aug 31, 2023
2c6b923
re-export errors mod from execution, not transport
wprzytula Aug 31, 2023
e3c311a
move some errors from scylla_cql to scylla
wprzytula Aug 31, 2023
58cd7ed
extract driver_tracing.rs with RequestSpan
wprzytula Aug 31, 2023
fc9f57f
move IntoTypedRows & TypedRowsIter to query_result
wprzytula Aug 31, 2023
71efe62
extract response mod, move QueryResponse there
wprzytula Aug 31, 2023
7c4ec68
move query_result.rs to new response mod
wprzytula Aug 31, 2023
4dbc401
re-export Compression in connection mod
wprzytula Aug 31, 2023
313b22a
finally! annihilate transport module
wprzytula Aug 31, 2023
c38b5e0
create cql mod for structured imports from scylla-cql
wprzytula Aug 31, 2023
4967b4c
move type benchmark to scylla-cql
wprzytula Aug 31, 2023
ae499fa
re-export value in cql mod
wprzytula Aug 31, 2023
934de12
re-export CqlValue in cql::value
wprzytula Aug 31, 2023
80daa7c
re-export frame::response::result in cql mod
wprzytula Aug 31, 2023
a449c4b
re-export types and ProtocolFeatures in test_utils
wprzytula Aug 31, 2023
283abda
re-export cql_to_rust in cql mod
wprzytula Aug 31, 2023
a6d9425
no longer expose scylla_cql::frame in scylla
wprzytula Aug 31, 2023
06271ee
clippy-fixes
wprzytula Aug 31, 2023
9b6bbed
fixes for doc tests
wprzytula Aug 31, 2023
ae59115
adjust docs for new module structure
wprzytula Aug 31, 2023
b4cd5be
cargo doc links fixes
wprzytula Aug 31, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/source/connecting/compression.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ An example enabling `Snappy` compression algorithm:
# extern crate scylla;
# extern crate tokio;
use scylla::{Session, SessionBuilder};
use scylla::transport::Compression;
use scylla::connection::Compression;
use std::error::Error;

#[tokio::main]
Expand Down
2 changes: 1 addition & 1 deletion docs/source/data-types/counter.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::IntoTypedRows;
use scylla::frame::value::Counter;
use scylla::cql::value::Counter;

// Read counter from the table
if let Some(rows) = session.query("SELECT c FROM keyspace.table", &[]).await?.rows {
Expand Down
7 changes: 3 additions & 4 deletions docs/source/data-types/date.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Date

For most use cases `Date` can be represented as
For most use cases `Date` can be represented as
[`chrono::NaiveDate`](https://docs.rs/chrono/0.4.19/chrono/naive/struct.NaiveDate.html).\
`NaiveDate` supports dates from -262145-1-1 to 262143-12-31.

Expand Down Expand Up @@ -40,11 +40,10 @@ Internally `Date` is represented as number of days since -5877641-06-23 i.e. 2^3
# use scylla::Session;
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::frame::value::Date;
use scylla::frame::response::result::CqlValue;
use scylla::cql::value::{CqlValue, Date};

// Insert date using raw u32 representation
let to_insert: Date = Date(2_u32.pow(31)); // 1970-01-01
let to_insert: Date = Date(2_u32.pow(31)); // 1970-01-01
session
.query("INSERT INTO keyspace.table (a) VALUES(?)", (to_insert,))
.await?;
Expand Down
4 changes: 2 additions & 2 deletions docs/source/data-types/duration.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Duration
`Duration` is represented as [`CqlDuration`](https://docs.rs/scylla/latest/scylla/frame/value/struct.CqlDuration.html)\
`Duration` is represented as [`CqlDuration`](https://docs.rs/scylla/latest/scylla/cql/value/struct.CqlDuration.html)\

```rust
# extern crate scylla;
# use scylla::Session;
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::IntoTypedRows;
use scylla::frame::value::CqlDuration;
use scylla::cql::value::CqlDuration;

// Insert some ip address into the table
let to_insert: CqlDuration = CqlDuration { months: 1, days: 2, nanoseconds: 3 };
Expand Down
4 changes: 2 additions & 2 deletions docs/source/data-types/time.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Time
`Time` is represented as [`chrono::Duration`](https://docs.rs/chrono/0.4.19/chrono/struct.Duration.html)

Internally `Time` is represented as number of nanoseconds since midnight.
Internally `Time` is represented as number of nanoseconds since midnight.
It can't be negative or exceed `86399999999999` (24 hours).

When sending in a query it needs to be wrapped in `value::Time` to differentiate from [`Timestamp`](timestamp.md)
Expand All @@ -13,7 +13,7 @@ When sending in a query it needs to be wrapped in `value::Time` to differentiate
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::IntoTypedRows;
use scylla::frame::value::Time;
use scylla::cql::value::Time;
use chrono::Duration;

// Insert some time into the table
Expand Down
2 changes: 1 addition & 1 deletion docs/source/data-types/timestamp.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ When sending in a query it needs to be wrapped in `value::Timestamp` to differen
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::IntoTypedRows;
use scylla::frame::value::Timestamp;
use scylla::cql::value::Timestamp;
use chrono::Duration;

// Insert some timestamp into the table
Expand Down
6 changes: 3 additions & 3 deletions docs/source/execution-profiles/create-and-use.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ To create an `ExecutionProfile` and attach it as default for `Session`:
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::{Session, SessionBuilder};
use scylla::statement::Consistency;
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;

let profile = ExecutionProfile::builder()
.consistency(Consistency::LocalOne)
Expand All @@ -34,7 +34,7 @@ To create an `ExecutionProfile` and attach it to a `Query`:
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::statement::Consistency;
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;
use std::time::Duration;

let profile = ExecutionProfile::builder()
Expand All @@ -60,7 +60,7 @@ To create an `ExecutionProfile` based on another profile:
# use std::error::Error;
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::statement::Consistency;
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;
use std::time::Duration;

let base_profile = ExecutionProfile::builder()
Expand Down
6 changes: 3 additions & 3 deletions docs/source/execution-profiles/maximal-example.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
use scylla::query::Query;
use scylla::speculative_execution::SimpleSpeculativeExecutionPolicy;
use scylla::statement::{Consistency, SerialConsistency};
use scylla::transport::ExecutionProfile;
use scylla::transport::load_balancing::DefaultPolicy;
use scylla::transport::retry_policy::FallthroughRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::load_balancing::DefaultPolicy;
use scylla::execution::retries::FallthroughRetryPolicy;
use std::{sync::Arc, time::Duration};

let profile = ExecutionProfile::builder()
Expand Down
2 changes: 1 addition & 1 deletion docs/source/execution-profiles/priority.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Priorities of execution profiles and directly set options:
use scylla::{Session, SessionBuilder};
use scylla::query::Query;
use scylla::statement::Consistency;
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;

let session_profile = ExecutionProfile::builder()
.consistency(Consistency::One)
Expand Down
2 changes: 1 addition & 1 deletion docs/source/execution-profiles/remap.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Below, the remaps described above are followed in code.
use scylla::{Session, SessionBuilder};
use scylla::query::Query;
use scylla::statement::Consistency;
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;

let profile1 = ExecutionProfile::builder()
.consistency(Consistency::One)
Expand Down
6 changes: 3 additions & 3 deletions docs/source/load-balancing/load-balancing.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ balancing plan based on the query information and the state of the cluster.

Load balancing policies do not influence to which nodes connections are
being opened. For a node connection blacklist configuration refer to
`scylla::transport::host_filter::HostFilter`, which can be set session-wide
`scylla::cluster::host_filter::HostFilter`, which can be set session-wide
using `SessionBuilder::host_filter` method.

## Plan
Expand Down Expand Up @@ -49,8 +49,8 @@ The newly created execution profile is then converted to a handle using
# async fn check_only_compiles(uri: &str) -> Result<(), Box<dyn Error>> {
use scylla::SessionBuilder;
use scylla::load_balancing::DefaultPolicy;
use scylla::transport::ExecutionProfile;
use scylla::transport::session::Session;
use scylla::execution::ExecutionProfile;
use scylla::session::Session;
use std::sync::Arc;

let policy = Arc::new(DefaultPolicy::default());
Expand Down
4 changes: 2 additions & 2 deletions docs/source/queries/result.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ session.query("INSERT INTO ks.tab (a) VALUES (0)", &[]).await?.result_not_rows()
For more see [`QueryResult`](https://docs.rs/scylla/latest/scylla/transport/query_result/struct.QueryResult.html)

### `NULL` values
`NULL` values will return an error when parsed as a Rust type.
`NULL` values will return an error when parsed as a Rust type.
To properly handle `NULL` values parse column as an `Option<>`:
```rust
# extern crate scylla;
Expand Down Expand Up @@ -123,7 +123,7 @@ Field names don't need to match column names.
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::IntoTypedRows;
use scylla::macros::FromRow;
use scylla::frame::response::cql_to_rust::FromRow;
use scylla::cql::cql_to_rust::FromRow;

#[derive(FromRow)]
struct MyRow {
Expand Down
2 changes: 1 addition & 1 deletion docs/source/queries/timeouts.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ However, setting per-statement timeout to `None` results in falling back to per-
# use std::error::Error;
# async fn timeouts() -> Result<(), Box<dyn Error>> {
use scylla::{Session, SessionBuilder, query::Query};
use scylla::transport::ExecutionProfile;
use scylla::execution::ExecutionProfile;
use std::time::Duration;

let uri = std::env::var("SCYLLA_URI")
Expand Down
6 changes: 3 additions & 3 deletions docs/source/queries/values.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Query values
Query text is constant, but the values might change.
You can pass changing values to a query by specifying a list of variables as bound values.\
Each `?` in query text will be filled with the matching value.
Each `?` in query text will be filled with the matching value.

> **Never** pass values by adding strings, this could lead to [SQL Injection](https://en.wikipedia.org/wiki/SQL_injection)

Expand All @@ -12,7 +12,7 @@ or a custom struct which derives from `ValueList`.
A few examples:
```rust
# extern crate scylla;
# use scylla::{Session, ValueList, frame::response::result::CqlValue};
# use scylla::{Session, ValueList, cql::value::CqlValue};
# use std::error::Error;
# use std::collections::HashMap;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
Expand Down Expand Up @@ -94,7 +94,7 @@ Using `Unset` results in better performance:
# use scylla::Session;
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::frame::value::{MaybeUnset, Unset};
use scylla::cql::value::{MaybeUnset, Unset};

// Inserting a null results in suboptimal performance
let null_i32: Option<i32> = None;
Expand Down
12 changes: 6 additions & 6 deletions docs/source/retry-policy/default.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ To use in `Session`:
# use std::error::Error;
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::{Session, SessionBuilder};
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::DefaultRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DefaultRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(DefaultRetryPolicy::new()))
Expand All @@ -36,8 +36,8 @@ To use in a [simple query](../queries/simple.md):
# use std::sync::Arc;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::DefaultRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DefaultRetryPolicy;

// Create a Query manually and set the retry policy
let mut my_query: Query = Query::new("INSERT INTO ks.tab (a) VALUES(?)");
Expand Down Expand Up @@ -65,8 +65,8 @@ To use in a [prepared query](../queries/prepared.md):
# use std::sync::Arc;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::prepared_statement::PreparedStatement;
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::DefaultRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DefaultRetryPolicy;

// Create PreparedStatement manually and set the retry policy
let mut prepared: PreparedStatement = session
Expand Down
12 changes: 6 additions & 6 deletions docs/source/retry-policy/downgrading-consistency.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ To use in `Session`:
# use std::error::Error;
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::{Session, SessionBuilder};
use scylla::transport::ExecutionProfile;
use scylla::transport::downgrading_consistency_retry_policy::DowngradingConsistencyRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DowngradingConsistencyRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(DowngradingConsistencyRetryPolicy::new()))
Expand All @@ -76,8 +76,8 @@ To use in a [simple query](../queries/simple.md):
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::transport::ExecutionProfile;
use scylla::transport::downgrading_consistency_retry_policy::DowngradingConsistencyRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DowngradingConsistencyRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(DowngradingConsistencyRetryPolicy::new()))
Expand All @@ -102,8 +102,8 @@ To use in a [prepared query](../queries/prepared.md):
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::prepared_statement::PreparedStatement;
use scylla::transport::ExecutionProfile;
use scylla::transport::downgrading_consistency_retry_policy::DowngradingConsistencyRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::DowngradingConsistencyRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(DowngradingConsistencyRetryPolicy::new()))
Expand Down
12 changes: 6 additions & 6 deletions docs/source/retry-policy/fallthrough.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ To use in `Session`:
# use std::error::Error;
# async fn check_only_compiles() -> Result<(), Box<dyn Error>> {
use scylla::{Session, SessionBuilder};
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::FallthroughRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::FallthroughRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(FallthroughRetryPolicy::new()))
Expand All @@ -34,8 +34,8 @@ To use in a [simple query](../queries/simple.md):
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::FallthroughRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::FallthroughRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(FallthroughRetryPolicy::new()))
Expand All @@ -60,8 +60,8 @@ To use in a [prepared query](../queries/prepared.md):
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::prepared_statement::PreparedStatement;
use scylla::transport::ExecutionProfile;
use scylla::transport::retry_policy::FallthroughRetryPolicy;
use scylla::execution::ExecutionProfile;
use scylla::execution::retries::FallthroughRetryPolicy;

let handle = ExecutionProfile::builder()
.retry_policy(Box::new(FallthroughRetryPolicy::new()))
Expand Down
2 changes: 1 addition & 1 deletion docs/source/speculative-execution/percentile.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use scylla::{
Session,
SessionBuilder,
speculative_execution::PercentileSpeculativeExecutionPolicy,
transport::execution_profile::ExecutionProfile,
execution::ExecutionProfile,
};

let policy = PercentileSpeculativeExecutionPolicy {
Expand Down
2 changes: 1 addition & 1 deletion docs/source/speculative-execution/simple.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use scylla::{
Session,
SessionBuilder,
speculative_execution::SimpleSpeculativeExecutionPolicy,
transport::execution_profile::ExecutionProfile,
execution::ExecutionProfile,
};

let policy = SimpleSpeculativeExecutionPolicy {
Expand Down
6 changes: 3 additions & 3 deletions docs/source/tracing/basic.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ return a `QueryResult` which contains a `tracing_id` if tracing was enabled.
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::QueryResult;
use scylla::tracing::TracingInfo;
use scylla::execution::tracing::TracingInfo;
use uuid::Uuid;

// Create a Query manually and enable tracing
Expand Down Expand Up @@ -40,7 +40,7 @@ if let Some(id) = tracing_id {
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::prepared_statement::PreparedStatement;
use scylla::QueryResult;
use scylla::tracing::TracingInfo;
use scylla::execution::tracing::TracingInfo;
use uuid::Uuid;

// Prepare the query
Expand Down Expand Up @@ -72,7 +72,7 @@ if let Some(id) = tracing_id {
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::batch::Batch;
use scylla::QueryResult;
use scylla::tracing::TracingInfo;
use scylla::execution::tracing::TracingInfo;
use uuid::Uuid;

// Create a batch statement
Expand Down
8 changes: 4 additions & 4 deletions docs/source/tracing/paged.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ If tracing is enabled the row iterator will contain a list of tracing ids for al
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::transport::iterator::RowIterator;
use scylla::tracing::TracingInfo;
use scylla::execution::iterator::RowIterator;
use scylla::execution::tracing::TracingInfo;
use futures::StreamExt;
use uuid::Uuid;

Expand Down Expand Up @@ -49,8 +49,8 @@ for id in tracing_ids {
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::prepared_statement::PreparedStatement;
use scylla::transport::iterator::RowIterator;
use scylla::tracing::TracingInfo;
use scylla::execution::iterator::RowIterator;
use scylla::execution::tracing::TracingInfo;
use futures::StreamExt;
use uuid::Uuid;

Expand Down
2 changes: 1 addition & 1 deletion docs/source/tracing/prepare.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::prepared_statement::PreparedStatement;
use scylla::tracing::TracingInfo;
use scylla::execution::tracing::TracingInfo;
use uuid::Uuid;

// Prepare the query with tracing enabled
Expand Down
2 changes: 1 addition & 1 deletion docs/source/tracing/query-history.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ This history includes all requests sent, decisions to retry and speculative exec
# use std::error::Error;
# async fn check_only_compiles(session: &Session) -> Result<(), Box<dyn Error>> {
use scylla::query::Query;
use scylla::history::{HistoryCollector, StructuredHistory};
use scylla::execution::history::{HistoryCollector, StructuredHistory};
use std::sync::Arc;

// Create a query for which we would like to trace the history of its execution
Expand Down
Loading