diff --git a/influxdb/src/client/mod.rs b/influxdb/src/client/mod.rs index 41ac198..1c84b97 100644 --- a/influxdb/src/client/mod.rs +++ b/influxdb/src/client/mod.rs @@ -91,6 +91,12 @@ impl Client { self } + /// Replaces the HTTP Client + pub fn with_http_client(mut self, http_client: HttpClient) -> Self { + self.client = http_client; + self + } + /// Returns the name of the database the client is using pub fn database_name(&self) -> &str { // safe to unwrap: we always set the database name in `Self::new`