@@ -224,7 +224,7 @@ const DEFAULT_DATA_RETENTION_SECONDS: i64 = 24 * 60 * 60;
224
224
/// SchemaApi is implemented upon kvapi::KVApi.
225
225
/// Thus every type that impl kvapi::KVApi impls SchemaApi.
226
226
#[ tonic:: async_trait]
227
- impl < KV : kvapi:: KVApi < Error = MetaError > > SchemaApi for KV {
227
+ impl < KV : kvapi:: KVApi < Error = MetaError > + ? Sized > SchemaApi for KV {
228
228
#[ logcall:: logcall( "debug" ) ]
229
229
#[ minitrace:: trace]
230
230
async fn create_database (
@@ -2987,7 +2987,7 @@ impl<KV: kvapi::KVApi<Error = MetaError>> SchemaApi for KV {
2987
2987
inner : db_info. name_ident . clone ( ) ,
2988
2988
filter,
2989
2989
} ;
2990
- do_get_table_history ( & self , req, db_info. ident . db_id , & db_info. meta )
2990
+ do_get_table_history ( self , req, db_info. ident . db_id , & db_info. meta )
2991
2991
. await ?
2992
2992
} else {
2993
2993
// while filter_drop_on is None, then get all the drop db tables
@@ -2996,7 +2996,7 @@ impl<KV: kvapi::KVApi<Error = MetaError>> SchemaApi for KV {
2996
2996
inner : db_info. name_ident . clone ( ) ,
2997
2997
filter : TableInfoFilter :: All ,
2998
2998
} ;
2999
- do_get_table_history ( & self , req, db_info. ident . db_id , & db_info. meta )
2999
+ do_get_table_history ( self , req, db_info. ident . db_id , & db_info. meta )
3000
3000
. await ?
3001
3001
}
3002
3002
}
@@ -3006,7 +3006,7 @@ impl<KV: kvapi::KVApi<Error = MetaError>> SchemaApi for KV {
3006
3006
filter : TableInfoFilter :: Dropped ( * filter_drop_on) ,
3007
3007
} ;
3008
3008
// not drop db, only filter drop tables with filter drop on
3009
- do_get_table_history ( & self , req, db_info. ident . db_id , & db_info. meta ) . await ?
3009
+ do_get_table_history ( self , req, db_info. ident . db_id , & db_info. meta ) . await ?
3010
3010
}
3011
3011
} ;
3012
3012
if drop_db {
@@ -3055,7 +3055,7 @@ impl<KV: kvapi::KVApi<Error = MetaError>> SchemaApi for KV {
3055
3055
} ) ;
3056
3056
}
3057
3057
3058
- let table_infos = do_get_table_history ( & self , req, db_id, & db_meta) . await ?;
3058
+ let table_infos = do_get_table_history ( self , req, db_id, & db_meta) . await ?;
3059
3059
table_infos. iter ( ) . for_each ( |table_info| {
3060
3060
drop_ids. push ( DroppedId :: Table (
3061
3061
db_id,
@@ -3564,7 +3564,7 @@ impl<KV: kvapi::KVApi<Error = MetaError>> SchemaApi for KV {
3564
3564
///
3565
3565
/// Returns number of files that are going to be removed.
3566
3566
async fn remove_table_copied_files (
3567
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
3567
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
3568
3568
table_id : u64 ,
3569
3569
condition : & mut Vec < TxnCondition > ,
3570
3570
if_then : & mut Vec < TxnOp > ,
@@ -3605,7 +3605,7 @@ async fn remove_table_copied_files(
3605
3605
3606
3606
/// List the copied file identities belonging to a table.
3607
3607
async fn list_table_copied_files (
3608
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
3608
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
3609
3609
table_id : u64 ,
3610
3610
) -> Result < Vec < TableCopiedFileNameIdent > , MetaError > {
3611
3611
let copied_file_ident = TableCopiedFileNameIdent {
@@ -3697,7 +3697,7 @@ fn table_has_to_not_exist(
3697
3697
/// It returns (seq, `u64` value).
3698
3698
/// If the count value is not in the kv space, (0, `u64` value) is returned.
3699
3699
async fn count_tables (
3700
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
3700
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
3701
3701
key : & CountTablesKey ,
3702
3702
) -> Result < u64 , KVAppError > {
3703
3703
// For backward compatibility:
@@ -3774,7 +3774,7 @@ async fn get_share_table_info_map(
3774
3774
}
3775
3775
3776
3776
async fn get_table_id_from_share_by_name (
3777
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
3777
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
3778
3778
share : & ShareNameIdent ,
3779
3779
table_name : & String ,
3780
3780
) -> Result < u64 , KVAppError > {
@@ -3885,7 +3885,7 @@ fn set_update_expire_operation(
3885
3885
#[ logcall:: logcall( "debug" ) ]
3886
3886
#[ minitrace:: trace]
3887
3887
async fn do_get_table_history (
3888
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
3888
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
3889
3889
req : ListDroppedTableReq ,
3890
3890
db_id : u64 ,
3891
3891
db_meta : & DatabaseMeta ,
@@ -4021,7 +4021,7 @@ pub(crate) async fn get_index_or_err(
4021
4021
}
4022
4022
4023
4023
async fn gc_dropped_db_by_id (
4024
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
4024
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
4025
4025
db_id : u64 ,
4026
4026
tenant : String ,
4027
4027
db_name : String ,
@@ -4123,7 +4123,7 @@ async fn gc_dropped_db_by_id(
4123
4123
}
4124
4124
4125
4125
async fn gc_dropped_table_by_id (
4126
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
4126
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
4127
4127
tenant : String ,
4128
4128
db_id : u64 ,
4129
4129
table_id : u64 ,
@@ -4169,7 +4169,7 @@ async fn gc_dropped_table_by_id(
4169
4169
}
4170
4170
4171
4171
async fn gc_dropped_table_data (
4172
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
4172
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
4173
4173
table_id : u64 ,
4174
4174
condition : & mut Vec < TxnCondition > ,
4175
4175
if_then : & mut Vec < TxnOp > ,
@@ -4209,7 +4209,7 @@ async fn gc_dropped_table_data(
4209
4209
}
4210
4210
4211
4211
async fn gc_dropped_table_index (
4212
- kv_api : & impl kvapi:: KVApi < Error = MetaError > ,
4212
+ kv_api : & ( impl kvapi:: KVApi < Error = MetaError > + ? Sized ) ,
4213
4213
tenant : & str ,
4214
4214
table_id : u64 ,
4215
4215
if_then : & mut Vec < TxnOp > ,
0 commit comments