Improve error message when transaction is cancelled
This commit is contained in:
parent
ff5a5fd346
commit
0f4f07d5d3
2 changed files with 4 additions and 1 deletions
|
@ -112,7 +112,7 @@ impl<'a> Executor<'a> {
|
|||
sql: v.sql,
|
||||
time: v.time,
|
||||
status: Status::Err,
|
||||
detail: Some(format!("Transaction cancelled")),
|
||||
detail: Some(format!("{}", Error::QueryCancelledError)),
|
||||
result: None,
|
||||
}
|
||||
}
|
||||
|
|
|
@ -70,6 +70,9 @@ pub enum Error {
|
|||
timer: Duration,
|
||||
},
|
||||
|
||||
#[error("Query not executed due to cancelled transaction")]
|
||||
QueryCancelledError,
|
||||
|
||||
#[error("Query not executed due to failed transaction")]
|
||||
QueryExecutionError,
|
||||
|
||||
|
|
Loading…
Reference in a new issue