Skip to content

Commit

Permalink
style: Remove duration from serialization debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
PROFeNoM committed Feb 20, 2025
1 parent d39e0b7 commit 6aecc1f
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions ext/serializer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1806,17 +1806,14 @@ void ddtrace_serialize_span_to_array(ddtrace_span_data *span, zval *array) {
smart_str_0(&metrics_str);
}
prop_name = zend_hash_str_find(Z_ARR_P(el), ZEND_STRL("name")); // refetch, array may have been rehashed
log("Encoding span %" PRIu64 ": trace_id=%s, name='%s', service='%s', resource: '%s', type '%s' with tags: %s; metrics: %s; start: %ld; duration_start: %ld, and duration: %ld",
log("Encoding span %" PRIu64 ": trace_id=%s, name='%s', service='%s', resource: '%s', type '%s' with tags: %s; and metrics: %s",
span->span_id,
Z_STRVAL(span->root->property_trace_id), prop_name && Z_TYPE_P(prop_name) == IS_STRING ? Z_STRVAL_P(prop_name) : "",
Z_TYPE(prop_service_as_string) == IS_STRING ? Z_STRVAL(prop_service_as_string) : "",
Z_TYPE(prop_resource_as_string) == IS_STRING ? Z_STRVAL(prop_resource_as_string) : "",
Z_TYPE(prop_type_as_string) == IS_STRING ? Z_STRVAL(prop_type_as_string) : "",
meta_str.s ? ZSTR_VAL(meta_str.s) : "-",
metrics_str.s ? ZSTR_VAL(metrics_str.s) : "-",
span->start,
span->duration_start,
span->duration);
metrics_str.s ? ZSTR_VAL(metrics_str.s) : "-");
smart_str_free(&meta_str);
smart_str_free(&metrics_str);
})
Expand Down

0 comments on commit 6aecc1f

Please sign in to comment.