Skip to content

Commit

Permalink
editoast: endpoints to retrieve stdcm payloads
Browse files Browse the repository at this point in the history
Signed-off-by: hamz2a <atrari.hamza@gmail.com>
  • Loading branch information
hamz2a committed Jan 6, 2025
1 parent 5a24fa3 commit 1a7b3f8
Show file tree
Hide file tree
Showing 16 changed files with 791 additions and 134 deletions.
3 changes: 2 additions & 1 deletion editoast/editoast_common/src/tracing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,12 @@ pub struct TracingConfig {

pub fn create_tracing_subscriber<T: SpanExporter + 'static>(
tracing_config: TracingConfig,
log_level: tracing_subscriber::filter::LevelFilter,
exporter: T,
) -> impl tracing::Subscriber {
let env_filter_layer = tracing_subscriber::EnvFilter::builder()
// Set the default log level to 'info'
.with_default_directive(tracing_subscriber::filter::LevelFilter::INFO.into())
.with_default_directive(log_level.into())
.from_env_lossy();
let fmt_layer = tracing_subscriber::fmt::layer()
.pretty()
Expand Down
3 changes: 2 additions & 1 deletion editoast/editoast_schemas/src/train_schedule/margins.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ use utoipa::ToSchema;

editoast_common::schemas! {
Margins,
MarginValue,
}

#[derive(Debug, Clone, Serialize, Derivative, ToSchema)]
Expand Down Expand Up @@ -44,7 +45,7 @@ impl<'de> Deserialize<'de> for Margins {
}
}

#[derive(Debug, Copy, Clone, PartialEq, Derivative)]
#[derive(Debug, Copy, Clone, PartialEq, Derivative, ToSchema)]
#[derivative(Hash, Default)]
pub enum MarginValue {
#[derivative(Default)]
Expand Down
Loading

0 comments on commit 1a7b3f8

Please sign in to comment.