Skip to content

Commit

Permalink
Do not return invalid TraceIDs in datafusion
Browse files Browse the repository at this point in the history
  • Loading branch information
AhmedSoliman committed Jan 12, 2024
1 parent 1e0c80d commit 6a8966f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions crates/storage-query-datafusion/src/status/row.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use restate_storage_api::status_table::{
};
use restate_storage_rocksdb::status_table::OwnedStatusRow;
use restate_types::identifiers::InvocationId;
use restate_types::invocation::Source;
use restate_types::invocation::{Source, TraceId};

#[inline]
pub(crate) fn append_status_row(
Expand Down Expand Up @@ -117,7 +117,9 @@ fn fill_journal_metadata(
) {
if row.is_trace_id_defined() {
let tid = journal_metadata.span_context.trace_id();
row.trace_id(format_using(output, &tid));
if tid != TraceId::INVALID {
row.trace_id(format_using(output, &tid));
}
}

row.journal_size(journal_metadata.length);
Expand Down

0 comments on commit 6a8966f

Please sign in to comment.