Skip to content

Commit

Permalink
fix: resolve PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelScofield committed Dec 26, 2023
1 parent 61af39d commit 235232b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 9 deletions.
6 changes: 3 additions & 3 deletions src/operator/src/insert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ use common_meta::datanode_manager::{AffectedRows, DatanodeManagerRef};
use common_meta::peer::Peer;
use common_query::Output;
use common_telemetry::tracing_context::TracingContext;
use common_telemetry::{debug, error, info};
use common_telemetry::{error, info};
use datatypes::schema::Schema;
use futures_util::future;
use meter_macros::write_meter;
Expand Down Expand Up @@ -301,7 +301,7 @@ impl Inserter {
let request_schema = req.rows.as_ref().unwrap().schema.as_slice();
let create_table_expr = &mut build_create_table_expr(&table_ref, request_schema)?;

debug!(
info!(
"Table {}.{}.{} does not exist, try create table",
table_ref.catalog, table_ref.schema, table_ref.table,
);
Expand All @@ -320,7 +320,7 @@ impl Inserter {
Ok(())
}
Err(err) => {
debug!(
error!(
"Failed to create table {}.{}.{}: {}",
table_ref.catalog, table_ref.schema, table_ref.table, err
);
Expand Down
8 changes: 2 additions & 6 deletions src/servers/src/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ use common_error::status_code::StatusCode;
use common_query::Output;
use common_recordbatch::{util, RecordBatch};
use common_telemetry::logging::{debug, error, info};
use common_telemetry::tracing::Level;
use common_time::timestamp::TimeUnit;
use common_time::Timestamp;
use datatypes::data_type::DataType;
Expand All @@ -62,7 +61,7 @@ use tokio::sync::oneshot::{self, Sender};
use tokio::sync::Mutex;
use tower::timeout::TimeoutLayer;
use tower::ServiceBuilder;
use tower_http::trace::{DefaultOnFailure, TraceLayer};
use tower_http::trace::TraceLayer;

use self::authorize::AuthState;
use crate::configurator::ConfiguratorRef;
Expand Down Expand Up @@ -711,10 +710,7 @@ impl HttpServer {
.layer(
ServiceBuilder::new()
.layer(HandleErrorLayer::new(handle_error))
.layer(
TraceLayer::new_for_http()
.on_failure(DefaultOnFailure::new().level(Level::DEBUG)),
)
.layer(TraceLayer::new_for_http())
.layer(TimeoutLayer::new(self.options.timeout))
.layer(DefaultBodyLimit::max(
self.options
Expand Down

0 comments on commit 235232b

Please sign in to comment.