Commit ede5582
Remove non-functional Thread.sleep(50) from async handler
The sleep doesn't reproduce the flake — it delays the Future body execution,
not the gap between span finish and Scala continuation cleanup. The race
window is nanoseconds and only manifests under extreme CI load (>20s OS
preemption). The .recover fix eliminates the race by design: converting the
failed Future to a successful one ensures the span is finished deterministically
before the HTTP response is sent.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent d6f5c4e commit ede5582
1 file changed
Lines changed: 0 additions & 4 deletions
File tree
- dd-java-agent/instrumentation/pekko/pekko-http-1.0/src/baseTest/scala
dd-java-agent/instrumentation/pekko/pekko-http-1.0/src/baseTest/scala/PekkoHttpTestWebServer.scala
Lines changed: 0 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
274 | 274 | | |
275 | 275 | | |
276 | 276 | | |
277 | | - | |
278 | | - | |
279 | | - | |
280 | | - | |
281 | 277 | | |
282 | 278 | | |
283 | 279 | | |
| |||
0 commit comments