@@ -36,15 +36,13 @@ mod my_pool {
36
36
use futures_core:: future:: BoxFuture ;
37
37
use rbatis:: async_trait;
38
38
use rbatis:: rbdc:: db:: { Connection , ExecResult , Row } ;
39
- use rbatis:: rbdc:: pool:: conn_box:: ConnectionBox ;
40
- use rbatis:: rbdc:: pool:: conn_manager:: ConnManager ;
41
- use rbatis:: rbdc:: pool:: Pool ;
42
39
use rbatis:: rbdc:: { db, Error } ;
43
40
use rbs:: value:: map:: ValueMap ;
44
41
use rbs:: { to_value, Value } ;
45
42
use std:: borrow:: Cow ;
46
43
use std:: fmt:: { Debug , Formatter } ;
47
44
use std:: time:: Duration ;
45
+ use rbatis:: rbdc:: pool:: { ConnectionGuard , ConnectionManager , Pool } ;
48
46
49
47
pub struct DeadPool {
50
48
pub manager : ConnManagerProxy ,
@@ -70,7 +68,7 @@ mod my_pool {
70
68
71
69
#[ async_trait]
72
70
impl Pool for DeadPool {
73
- fn new ( manager : ConnManager ) -> Result < Self , Error >
71
+ fn new ( manager : ConnectionManager ) -> Result < Self , Error >
74
72
where
75
73
Self : Sized ,
76
74
{
@@ -145,12 +143,12 @@ mod my_pool {
145
143
}
146
144
147
145
pub struct ConnManagerProxy {
148
- pub inner : ConnManager ,
146
+ pub inner : ConnectionManager ,
149
147
pub conn : Option < Object < ConnManagerProxy > > ,
150
148
}
151
149
152
150
impl deadpool:: managed:: Manager for ConnManagerProxy {
153
- type Type = ConnectionBox ;
151
+ type Type = ConnectionGuard ;
154
152
155
153
type Error = Error ;
156
154
0 commit comments