@@ -6,6 +6,8 @@ use crate::auth::{TokenInterceptor, WrappedInterceptor};
66use crate :: qdrant_client:: GenericQdrant ;
77use crate :: QdrantError ;
88
9+ pub type QdrantConfig = GenericQdrantConfig < TokenInterceptor > ;
10+
911struct DefaultConfigValues < I : Send + Sync + ' static + Clone + Interceptor = TokenInterceptor > {
1012 timeout : Duration ,
1113 connect_timeout : Duration ,
@@ -45,7 +47,7 @@ impl<I: Send + Sync + 'static + Clone + Interceptor> Default for DefaultConfigVa
4547/// .build();
4648/// ```
4749#[ derive( Clone ) ]
48- pub struct QdrantConfig < I : Send + Sync + ' static + Clone + Interceptor = TokenInterceptor > {
50+ pub struct GenericQdrantConfig < I : Send + Sync + ' static + Clone + Interceptor = TokenInterceptor > {
4951 /// Qdrant server URI to connect to
5052 pub uri : String ,
5153
@@ -72,7 +74,7 @@ pub struct QdrantConfig<I: Send + Sync + 'static + Clone + Interceptor = TokenIn
7274 pub interceptor : WrappedInterceptor < I > ,
7375}
7476
75- impl < I : Send + Sync + ' static + Clone + Interceptor > QdrantConfig < I > {
77+ impl < I : Send + Sync + ' static + Clone + Interceptor > GenericQdrantConfig < I > {
7678 fn with_defaults ( url : & str ) -> Self {
7779 let defaults = DefaultConfigValues :: default ( ) ;
7880 Self {
@@ -90,7 +92,7 @@ impl<I: Send + Sync + 'static + Clone + Interceptor> QdrantConfig<I> {
9092 /// Start configuring a Qdrant client with an URL
9193 ///
9294 /// ```rust,no_run
93- ///# use qdrant_client::config::QdrantConfig;
95+ /// use crate:: qdrant_client::config::QdrantConfig;
9496 /// let client = QdrantConfig::from_url("http://localhost:6334").build();
9597 /// ```
9698 ///
@@ -151,7 +153,7 @@ impl<I: Send + Sync + 'static + Clone + Interceptor> QdrantConfig<I> {
151153 /// Set the interceptor to use for this client
152154 ///
153155 /// ```no_run
154- /// use qdrant_client::GenericQdrant;
156+ /// use crate:: qdrant_client::GenericQdrant;
155157 /// use tonic::service::Interceptor;
156158 /// use tonic::{Request, Status};
157159 ///
@@ -164,7 +166,7 @@ impl<I: Send + Sync + 'static + Clone + Interceptor> QdrantConfig<I> {
164166 /// }
165167 ///
166168 ///# async fn connect() -> Result<(), qdrant_client::QdrantError> {
167- /// let client = GenericQdrant<CustomInterceptor>::from_url("http://localhost:6334")
169+ /// let client = GenericQdrant:: <CustomInterceptor>::from_url("http://localhost:6334")
168170 /// .interceptor(CustomInterceptor)
169171 /// .build()?;
170172 ///# Ok(())
@@ -227,7 +229,7 @@ impl<I: Send + Sync + 'static + Clone + Interceptor> QdrantConfig<I> {
227229 }
228230}
229231
230- impl QdrantConfig < TokenInterceptor > {
232+ impl GenericQdrantConfig < TokenInterceptor > {
231233 /// Set an optional API key
232234 ///
233235 /// This method is only available when using the default TokenInterceptor.
@@ -259,7 +261,7 @@ impl QdrantConfig<TokenInterceptor> {
259261/// Default Qdrant client configuration.
260262///
261263/// Connects to `http://localhost:6334` without an API key.
262- impl Default for QdrantConfig < TokenInterceptor > {
264+ impl Default for GenericQdrantConfig < TokenInterceptor > {
263265 fn default ( ) -> Self {
264266 Self :: with_defaults ( "http://localhost:6334" )
265267 }
0 commit comments