Add key value to deserialize errors
This commit is contained in:
@@ -135,7 +135,8 @@ impl DirectoryStore for Store {
|
||||
Ok(true)
|
||||
},
|
||||
)
|
||||
.await.caused_by(trc::location!())?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
}
|
||||
|
||||
Ok(results)
|
||||
|
||||
@@ -206,7 +206,9 @@ impl QueueManagement for Server {
|
||||
.iterate(
|
||||
IterateParams::new(from_key, to_key).ascending(),
|
||||
|key, value| {
|
||||
let message = Bincode::<queue::Message>::deserialize(value)?.inner;
|
||||
let message = Bincode::<queue::Message>::deserialize(value)
|
||||
.add_context(|ctx| ctx.ctx(trc::Key::Key, key))?
|
||||
.inner;
|
||||
let matches = tenant_domains
|
||||
.as_ref()
|
||||
.map_or(true, |domains| message.has_domain(domains))
|
||||
|
||||
@@ -227,7 +227,8 @@ impl ManageReports for Server {
|
||||
Ok(max_total == 0 || total < max_total)
|
||||
},
|
||||
)
|
||||
.await.caused_by(trc::location!())?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
|
||||
Ok(JsonResponse::new(json!({
|
||||
"data": {
|
||||
|
||||
@@ -118,7 +118,9 @@ impl Indexer for Server {
|
||||
)
|
||||
.await
|
||||
.map_err(|err| {
|
||||
trc::error!(err.caused_by(trc::location!()).details("Failed to iterate over index emails"));
|
||||
trc::error!(err
|
||||
.caused_by(trc::location!())
|
||||
.details("Failed to iterate over index emails"));
|
||||
});
|
||||
|
||||
// Add entries to the index
|
||||
|
||||
@@ -559,7 +559,8 @@ impl DmarcReporting for Server {
|
||||
}
|
||||
},
|
||||
)
|
||||
.await.caused_by(trc::location!())?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
|
||||
for (record, count) in record_map {
|
||||
report = report.with_record(record.with_count(count));
|
||||
|
||||
@@ -366,7 +366,8 @@ impl TlsReporting for Server {
|
||||
Ok(true)
|
||||
}
|
||||
})
|
||||
.await.caused_by(trc::location!())?;
|
||||
.await
|
||||
.caused_by(trc::location!())?;
|
||||
|
||||
// Add policy
|
||||
report.policies.push(Policy {
|
||||
|
||||
Reference in New Issue
Block a user