@@ -13,10 +13,7 @@ use crate::{
1313 config:: Config ,
1414 pd:: { PdClient , PdRpcClient } ,
1515 raw:: lowering:: * ,
16- request:: {
17- codec:: { RawCodec , RequestCodec } ,
18- Collect , CollectSingle , Plan ,
19- } ,
16+ request:: { codec:: RawCodec , Collect , CollectSingle , Plan } ,
2017 Backoff , BoundRange , ColumnFamily , Key , KvPair , Result , Value ,
2118} ;
2219
@@ -29,7 +26,7 @@ const MAX_RAW_KV_SCAN_LIMIT: u32 = 10240;
2926///
3027/// The returned results of raw request methods are [`Future`](std::future::Future)s that must be
3128/// awaited to execute.
32- pub struct Client < C , PdC : PdClient = PdRpcClient < C > > {
29+ pub struct Client < C : RawCodec , PdC : PdClient = PdRpcClient < C > > {
3330 rpc : Arc < PdC > ,
3431 cf : Option < ColumnFamily > ,
3532 /// Whether to use the [`atomic mode`](Client::with_atomic_for_cas).
@@ -38,7 +35,7 @@ pub struct Client<C, PdC: PdClient = PdRpcClient<C>> {
3835 _phantom : PhantomData < C > ,
3936}
4037
41- impl < C : RequestCodec > Clone for Client < C > {
38+ impl < C : RawCodec > Clone for Client < C > {
4239 fn clone ( & self ) -> Self {
4340 Self {
4441 rpc : self . rpc . clone ( ) ,
0 commit comments