Skip to content

Commit e930004

Browse files
authored
Merge pull request #3260 from calebschoepp/fix-otel-span-propagation-caleb
trigger-http: Fix otel context propagation
2 parents d8dbc58 + bb28e27 commit e930004

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

crates/trigger-http/src/wasi.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,29 +93,28 @@ impl HttpExecutor for WasiHttpExecutor<'_> {
9393
HandlerType::Wagi(_) => unreachable!("should have used WagiExecutor instead"),
9494
};
9595

96-
let span = tracing::debug_span!("execute_wasi");
9796
let handle = task::spawn(
9897
async move {
9998
let result = match handler {
10099
Handler::Latest(handler) => {
101100
handler
102101
.wasi_http_incoming_handler()
103102
.call_handle(&mut store, request, response)
104-
.instrument(span)
103+
.in_current_span()
105104
.await
106105
}
107106
Handler::Handler2023_10_18(handler) => {
108107
handler
109108
.wasi_http0_2_0_rc_2023_10_18_incoming_handler()
110109
.call_handle(&mut store, request, response)
111-
.instrument(span)
110+
.in_current_span()
112111
.await
113112
}
114113
Handler::Handler2023_11_10(handler) => {
115114
handler
116115
.wasi_http0_2_0_rc_2023_11_10_incoming_handler()
117116
.call_handle(&mut store, request, response)
118-
.instrument(span)
117+
.in_current_span()
119118
.await
120119
}
121120
};

0 commit comments

Comments
 (0)