Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 5 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

135 changes: 87 additions & 48 deletions crates/chain-orchestrator/src/lib.rs

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion crates/database/db/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@ rollup-node-primitives.workspace = true
async-trait.workspace = true
auto_impl.workspace = true
futures.workspace = true
metrics.workspace = true
metrics-derive.workspace = true
sea-orm = { workspace = true, features = ["sqlx-sqlite", "runtime-tokio-native-tls", "macros"] }
tempfile = { version = "3.20.0", optional = true }
thiserror.workspace = true
tokio = { workspace = true, features = ["macros", "sync"] }
tracing.workspace = true
Expand All @@ -41,4 +44,4 @@ arbitrary.workspace = true
rand.workspace = true

[features]
test-utils = ["dep:scroll-migration"]
test-utils = ["dep:scroll-migration", "dep:tempfile"]
7 changes: 6 additions & 1 deletion crates/database/db/src/connection.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/// The [`DatabaseConnectionProvider`] trait provides a way to get a connection to the database.
/// This is implemented by the [`crate::Database`] and [`crate::DatabaseTransaction`] types.
#[auto_impl::auto_impl(Arc)]
pub trait DatabaseConnectionProvider {
/// The type of the database connection.
Expand All @@ -9,3 +8,9 @@ pub trait DatabaseConnectionProvider {
/// `StreamTrait` traits.
fn get_connection(&self) -> &Self::Connection;
}

/// A trait for providing read-only access to the database.
pub trait ReadConnectionProvider: DatabaseConnectionProvider {}

/// A trait for providing read and write access to the database.
pub trait WriteConnectionProvider: ReadConnectionProvider {}
Loading
Loading