promote request error event from info to warn

And also make it structured.
This commit is contained in:
Charles Hall 2024-06-22 16:21:39 -07:00
parent 230172718f
commit 573fac553c
No known key found for this signature in database
GPG key ID: 7B8E0645816E07CF

View file

@ -9,7 +9,7 @@ use ruma::{
OwnedServerName,
};
use thiserror::Error;
use tracing::{error, info};
use tracing::{error, warn};
use crate::Ra;
@ -149,7 +149,7 @@ impl Error {
_ => (Unknown, StatusCode::INTERNAL_SERVER_ERROR),
};
info!("Returning an error: {}: {}", status_code, message);
warn!(%status_code, error = %message, "Responding with an error");
Ra(UiaaResponse::MatrixError(RumaError {
body: ErrorBody::Standard {