Skip to content

Commit

Permalink
update clickhouse with lz4
Browse files Browse the repository at this point in the history
  • Loading branch information
blind-oracle committed Jun 4, 2024
1 parent 449428b commit 2ade4a3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 13 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ clap = { version = "4.5", features = ["derive", "string"] }
clap_derive = "4.5"
# TODO lz4 feature requires C++ compiler to build, fails with MUSL
clickhouse = { git = "https://github.com/blind-oracle/clickhouse.rs.git", default_features = false, features = [
"lz4",
"inserter",
"tls",
"uuid",
Expand Down
13 changes: 1 addition & 12 deletions src/routing/ic/transport.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ use futures::Future;
use futures_util::StreamExt;
use ic_agent::{
agent::{
agent_error::HttpErrorPayload,
http_transport::route_provider::{RoundRobinRouteProvider, RouteProvider},
Transport,
agent_error::HttpErrorPayload, http_transport::route_provider::RouteProvider, Transport,
},
export::Principal,
AgentError, RequestId,
Expand Down Expand Up @@ -54,15 +52,6 @@ pub struct ReqwestTransport {
}

impl ReqwestTransport {
/// Creates a replica transport from a HTTP URL and a [`reqwest::Client`].
pub fn create_with_client<U: Into<String>>(
url: U,
client: Arc<dyn HttpClient>,
) -> Result<Self, AgentError> {
let route_provider = Arc::new(RoundRobinRouteProvider::new(vec![url.into()])?);
Self::create_with_client_route(route_provider, client)
}

/// Creates a replica transport from a [`RouteProvider`] and a [`reqwest::Client`].
pub fn create_with_client_route(
route_provider: Arc<dyn RouteProvider>,
Expand Down
2 changes: 1 addition & 1 deletion src/routing/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ use std::sync::Arc;

use anyhow::Error;
use axum::{
extract::{Host, MatchedPath, OriginalUri, Request},
extract::{Host, OriginalUri, Request},
middleware::{from_fn, from_fn_with_state, FromFnLayer},
response::{IntoResponse, Redirect},
routing::{get, post},
Expand Down

0 comments on commit 2ade4a3

Please sign in to comment.