Skip to content

Commit

Permalink
chore: expose pool / sqlx
Browse files Browse the repository at this point in the history
  • Loading branch information
bodymindarts committed Jun 12, 2024
1 parent 6b9df30 commit 8a9c468
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cala-ledger/src/ledger/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ impl CalaLedger {
})
}

pub fn pool(&self) -> &PgPool {
&self.pool
}

pub async fn begin_operation<'a>(&self) -> Result<AtomicOperation<'a>, LedgerError> {
Ok(AtomicOperation::init(&self.pool, &self.outbox).await?)
}
Expand Down
1 change: 1 addition & 0 deletions cala-server/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ pub mod server;
pub use async_graphql;
pub use async_trait;
pub use futures;
pub use sqlx;
pub use tokio;
pub use tracing;

Expand Down

0 comments on commit 8a9c468

Please sign in to comment.