Skip to content

Commit 9d11efc

Browse files
authored
refactor: upgrade arango-rs and bb8 deps (#3)
1 parent 0263013 commit 9d11efc

File tree

2 files changed

+11
-14
lines changed

2 files changed

+11
-14
lines changed

Cargo.toml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bb8-arangodb"
3-
version = "0.2.0"
3+
version = "0.3.0"
44
authors = ["Gabor Boros <gabor.brs@gmail.com>"]
55
edition = "2021"
66
description = "ArangoDB driver for bb8 based on the arangors crate."
@@ -14,11 +14,10 @@ exclude = [".gitignore", ".github/**"]
1414
maintenance = { status = "actively-developed" }
1515

1616
[dependencies]
17-
async-trait = "0.1"
18-
arangors = { version = "0.5", default-features = false }
19-
bb8 = "0.8"
17+
arangors = { version = "0.6", default-features = false }
18+
bb8 = "0.9"
2019

2120
[dev-dependencies]
22-
arangors = "0.5"
21+
arangors = "0.6"
2322
tokio = { version = "1.0", features = ["macros", "rt-multi-thread"] }
2423
tokio-test = "0.4"

src/lib.rs

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
//! ```
1414
//! use bb8::Pool;
1515
//! use bb8_arangodb::{ArangoConnectionManager, AuthenticationMethod};
16-
//! use arangors::uclient::reqwest::ReqwestClient;
16+
//! use arangors::client::reqwest::ReqwestClient;
1717
//!
1818
//! tokio_test::block_on(async {
1919
//! let manager = ArangoConnectionManager::<ReqwestClient>::new(
@@ -35,7 +35,7 @@
3535
//! ```
3636
//! use bb8::Pool;
3737
//! use bb8_arangodb::{ArangoConnectionManager, AuthenticationMethod};
38-
//! use arangors::uclient::reqwest::ReqwestClient;
38+
//! use arangors::client::reqwest::ReqwestClient;
3939
//!
4040
//! tokio_test::block_on(async {
4141
//! let manager = ArangoConnectionManager::<ReqwestClient>::new(
@@ -57,7 +57,7 @@
5757
//! ```no_run
5858
//! use bb8::Pool;
5959
//! use bb8_arangodb::{ArangoConnectionManager, AuthenticationMethod};
60-
//! use arangors::uclient::reqwest::ReqwestClient;
60+
//! use arangors::client::reqwest::ReqwestClient;
6161
//!
6262
//! tokio_test::block_on(async {
6363
//! let manager = ArangoConnectionManager::<ReqwestClient>::new(
@@ -78,8 +78,7 @@ use std::marker::PhantomData;
7878
pub use arangors;
7979
pub use bb8;
8080

81-
use arangors::{uclient, ClientError, GenericConnection};
82-
use async_trait::async_trait;
81+
use arangors::{client, ClientError, GenericConnection};
8382

8483
/// Kind of the authentication method to use when establishing a connection.
8584
#[derive(Debug)]
@@ -96,13 +95,13 @@ pub enum AuthenticationMethod {
9695

9796
/// A connection manager for ArangoDB.
9897
#[derive(Debug)]
99-
pub struct ArangoConnectionManager<C: uclient::ClientExt> {
98+
pub struct ArangoConnectionManager<C: client::ClientExt> {
10099
url: String,
101100
method: AuthenticationMethod,
102101
phantom: PhantomData<C>,
103102
}
104103

105-
impl<C: uclient::ClientExt> ArangoConnectionManager<C> {
104+
impl<C: client::ClientExt> ArangoConnectionManager<C> {
106105
/// Create a new ArangoConnectionManager..
107106
pub fn new(url: String, method: AuthenticationMethod) -> Self {
108107
Self {
@@ -113,8 +112,7 @@ impl<C: uclient::ClientExt> ArangoConnectionManager<C> {
113112
}
114113
}
115114

116-
#[async_trait]
117-
impl<C: uclient::ClientExt + Send + 'static> bb8::ManageConnection for ArangoConnectionManager<C> {
115+
impl<C: client::ClientExt + Send + 'static> bb8::ManageConnection for ArangoConnectionManager<C> {
118116
type Connection = GenericConnection<C>;
119117
type Error = ClientError;
120118

0 commit comments

Comments
 (0)