mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-30 01:27:31 +08:00
build: bump MSRV to 1.76.0 (#5586)
This commit is contained in:
@ -1,4 +1,3 @@
|
||||
#![forbid(unsafe_code)]
|
||||
#![warn(missing_debug_implementations)]
|
||||
|
||||
//!
|
||||
|
||||
@ -151,6 +151,8 @@ impl Config {
|
||||
.add_source(config::Environment::with_prefix("ROUTER").separator("__"))
|
||||
.build()?;
|
||||
|
||||
// The logger may not yet be initialized when constructing the application configuration
|
||||
#[allow(clippy::print_stderr)]
|
||||
serde_path_to_error::deserialize(config).map_err(|error| {
|
||||
crate::error!(%error, "Unable to deserialize configuration");
|
||||
eprintln!("Unable to deserialize application configuration: {error}");
|
||||
|
||||
@ -33,6 +33,7 @@ pub struct TelemetryGuard {
|
||||
/// Setup logging sub-system specifying the logging configuration, service (binary) name, and a
|
||||
/// list of external crates for which a more verbose logging must be enabled. All crates within the
|
||||
/// current cargo workspace are automatically considered for verbose logging.
|
||||
#[allow(clippy::print_stdout)] // The logger hasn't been initialized yet
|
||||
pub fn setup(
|
||||
config: &config::Log,
|
||||
service_name: &str,
|
||||
@ -271,6 +272,7 @@ fn setup_tracing_pipeline(
|
||||
.install_batch(runtime::TokioCurrentThread)
|
||||
.map(|tracer| tracing_opentelemetry::layer().with_tracer(tracer));
|
||||
|
||||
#[allow(clippy::print_stderr)] // The logger hasn't been initialized yet
|
||||
if config.ignore_errors {
|
||||
traces_layer_result
|
||||
.map_err(|error| {
|
||||
@ -315,6 +317,7 @@ fn setup_metrics_pipeline(config: &config::LogTelemetry) -> Option<BasicControll
|
||||
)]))
|
||||
.build();
|
||||
|
||||
#[allow(clippy::print_stderr)] // The logger hasn't been initialized yet
|
||||
if config.ignore_errors {
|
||||
metrics_controller_result
|
||||
.map_err(|error| eprintln!("Failed to setup metrics pipeline: {error:?}"))
|
||||
|
||||
Reference in New Issue
Block a user